Merge pull request 'Added skip on completed serial and warning on mismatch invoice' (#403) from ranjith-dev into master
All checks were successful
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 15s

Reviewed-on: #403
This commit was merged in pull request #403.
This commit is contained in:
2026-02-26 03:03:34 +00:00

View File

@@ -353,6 +353,12 @@ class InvoiceValidationImporter extends Importer
$curPanelBoxSerialNumber = $record->panel_box_serial_number ?? null;
}
if ($record->scanned_status == 'Scanned') {
return null;
} elseif ($record->invoice_number != $invoiceNumber) {
throw new RowImportFailedException('Invoice number mismatch with existing record!');
}
// if ($hadPumpQr == $hasPumpQr && $hadPumpSetQr == $hasPumpSetQr)
if ($hasMotorQr || $hasPumpQr || $hasPumpSetQr || $hasCapacitorQr) {
$scanCnt = $curMotorQr ? $scanCnt + 1 : $scanCnt;