Merge pull request 'Updated process order import function for testing purpose.' (#427) from ranjith-dev into master
All checks were successful
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 16s

Reviewed-on: #427
This commit was merged in pull request #427.
This commit is contained in:
2026-03-01 08:26:39 +00:00

View File

@@ -221,6 +221,14 @@ class ProcessOrderImporter extends Importer
$updatedBy = Filament::auth()->user()->name;
}
$existing = ProcessOrder::where('plant_id', $plantId)->where('process_order', $processOrder)->first();
if ($existing) {
$warnMsg[] = 'Process Order already exists!';
} else {
$warnMsg[] = 'New process order found!';
}
if (! empty($warnMsg)) {
throw new RowImportFailedException(implode(', ', $warnMsg));
}