diff options
| author | it-fixcomart <it@fixcomart.co.id> | 2024-09-03 12:19:44 +0700 |
|---|---|---|
| committer | it-fixcomart <it@fixcomart.co.id> | 2024-09-03 12:19:44 +0700 |
| commit | 105ffc8cfa4d8efd51bb7654bfdd279df2a64779 (patch) | |
| tree | 857da42c4c512a5860b20a99508662d55cb2552c /src/utils | |
| parent | dab7f8a1ebd135d9335f1a53346c91d32a2be9f9 (diff) | |
<iman> update tempt
Diffstat (limited to 'src/utils')
| -rw-r--r-- | src/utils/solrMapping.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/utils/solrMapping.js b/src/utils/solrMapping.js index 637d7c09..15bf3afb 100644 --- a/src/utils/solrMapping.js +++ b/src/utils/solrMapping.js @@ -14,11 +14,13 @@ export const promoMappingSolr = (promotions) => { price: promotion.price_f, sequence: promotion.sequence_i, total_qty: promotion.total_qty_i, - products: JSON.parse(promotion.products_s), + products: JSON.parse(promotion.products_s) || '', product_id: promotion.product_ids[0], qty_sold_f:promotion.total_qty_sold_f, - free_products: JSON.parse(promotion.free_products_s), + free_products: JSON.parse(promotion.free_products_s) }; + console.log("productMapped",productMapped) + // console.log("promotions",promotions) return productMapped; }) }; |
