Added duplicate process order with coil number warning message
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 11s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 12s
Gemini PR Review / Gemini PR Review (pull_request) Failing after 16s
Laravel Pint / pint (pull_request) Successful in 3m13s
Laravel Larastan / larastan (pull_request) Failing after 3m24s
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 11s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 12s
Gemini PR Review / Gemini PR Review (pull_request) Failing after 16s
Laravel Pint / pint (pull_request) Successful in 3m13s
Laravel Larastan / larastan (pull_request) Failing after 3m24s
This commit is contained in:
@@ -176,7 +176,13 @@ class ProcessOrderImporter extends Importer
|
|||||||
$existing = ProcessOrder::where('plant_id', $plantId)->where('process_order', $processOrder)->first();
|
$existing = ProcessOrder::where('plant_id', $plantId)->where('process_order', $processOrder)->first();
|
||||||
|
|
||||||
if ($existing) {
|
if ($existing) {
|
||||||
|
$existing = ProcessOrder::where('plant_id', $plantId)->where('process_order', $processOrder)->where('coil_number', $coilNo)->first();
|
||||||
|
|
||||||
|
if ($existing) {
|
||||||
|
$warnMsg[] = 'Process Order with coil number already exists!';
|
||||||
|
} else {
|
||||||
$warnMsg[] = 'Process Order already exists!';
|
$warnMsg[] = 'Process Order already exists!';
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
$warnMsg[] = 'New process order found!';
|
$warnMsg[] = 'New process order found!';
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user