mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
Database indexing
This commit is contained in:
parent
f072b921c7
commit
c0d4aa18c4
@ -91,7 +91,8 @@ class TemplateEmail extends Mailable
|
||||
if (strlen($settings->bcc_email) > 1) {
|
||||
if (Ninja::isHosted()) {
|
||||
$bccs = explode(',', str_replace(' ', '', $settings->bcc_email));
|
||||
$this->bcc(reset($bccs)); //remove whitespace if any has been inserted.
|
||||
$this->bcc(array_slice($bccs, 0, 2));
|
||||
//$this->bcc(reset($bccs)); //remove whitespace if any has been inserted.
|
||||
} else {
|
||||
$this->bcc(explode(',', str_replace(' ', '', $settings->bcc_email)));
|
||||
}//remove whitespace if any has been inserted.
|
||||
@ -116,11 +117,6 @@ class TemplateEmail extends Mailable
|
||||
'whitelabel' => $this->client->user->account->isPaid() ? true : false,
|
||||
'logo' => $this->company->present()->logo($settings),
|
||||
]);
|
||||
// ->withSymfonyMessage(function ($message) use ($company) {
|
||||
// $message->getHeaders()->addTextHeader('Tag', $company->company_key);
|
||||
// $message->invitation = $this->invitation;
|
||||
//});
|
||||
// ->tag($company->company_key);
|
||||
|
||||
/*In the hosted platform we need to slow things down a little for Storage to catch up.*/
|
||||
|
||||
|
@ -0,0 +1,41 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('clients', function (Blueprint $table) {
|
||||
$table->index([\DB::raw('client_hash(20)')]);
|
||||
});
|
||||
|
||||
|
||||
Schema::table('client_contacts', function (Blueprint $table) {
|
||||
$table->index([\DB::raw('contact_key(20)')]);
|
||||
$table->index('email');
|
||||
});
|
||||
|
||||
Schema::table('vendor_contacts', function (Blueprint $table) {
|
||||
$table->index([\DB::raw('contact_key(20)')]);
|
||||
$table->index('email');
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
}
|
||||
};
|
Loading…
x
Reference in New Issue
Block a user