fix: map category from backend relation/name to frontend display
This commit is contained in:
1 parent
2103b105ac
commit
804a596711
1 file changed
+1
-1
@@ -34,7 +34,7 @@ export class ProductService {
|
||||
shortDescription: data.shortDescription,
|
||||
price: data.priceDisplay || `${data.priceValue.toLocaleString('fa-IR')} تومان`,
|
||||
priceValue: Number(data.priceValue),
|
||||
category: data.category,
|
||||
category: data.category?.name || data.category || data.categorySlug || '',
|
||||
categorySlug: data.categorySlug,
|
||||
unit: data.unit,
|
||||
packageSize: data.packageSize,
|
||||
|
||||
Reference in new issue
Block a user