Refactored invoice processing logic to ensure file deletion occurs correctly and added additional condition for marking serial numbers.
This commit is contained in:
@@ -1024,9 +1024,9 @@ class CreateInvoiceValidation extends CreateRecord
|
|||||||
->send();
|
->send();
|
||||||
|
|
||||||
$this->dispatch('playWarnSound');
|
$this->dispatch('playWarnSound');
|
||||||
// if ($disk->exists($filePath)) {
|
if ($disk->exists($filePath)) {
|
||||||
// $disk->delete($filePath);
|
$disk->delete($filePath);
|
||||||
// }
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1392,7 +1392,6 @@ class CreateInvoiceValidation extends CreateRecord
|
|||||||
->send();
|
->send();
|
||||||
|
|
||||||
$this->dispatch('playWarnSound');
|
$this->dispatch('playWarnSound');
|
||||||
|
|
||||||
if ($disk->exists($filePath)) {
|
if ($disk->exists($filePath)) {
|
||||||
$disk->delete($filePath);
|
$disk->delete($filePath);
|
||||||
}
|
}
|
||||||
@@ -3479,6 +3478,13 @@ class CreateInvoiceValidation extends CreateRecord
|
|||||||
$isMarkC = false;
|
$isMarkC = false;
|
||||||
$isMarkPs = false;
|
$isMarkPs = false;
|
||||||
}
|
}
|
||||||
|
else if (!$hasMotorQr && !$hasPumpQr && !$hasPumpSetQr && $hasCapacitorQr)
|
||||||
|
{
|
||||||
|
$isMarkM = false;
|
||||||
|
$isMarkP = false;
|
||||||
|
$isMarkC = true;
|
||||||
|
$isMarkPs = false;
|
||||||
|
}
|
||||||
|
|
||||||
if ($isMarkM) {
|
if ($isMarkM) {
|
||||||
if (!$hasMotorQr)
|
if (!$hasMotorQr)
|
||||||
|
|||||||
Reference in New Issue
Block a user