Ketika user ingin update data product melalui API Update Product by Code muncul response error seperti pada di bawah ini.
{"Message":"Value cannot be null. (Parameter 'source')","StackTrace":" at System.Linq.ThrowHelper.ThrowArgumentNullException(ExceptionArgument argument)\r\n at System.Linq.Enumerable.Where[TSource](IEnumerable1 source, Func
2 predicate)\r\n at POS.BLL.ObjectManager.ProductManager.RemoveProductImage(Guid ID, List1 newProductImage) in /builds/dealpos/pos-asp-netcore/src/POS.BLL/ObjectManager/ProductManager.cs:line 632\\\\r\\\\n at POS.BLL.ObjectManager.ProductManager.Update(Product p, List
1 variants, List1 listTags, POSIdentity identity, List
1 listStock, List1 productImages, List
1 productLocations) in /builds/dealpos/pos-asp-netcore/src/POS.BLL/ObjectManager/ProductManager.cs:line 538\r\n at POS.BLL.ObjectManager.ProductManager.Process(Product p, List1 variants, POSIdentity identity, List
1 listTags, List1 listStock, Guid temporaryID, List
1 productImages, List`1 productLocations) in /builds/dealpos/pos-asp-netcore/src/POS.BLL/ObjectManager/ProductManager.cs:line 85\r\n at POS.BLL.Processor.ProductProcessor.SubmitProduct(ProductFormVM model, POSIdentity _identity) in /builds/dealpos/pos-asp-netcore/src/POS.BLL/Processor/ProductProcessor.cs:line 177\r\n at POS.WEB.Controllers.v3.ProductController.Put(JsonElement request) in /builds/dealpos/pos-asp-netcore/src/POS.WEB/Controllers/v3/ProductController.cs:line 288"}
Berikut adalah parameter yang diisi :
{
"Category": "Raket Badminton",
"Name": "Yonex Raket Badminton Astrox 88s Pro + Tasj",
"SupplierName": "Pemasok Umum",
"BrandName": "Astrox",
"Code": "23524",
"Variants": [
{
"Code": "4550086904458",
"UnitPrice": 2700000,
"UnitCost": 2100000,
"UnitStock": 1,
"Model": "CMGO"
},