attribute seeder

This commit is contained in:
2026-01-27 15:38:48 +03:30
parent e2b065aa2b
commit 355d4afaa2
7 changed files with 129 additions and 7 deletions
+2 -2
View File
@@ -279,7 +279,7 @@ export class OrderService {
}
async updateStatus(orderId: string, newStatus: OrderStatusEnum) {
const order = await this.findOrderOrFail(orderId)
order.status = newStatus
@@ -344,7 +344,7 @@ export class OrderService {
em.persist(order)
for (const item of items) {
const product = products.find(p => Number(p.id) === item.productId)
const product = products.find(p => Number(p.id) === Number(item.productId))
if (!product) {
throw new BadRequestException("Product not found!")