Skip to content

Commit af0602f

Browse files
committed
feat: added missing update product payload dtos
1 parent 8136781 commit af0602f

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,6 @@ obj/
44
riderModule.iml
55
/_ReSharper.Caches/
66
.idea
7-
publish
7+
publish
8+
**/*.DotSettings
9+
**/*.user

Controllers/ProductsController.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,11 @@ public async Task<IActionResult> UpdateProduct(Guid id, UpdateProductDto updateP
8989
existingProduct.Description = updateProductDto.Description ?? string.Empty;
9090
existingProduct.ModifiedById = updateProductDto.ModifiedById;
9191
existingProduct.Modified = DateTime.UtcNow;
92+
existingProduct.SKU = updateProductDto.SKU;
93+
existingProduct.Status = updateProductDto.Status;
94+
existingProduct.QuantityInStock = updateProductDto.QuantityInStock;
95+
existingProduct.IsActive = updateProductDto.IsActive;
96+
existingProduct.CategoryId = updateProductDto.CategoryId;
9297

9398
await _productService.UpdateAsync(existingProduct);
9499

0 commit comments

Comments
 (0)