removed logic submerisible motor and pump in sticker reprint
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 11s
Gemini PR Review / review (pull_request) Failing after 24s
Laravel Pint / pint (pull_request) Successful in 2m29s
Laravel Larastan / larastan (pull_request) Failing after 3m6s

This commit is contained in:
dhanabalan
2025-12-31 09:20:15 +05:30
parent 3bcc351fa6
commit f0141c4f7e
2 changed files with 159 additions and 147 deletions

View File

@@ -73,13 +73,25 @@ class ProductionStickerReprintController extends Controller
}
else
{
if ($item->category == 'Submersible Motor')
{
$copies = 1;
}
elseif ($item->category == 'Submersible Pump')
{
$copies = 1;
// if ($item->category == 'Submersible Motor')
// {
// $copies = 1;
// }
// elseif ($item->category == 'Submersible Pump')
// {
// $copies = 1;
// }
$copies = 1;
if ($serialNumberRaw) {
// Check if serial ends with /m or /M, optionally followed by |
if (preg_match('/\/[mM](\|)?$/', $serialNumberRaw)) {
$copies = 1;
}
// Check if serial ends with /p or /P, optionally followed by |
elseif (preg_match('/\/[pP](\|)?$/', $serialNumberRaw)) {
$copies = 1;
}
}
}