Update merge actions to bulk_print

This commit is contained in:
David Bomba 2022-10-31 16:46:51 +11:00
parent 29ceb1f131
commit 6ebf5ad31b
4 changed files with 4 additions and 4 deletions

View File

@ -535,7 +535,7 @@ class CreditController extends BaseController
return response()->json(['message' => ctrans('texts.sent_message')], 200);
}
if($action == 'merge' && auth()->user()->can('view', $credits->first())){
if($action == 'bulk_print' && auth()->user()->can('view', $credits->first())){
$paths = $credits->map(function ($credit){
return $credit->service()->getCreditPdf($credit->invitations->first());

View File

@ -589,7 +589,7 @@ class InvoiceController extends BaseController
}
if($action == 'merge' && auth()->user()->can('view', $invoices->first())){
if($action == 'bulk_print' && auth()->user()->can('view', $invoices->first())){
$paths = $invoices->map(function ($invoice){
return $invoice->service()->getInvoicePdf();

View File

@ -516,7 +516,7 @@ class PurchaseOrderController extends BaseController
return response()->json(['message' => ctrans('texts.sent_message')], 200);
}
if($action == 'merge' && auth()->user()->can('view', $purchase_orders->first())){
if($action == 'bulk_print' && auth()->user()->can('view', $purchase_orders->first())){
$paths = $purchase_orders->map(function ($purchase_order){
return $purchase_order->service()->getPurchaseOrderPdf();

View File

@ -562,7 +562,7 @@ class QuoteController extends BaseController
return $this->listResponse(Quote::withTrashed()->whereIn('id', $this->transformKeys($ids))->company());
}
if($action == 'merge' && auth()->user()->can('view', $quotes->first())){
if($action == 'bulk_print' && auth()->user()->can('view', $quotes->first())){
$paths = $quotes->map(function ($quote){
return $quote->service()->getQuotePdf();