1
chenjingwu
2024-04-10 3610be47569bede28c074122907eb556b8a682e7
force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
@@ -1867,13 +1867,13 @@
            var selectvlue = this.SelectedNewProduct;
            var Listvalue = this.jzDataToBeproduct;
            this.jzDataToBeproduct = additionaljzProductLogic(selectvlue,Listvalue,this.oppInfo.CurrencyIsoCode,this.quo.IsQuoteTrial__c);
            var jzDataToBeproductStr = JSON.stringify(this.jzDataToBeproduct);
            addOptions({str: jzDataToBeproductStr}).then(result=>{
                console.log('before');
                console.log(jzDataToBeproductStr);
                this.jzDataToBeproduct = JSON.parse(result);
                console.log('after123123213');
                console.log(result);
            var idList = [];
            this.jzDataToBeproduct.forEach(item=>{
                idList.push(item.pageObject.PricebookEntry.Product2Id);
            });
            addOptions({idList: idList}).then(result=>{
                console.log('result');
                this.addOptionsLogic(result);
                if(alertExp){
                    this.Alert(alertExp,'error');
                }
@@ -1888,6 +1888,14 @@
            
        }
    }
    addOptionsLogic(result){
        console.log(result);
        this.jzDataToBeproduct.forEach(item=>{
            if(result.get(item.pageObject.PricebookEntry.Product2Id)){
                item.Learning_CommunityOptions = result.get(item.pageObject.PricebookEntry.Product2Id);
            }
        });
    }
    //新增报价产品模态框取消按钮
    cancelProduct() {
        this.showproductfalg = false;