From 0e7c1caf05772a9727f5525a7d1b0043006df461 Mon Sep 17 00:00:00 2001 From: dhanabalan Date: Mon, 7 Sep 2026 11:28:32 +0530 Subject: [PATCH 1/3] Added status column in panel box validation table --- ...28_add_status_to_panel_box_validations.php | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 database/migrations/2026_09_07_105328_add_status_to_panel_box_validations.php diff --git a/database/migrations/2026_09_07_105328_add_status_to_panel_box_validations.php b/database/migrations/2026_09_07_105328_add_status_to_panel_box_validations.php new file mode 100644 index 0000000..3b6065f --- /dev/null +++ b/database/migrations/2026_09_07_105328_add_status_to_panel_box_validations.php @@ -0,0 +1,31 @@ + Date: Mon, 7 Sep 2026 11:29:21 +0530 Subject: [PATCH 2/3] Added status column in panel box validation model file --- app/Models/PanelBoxValidation.php | 1 + 1 file changed, 1 insertion(+) diff --git a/app/Models/PanelBoxValidation.php b/app/Models/PanelBoxValidation.php index 1801cd3..1632e0c 100644 --- a/app/Models/PanelBoxValidation.php +++ b/app/Models/PanelBoxValidation.php @@ -31,6 +31,7 @@ class PanelBoxValidation extends Model 'panel_box_code', 'inspection_lot_number', 'rework_count', + 'status', 'created_by', 'updated_by' ]; From 1dc2d8a2068e149dad2c40f3e04a93b96f117dc4 Mon Sep 17 00:00:00 2001 From: dhanabalan Date: Mon, 7 Sep 2026 11:31:45 +0530 Subject: [PATCH 3/3] Added status logic in save panel check list page --- app/Livewire/PanelCheckList.php | 31 ++----------------------------- 1 file changed, 2 insertions(+), 29 deletions(-) diff --git a/app/Livewire/PanelCheckList.php b/app/Livewire/PanelCheckList.php index 6347bf3..a95b89f 100644 --- a/app/Livewire/PanelCheckList.php +++ b/app/Livewire/PanelCheckList.php @@ -218,7 +218,7 @@ public $records = []; } } else{ - $qualityValidation = PanelBoxValidation::create([ + $qualityValidation = PanelBoxValidation::create([ 'plant_id' => $this->data['plant_id'] ?? null, 'line_id' => $this->data['line_id'] ?? null, 'sticker_master_id' => $this->data['sticker_master_id'] ?? null, @@ -238,36 +238,12 @@ public $records = []; 'panel_box_serial_number' => $this->data['panel_box_serial_number'] ?? null, 'panel_box_code' => $this->data['panel_box_code'] ?? null, 'inspection_lot_number' => $this->data['inspection_lot_number'] ?? null, + 'status' => $this->selectForNotOk ? 'NotOk' : 'Ok', 'created_by' => $this->data['created_by'] ?? null, 'updated_by' => $this->data['updated_by'] ?? null, ]); } - // $qualityValidation = PanelBoxValidation::create([ - // 'plant_id' => $this->data['plant_id'] ?? null, - // 'line_id' => $this->data['line_id'] ?? null, - // 'sticker_master_id' => $this->data['sticker_master_id'] ?? null, - // 'production_order' => $this->data['production_order'] ?? null, - // 'serial_number' => $this->data['serial_number'] ?? null, - // 'serial_number_panel' => $this->data['serial_number_panel'] ?? null, - // 'pack_slip_panel' => $this->data['pack_slip_panel'] ?? null, - // 'name_plate_panel' => $this->data['name_plate_panel'] ?? null, - // 'tube_sticker_panel' => $this->data['tube_sticker_panel'] ?? null, - // 'warranty_card_panel' => $this->data['warranty_card_panel'] ?? null, - // 'part_validation1' => $this->data['part_validation1'] ?? null, - // 'part_validation2' => $this->data['part_validation2'] ?? null, - // 'part_validation3' => $this->data['part_validation3'] ?? null, - // 'part_validation4' => $this->data['part_validation4'] ?? null, - // 'part_validation5' => $this->data['part_validation5'] ?? null, - // 'panel_box_supplier' => $this->data['panel_box_supplier'] ?? null, - // 'panel_box_serial_number' => $this->data['panel_box_serial_number'] ?? null, - // 'panel_box_code' => $this->data['panel_box_code'] ?? null, - // 'inspection_lot_number' => $this->data['inspection_lot_number'] ?? null, - // 'created_by' => $this->data['created_by'] ?? null, - // 'updated_by' => $this->data['updated_by'] ?? null, - // ]); - - if (! $qualityValidation || ! $qualityValidation->exists) { Notification::make() ->title('Failed to save Panel Box Validation') @@ -400,15 +376,12 @@ public $records = []; if ($mailRule && !empty($mailRule->email)) { - // $mail = Mail::to($mailRule->email); - $toEmails = array_filter( array_map('trim', explode(',', $mailRule->email)) ); $mail = Mail::to($toEmails); - if (!empty($mailRule->cc_emails)) { $ccEmails = array_filter( array_map('trim', explode(',', $mailRule->cc_emails))