From d9160750064e7a1a980c0901dcead42167bfb999 Mon Sep 17 00:00:00 2001
From: chenjingwu <chenjingwu@prec-tech.com>
Date: 星期三, 10 四月 2024 16:46:10 +0800
Subject: [PATCH] 1

---
 force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js b/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
index 824bd41..c1dda24 100644
--- a/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
+++ b/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
@@ -1872,8 +1872,7 @@
                 idList.push(item.pageObject.PricebookEntry.Product2Id);
             });
             addOptions({idList: idList}).then(result=>{
-                console.log('result');
-                this.addOptionsLogic(JSON.parse(JSON.stringify(result)));
+                this.addOptionsLogic(result);
                 if(alertExp){
                     this.Alert(alertExp,'error');
                 }
@@ -1889,10 +1888,13 @@
         }
     }
     addOptionsLogic(result){
+        const options = Object.entries(result).map(([key, value]) => ({
+            label: key, 
+            value: value
+        }));
         this.jzDataToBeproduct.forEach(item=>{
-            console.log(result);
             if(result){
-                item.Learning_CommunityOptions = result.get(item.pageObject.PricebookEntry.Product2Id);
+                item.Learning_CommunityOptions = options.get(item.pageObject.PricebookEntry.Product2Id);
             }
         });
     }

--
Gitblit v1.9.1