mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-31 23:24:36 -04:00
Fixes for viewing documents
This commit is contained in:
parent
185f48a758
commit
04d2726c87
@ -46,7 +46,14 @@ class CloneQuoteToInvoiceFactory
|
|||||||
$invoice->date = now()->format('Y-m-d');
|
$invoice->date = now()->format('Y-m-d');
|
||||||
$invoice->balance = 0;
|
$invoice->balance = 0;
|
||||||
$invoice->deleted_at = null;
|
$invoice->deleted_at = null;
|
||||||
|
$invoice->next_send_date = null;
|
||||||
|
$invoice->reminder1_sent = null;
|
||||||
|
$invoice->reminder2_sent = null;
|
||||||
|
$invoice->reminder3_sent = null;
|
||||||
|
$invoice->reminder_last_sent = null;
|
||||||
|
$invoice->last_sent_date = null;
|
||||||
|
$invoice->last_viewed = null;
|
||||||
|
|
||||||
return $invoice;
|
return $invoice;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,6 +15,7 @@ namespace App\Http\Controllers\ClientPortal;
|
|||||||
use App\Http\Controllers\Controller;
|
use App\Http\Controllers\Controller;
|
||||||
use App\Http\Requests\ClientPortal\Documents\ShowDocumentRequest;
|
use App\Http\Requests\ClientPortal\Documents\ShowDocumentRequest;
|
||||||
use App\Http\Requests\Document\DownloadMultipleDocumentsRequest;
|
use App\Http\Requests\Document\DownloadMultipleDocumentsRequest;
|
||||||
|
use App\Libraries\MultiDB;
|
||||||
use App\Models\Document;
|
use App\Models\Document;
|
||||||
use App\Utils\TempFile;
|
use App\Utils\TempFile;
|
||||||
use App\Utils\Traits\MakesHash;
|
use App\Utils\Traits\MakesHash;
|
||||||
@ -55,6 +56,8 @@ class DocumentController extends Controller
|
|||||||
|
|
||||||
public function publicDownload(string $document_hash)
|
public function publicDownload(string $document_hash)
|
||||||
{
|
{
|
||||||
|
MultiDB::documentFindAndSetDb($document_hash);
|
||||||
|
|
||||||
$document = Document::where('hash', $document_hash)->firstOrFail();
|
$document = Document::where('hash', $document_hash)->firstOrFail();
|
||||||
|
|
||||||
$headers = [];
|
$headers = [];
|
||||||
|
@ -124,10 +124,10 @@ class QuoteService
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if ($this->quote->client->getSetting('auto_archive_quote')) {
|
// if ($this->quote->client->getSetting('auto_archive_quote')) {
|
||||||
$quote_repo = new QuoteRepository();
|
// $quote_repo = new QuoteRepository();
|
||||||
$quote_repo->archive($this->quote);
|
// $quote_repo->archive($this->quote);
|
||||||
}
|
// }
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user