mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-03 09:24:33 -04:00
Remove make dir for Storage::
This commit is contained in:
parent
ab71be42a0
commit
2f4e129cf0
@ -213,9 +213,9 @@ class CreateEntityPdf implements ShouldQueue
|
|||||||
|
|
||||||
if ($pdf) {
|
if ($pdf) {
|
||||||
try {
|
try {
|
||||||
if (! Storage::disk($this->disk)->exists($path)) {
|
// if (! Storage::disk($this->disk)->exists($path)) {
|
||||||
Storage::disk($this->disk)->makeDirectory($path, 0775);
|
// Storage::disk($this->disk)->makeDirectory($path, 0775);
|
||||||
}
|
// }
|
||||||
|
|
||||||
Storage::disk($this->disk)->put($file_path, $pdf, 'public');
|
Storage::disk($this->disk)->put($file_path, $pdf, 'public');
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
|
4
app/Jobs/Vendor/CreatePurchaseOrderPdf.php
vendored
4
app/Jobs/Vendor/CreatePurchaseOrderPdf.php
vendored
@ -100,8 +100,8 @@ class CreatePurchaseOrderPdf implements ShouldQueue
|
|||||||
|
|
||||||
try{
|
try{
|
||||||
|
|
||||||
if(!Storage::disk($this->disk)->exists($this->path))
|
// if(!Storage::disk($this->disk)->exists($this->path))
|
||||||
Storage::disk($this->disk)->makeDirectory($this->path, 0775);
|
// Storage::disk($this->disk)->makeDirectory($this->path, 0775);
|
||||||
|
|
||||||
Storage::disk($this->disk)->put($this->file_path, $pdf, 'public');
|
Storage::disk($this->disk)->put($this->file_path, $pdf, 'public');
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@ class Backup extends BaseModel
|
|||||||
$filename = now()->format('Y_m_d').'_'.md5(time()).'.html';
|
$filename = now()->format('Y_m_d').'_'.md5(time()).'.html';
|
||||||
$file_path = $path.$filename;
|
$file_path = $path.$filename;
|
||||||
|
|
||||||
Storage::disk(config('filesystems.default'))->makeDirectory($path, 0775);
|
// Storage::disk(config('filesystems.default'))->makeDirectory($path, 0775);
|
||||||
|
|
||||||
Storage::disk(config('filesystems.default'))->put($file_path, $html);
|
Storage::disk(config('filesystems.default'))->put($file_path, $html);
|
||||||
|
|
||||||
|
@ -82,7 +82,8 @@ class ActivityRepository extends BaseRepository
|
|||||||
$backup = new Backup();
|
$backup = new Backup();
|
||||||
$entity->load('client');
|
$entity->load('client');
|
||||||
$contact = $entity->client->primary_contact()->first();
|
$contact = $entity->client->primary_contact()->first();
|
||||||
$backup->html_backup = $this->generateHtml($entity);
|
$backup->html_backup = '';
|
||||||
|
// $backup->html_backup = $this->generateHtml($entity);
|
||||||
$backup->amount = $entity->amount;
|
$backup->amount = $entity->amount;
|
||||||
$backup->activity_id = $activity->id;
|
$backup->activity_id = $activity->id;
|
||||||
$backup->json_backup = '';
|
$backup->json_backup = '';
|
||||||
|
@ -105,9 +105,10 @@ class GenerateDeliveryNote
|
|||||||
info($maker->getCompiledHTML());
|
info($maker->getCompiledHTML());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! Storage::disk($this->disk)->exists($this->invoice->client->invoice_filepath($invitation))) {
|
// if (! Storage::disk($this->disk)->exists($this->invoice->client->invoice_filepath($invitation))) {
|
||||||
Storage::disk($this->disk)->makeDirectory($this->invoice->client->invoice_filepath($invitation), 0775);
|
// Storage::disk($this->disk)->makeDirectory($this->invoice->client->invoice_filepath($invitation), 0775);
|
||||||
}
|
// }
|
||||||
|
|
||||||
Storage::disk($this->disk)->put($file_path, $pdf, 'public');
|
Storage::disk($this->disk)->put($file_path, $pdf, 'public');
|
||||||
|
|
||||||
return $file_path;
|
return $file_path;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user