From fc9a8b1f0ef2836d72467819013118f1e589e982 Mon Sep 17 00:00:00 2001 From: Yoga Pangestu Date: Sun, 19 Jul 2026 19:06:58 +0700 Subject: [PATCH] fix: update error keys in CuttingService, ProductService, and RawMaterialService to use 's3_keys' instead of 'images' --- app/Services/Manage/CuttingService.php | 2 +- app/Services/Master/ProductService.php | 4 ++-- app/Services/Master/RawMaterialService.php | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/Services/Manage/CuttingService.php b/app/Services/Manage/CuttingService.php index 5c3a1a2..b3a6856 100644 --- a/app/Services/Manage/CuttingService.php +++ b/app/Services/Manage/CuttingService.php @@ -984,7 +984,7 @@ public function quickCreateProduct(array $validated): array null, $maxVariantImages, required: false, - errorKey: "variants.{$index}.images", + errorKey: "variants.{$index}.s3_keys", s3Keys: $variantData['s3_keys'] ?? null, ); diff --git a/app/Services/Master/ProductService.php b/app/Services/Master/ProductService.php index 3337e44..74c1357 100644 --- a/app/Services/Master/ProductService.php +++ b/app/Services/Master/ProductService.php @@ -815,7 +815,7 @@ private function syncVariantImages( $variantData['remove_media_ids'] ?? null, self::MAX_VARIANT_IMAGES, required: true, - errorKey: "variants.{$index}.images", + errorKey: "variants.{$index}.s3_keys", s3Keys: $variantData['s3_keys'] ?? null, ); } @@ -835,7 +835,7 @@ private function syncRequestVariantImages( $variantData['remove_media_ids'] ?? null, self::MAX_VARIANT_IMAGES, required: $required, - errorKey: "variants.{$index}.images", + errorKey: "variants.{$index}.s3_keys", s3Keys: $variantData['s3_keys'] ?? null, ); } diff --git a/app/Services/Master/RawMaterialService.php b/app/Services/Master/RawMaterialService.php index 3ebec1e..1ef1099 100644 --- a/app/Services/Master/RawMaterialService.php +++ b/app/Services/Master/RawMaterialService.php @@ -515,7 +515,7 @@ private function syncPriceImages(RawMaterialPrice $price, array $priceData, int $priceData['remove_media_ids'] ?? null, self::MAX_VARIANT_IMAGES, required: true, - errorKey: "prices.{$index}.images", + errorKey: "prices.{$index}.s3_keys", s3Keys: $priceData['s3_keys'] ?? null, ); } @@ -535,7 +535,7 @@ private function syncRequestPriceImages( $priceData['remove_media_ids'] ?? null, self::MAX_VARIANT_IMAGES, required: $required, - errorKey: "prices.{$index}.images", + errorKey: "prices.{$index}.s3_keys", s3Keys: $priceData['s3_keys'] ?? null, ); }