From 8b71bcab2f313f32c63b0c54f5b6966f60329b85 Mon Sep 17 00:00:00 2001 From: amirghasempoor Date: Sat, 21 Dec 2024 14:44:21 +0330 Subject: [PATCH] add nullable for v2 --- app/Models/RoadItemsProject.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Models/RoadItemsProject.php b/app/Models/RoadItemsProject.php index 9c3c5ef0..e09a4bfe 100644 --- a/app/Models/RoadItemsProject.php +++ b/app/Models/RoadItemsProject.php @@ -130,8 +130,8 @@ class RoadItemsProject extends Model 'activity_time' => $attributes['activity_time'], 'activity_date_time' => $attributes['activity_date']." ".$attributes['activity_time'], 'is_new' => 1, - 'cmms_machine_id' => $attributes['cmms_machine_id'], - 'cmms_machine_code' => $attributes['cmms_machine_code'], + 'cmms_machine_id' => $attributes['cmms_machine_id'] ?? null, + 'cmms_machine_code' => $attributes['cmms_machine_code'] ?? null, ]); // if ($info_item->needs_image) {