mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-31 13:24:34 -04:00
Minor cleanup
This commit is contained in:
parent
fe4d08a522
commit
0dc4b64ad0
@ -22,7 +22,7 @@ class ClientContactFactory
|
|||||||
$client_contact->first_name = '';
|
$client_contact->first_name = '';
|
||||||
$client_contact->user_id = $user_id;
|
$client_contact->user_id = $user_id;
|
||||||
$client_contact->company_id = $company_id;
|
$client_contact->company_id = $company_id;
|
||||||
$client_contact->contact_key = Str::random(40);
|
$client_contact->contact_key = Str::random(32);
|
||||||
$client_contact->id = 0;
|
$client_contact->id = 0;
|
||||||
$client_contact->send_email = true;
|
$client_contact->send_email = true;
|
||||||
|
|
||||||
|
@ -22,7 +22,7 @@ class VendorContactFactory
|
|||||||
$vendor_contact->first_name = '';
|
$vendor_contact->first_name = '';
|
||||||
$vendor_contact->user_id = $user_id;
|
$vendor_contact->user_id = $user_id;
|
||||||
$vendor_contact->company_id = $company_id;
|
$vendor_contact->company_id = $company_id;
|
||||||
$vendor_contact->contact_key = Str::random(40);
|
$vendor_contact->contact_key = Str::random(32);
|
||||||
$vendor_contact->id = 0;
|
$vendor_contact->id = 0;
|
||||||
|
|
||||||
return $vendor_contact;
|
return $vendor_contact;
|
||||||
|
@ -120,9 +120,7 @@ class InvitationController extends Controller
|
|||||||
return response()->streamDownload(function () use($file) {
|
return response()->streamDownload(function () use($file) {
|
||||||
echo $file;
|
echo $file;
|
||||||
}, $file_name, $headers);
|
}, $file_name, $headers);
|
||||||
}
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
64
app/Jobs/Vendor/CreatePurchaseOrderPdf.php
vendored
64
app/Jobs/Vendor/CreatePurchaseOrderPdf.php
vendored
@ -11,42 +11,44 @@
|
|||||||
|
|
||||||
namespace App\Jobs\Vendor;
|
namespace App\Jobs\Vendor;
|
||||||
|
|
||||||
use App\Exceptions\FilePermissionsFailure;
|
use App\Utils\Ninja;
|
||||||
use App\Libraries\MultiDB;
|
|
||||||
use App\Models\Account;
|
|
||||||
use App\Models\Credit;
|
|
||||||
use App\Models\CreditInvitation;
|
|
||||||
use App\Models\Design;
|
|
||||||
use App\Models\Invoice;
|
|
||||||
use App\Models\InvoiceInvitation;
|
|
||||||
use App\Models\Quote;
|
use App\Models\Quote;
|
||||||
|
use App\Models\Credit;
|
||||||
|
use App\Models\Design;
|
||||||
|
use App\Models\Vendor;
|
||||||
|
use App\Models\Account;
|
||||||
|
use App\Models\Invoice;
|
||||||
|
use App\Utils\HtmlEngine;
|
||||||
|
use App\Libraries\MultiDB;
|
||||||
|
use App\Utils\Traits\Pdf\PDF;
|
||||||
|
use Illuminate\Bus\Queueable;
|
||||||
use App\Models\QuoteInvitation;
|
use App\Models\QuoteInvitation;
|
||||||
|
use App\Utils\Traits\MakesHash;
|
||||||
|
use App\Utils\VendorHtmlEngine;
|
||||||
|
use App\Models\CreditInvitation;
|
||||||
use App\Models\RecurringInvoice;
|
use App\Models\RecurringInvoice;
|
||||||
|
use App\Services\Pdf\PdfService;
|
||||||
|
use App\Utils\PhantomJS\Phantom;
|
||||||
|
use App\Models\InvoiceInvitation;
|
||||||
|
use App\Utils\HostedPDF\NinjaPdf;
|
||||||
|
use App\Utils\Traits\Pdf\PdfMaker;
|
||||||
|
use Illuminate\Support\Facades\App;
|
||||||
|
use Illuminate\Support\Facades\Lang;
|
||||||
|
use App\Utils\Traits\NumberFormatter;
|
||||||
|
use App\Utils\Traits\MakesInvoiceHtml;
|
||||||
|
use Illuminate\Queue\SerializesModels;
|
||||||
|
use App\Models\PurchaseOrderInvitation;
|
||||||
|
use App\Utils\Traits\Pdf\PageNumbering;
|
||||||
|
use Illuminate\Support\Facades\Storage;
|
||||||
|
use Illuminate\Queue\InteractsWithQueue;
|
||||||
|
use setasign\Fpdi\PdfParser\StreamReader;
|
||||||
|
use App\Exceptions\FilePermissionsFailure;
|
||||||
use App\Models\RecurringInvoiceInvitation;
|
use App\Models\RecurringInvoiceInvitation;
|
||||||
|
use Illuminate\Contracts\Queue\ShouldQueue;
|
||||||
|
use Illuminate\Foundation\Bus\Dispatchable;
|
||||||
use App\Services\PdfMaker\Design as PdfDesignModel;
|
use App\Services\PdfMaker\Design as PdfDesignModel;
|
||||||
use App\Services\PdfMaker\Design as PdfMakerDesign;
|
use App\Services\PdfMaker\Design as PdfMakerDesign;
|
||||||
use App\Services\PdfMaker\PdfMaker as PdfMakerService;
|
use App\Services\PdfMaker\PdfMaker as PdfMakerService;
|
||||||
use App\Services\Pdf\PdfService;
|
|
||||||
use App\Utils\HostedPDF\NinjaPdf;
|
|
||||||
use App\Utils\HtmlEngine;
|
|
||||||
use App\Utils\Ninja;
|
|
||||||
use App\Utils\PhantomJS\Phantom;
|
|
||||||
use App\Utils\Traits\MakesHash;
|
|
||||||
use App\Utils\Traits\MakesInvoiceHtml;
|
|
||||||
use App\Utils\Traits\NumberFormatter;
|
|
||||||
use App\Utils\Traits\Pdf\PDF;
|
|
||||||
use App\Utils\Traits\Pdf\PageNumbering;
|
|
||||||
use App\Utils\Traits\Pdf\PdfMaker;
|
|
||||||
use App\Utils\VendorHtmlEngine;
|
|
||||||
use Illuminate\Bus\Queueable;
|
|
||||||
use Illuminate\Contracts\Queue\ShouldQueue;
|
|
||||||
use Illuminate\Foundation\Bus\Dispatchable;
|
|
||||||
use Illuminate\Queue\InteractsWithQueue;
|
|
||||||
use Illuminate\Queue\SerializesModels;
|
|
||||||
use Illuminate\Support\Facades\App;
|
|
||||||
use Illuminate\Support\Facades\Lang;
|
|
||||||
use Illuminate\Support\Facades\Storage;
|
|
||||||
use setasign\Fpdi\PdfParser\StreamReader;
|
|
||||||
|
|
||||||
class CreatePurchaseOrderPdf implements ShouldQueue
|
class CreatePurchaseOrderPdf implements ShouldQueue
|
||||||
{
|
{
|
||||||
@ -56,9 +58,9 @@ class CreatePurchaseOrderPdf implements ShouldQueue
|
|||||||
|
|
||||||
private $disk;
|
private $disk;
|
||||||
|
|
||||||
public $invitation;
|
public PurchaseOrderInvitation $invitation;
|
||||||
|
|
||||||
|
|
||||||
|
public Vendor $vendor;
|
||||||
/**
|
/**
|
||||||
* Create a new job instance.
|
* Create a new job instance.
|
||||||
*
|
*
|
||||||
|
@ -141,6 +141,10 @@ class PurchaseOrder extends BaseModel
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getEntityType()
|
||||||
|
{
|
||||||
|
return self::class;
|
||||||
|
}
|
||||||
|
|
||||||
public function assigned_user()
|
public function assigned_user()
|
||||||
{
|
{
|
||||||
|
@ -27,7 +27,12 @@ class VendorContactFactory extends Factory
|
|||||||
'first_name' => $this->faker->firstName(),
|
'first_name' => $this->faker->firstName(),
|
||||||
'last_name' => $this->faker->lastName(),
|
'last_name' => $this->faker->lastName(),
|
||||||
'phone' => $this->faker->phoneNumber(),
|
'phone' => $this->faker->phoneNumber(),
|
||||||
|
'email_verified_at' => now(),
|
||||||
'email' => $this->faker->unique()->safeEmail(),
|
'email' => $this->faker->unique()->safeEmail(),
|
||||||
|
'send_email' => true,
|
||||||
|
'password' => bcrypt('password'),
|
||||||
|
'remember_token' => \Illuminate\Support\Str::random(10),
|
||||||
|
'contact_key' => \Illuminate\Support\Str::random(32),
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user