mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fix for sidebar history
This commit is contained in:
parent
c51beb5f57
commit
2c3176544a
@ -3,6 +3,7 @@
|
||||
namespace App\Http\Requests;
|
||||
|
||||
use App\Models\Invoice;
|
||||
use App\Libraries\HistoryUtils;
|
||||
|
||||
class InvoiceRequest extends EntityRequest
|
||||
{
|
||||
@ -15,7 +16,6 @@ class InvoiceRequest extends EntityRequest
|
||||
*/
|
||||
public function authorize()
|
||||
{
|
||||
|
||||
$invoice = parent::entity();
|
||||
|
||||
if ($invoice && $invoice->isQuote())
|
||||
@ -46,9 +46,11 @@ class InvoiceRequest extends EntityRequest
|
||||
if(request()->is('quotes/*') && request()->isMethod('get') && !$this->user()->can('view', ENTITY_QUOTE))
|
||||
return false;
|
||||
|
||||
HistoryUtils::trackViewed($invoice);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
public function entity()
|
||||
{
|
||||
$invoice = parent::entity();
|
||||
|
Loading…
x
Reference in New Issue
Block a user