diff --git a/app/Filament/Resources/InvoiceValidationResource/Pages/CreateInvoiceValidation.php b/app/Filament/Resources/InvoiceValidationResource/Pages/CreateInvoiceValidation.php index db6a177..61fe91d 100644 --- a/app/Filament/Resources/InvoiceValidationResource/Pages/CreateInvoiceValidation.php +++ b/app/Filament/Resources/InvoiceValidationResource/Pages/CreateInvoiceValidation.php @@ -790,6 +790,8 @@ class CreateInvoiceValidation extends CreateRecord ->send(); $this->dispatch('playNotificationSound'); + InvoiceValidation::where('invoice_number', $invoiceNumber)->where('plant_id', $plantId)->update(['updated_by' => $operatorName]); // 'updated_at' => now(), + // Update total quantity in the form $totalQuantity = InvoiceValidation::where('invoice_number', $invoiceNumber)->where('plant_id', $plantId)->count(); $scannedQuantity = InvoiceValidation::where('invoice_number', $invoiceNumber)->whereNotNull('serial_number')->where('serial_number', '!=', '')->where('plant_id', $plantId)->count(); @@ -1266,6 +1268,8 @@ class CreateInvoiceValidation extends CreateRecord $this->dispatch('playNotificationSound'); + InvoiceValidation::where('invoice_number', $invoiceNumber)->where('plant_id', $plantId)->update(['updated_by' => $operatorName]); // 'updated_at' => now(), + // Update total quantity in the form $totalQuantity = InvoiceValidation::where('invoice_number', $invoiceNumber)->where('plant_id', $plantId)->count(); $scannedQuantity = InvoiceValidation::where('invoice_number', $invoiceNumber)->where('scanned_status', 'Scanned')->where('plant_id', $plantId)->count();