From d29f75b84fccd06917fb8e2c2ee70e9d76f868cd Mon Sep 17 00:00:00 2001
From: chenjingwu <chenjingwu@prec-tech.com>
Date: 星期四, 11 四月 2024 20:15:54 +0800
Subject: [PATCH] 123
---
force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js | 26 ++++++++++++++++++++++----
1 files changed, 22 insertions(+), 4 deletions(-)
diff --git a/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js b/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
index f6d9e09..979162d 100644
--- a/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
+++ b/force-app/main/default/lwc/lexNewQuoteEntry/lexNewQuoteEntry.js
@@ -84,7 +84,7 @@
import selectUpdateFiexedpriceData from '@salesforce/apex/QuoteTrialController.selectUpdateFiexedpriceData';
import selectUpdateQuoteLineItemData from '@salesforce/apex/QuoteTrialController.selectUpdateQuoteLineItemData';
import lwcCSS from '@salesforce/resourceUrl/lwcCSS';
-import {yingYanCheck,qwe,lineDown,lineUp,localParseInt,toNum,initDataTableToBeproductConfig,saveEvoluationLogic,oppInfosave,quoLineItemsave,filterNameoptionList,initDataSetProductTablefig,quoteTotalPriceActionLogic,CheckForCost,actState,tStringe,Agent1comput,
+import {ExtendedWarrantyAmountTotalPriceExport,yingYanCheck,qwe,lineDown,lineUp,localParseInt,toNum,initDataTableToBeproductConfig,saveEvoluationLogic,oppInfosave,quoLineItemsave,filterNameoptionList,initDataSetProductTablefig,quoteTotalPriceActionLogic,CheckForCost,actState,tStringe,Agent1comput,
toNumComma,localParseFloat,NewQcopyLogic,productCompareLogic,bflag,jzProductsearchLogic,additionaljzProductLogic,initDataProductTablefig,checkNMPA,saveQuotel,CheckForListPrice,calGuranteePeriodLogic,EstimationL,checkch,
additionabuttonLoc,DataStatus,InitializeProductAssignment,PriceStatusUpdateLogic,newQuoteFlagex,calGuranteeAllFieldsLogic,MultiYearWarrantyTotalPriceExport,newQuoteFlagExp,AlertForCFDA,UnitPriceUpdateLogic,nafgExp,flg,errorflgw,
PrintCustomerNameoptionsvlue,selection_hpExp,options_hpflgExp,initquoassignment,initquoassignmentcopy,salesProfit1Logic,salesCalculation1Logic,salesProfit2Logic,salesCalculation2Logic,SubtotalupdateLogic,alfExp,resultFlag,
@@ -580,6 +580,7 @@
this.jzDataToBeproduct =[].concat(this.jzDataToBeproduct);
this.hidden_MultiYearWarrantyTotalPrice = MultiYearWarrantyTotalPriceExport;
this.quo.MultiYearWarrantyTotalPrice__c = toNumComma(MultiYearWarrantyTotalPriceExport);
+ this.quo.ExtendedWarrantyAmountTotalPrice__c = toNumComma(ExtendedWarrantyAmountTotalPriceExport);
}
EstimationListPrice() {
this.jzDataToBeproduct = EstimationL(this.jzDataToBeproduct,this.quo);
@@ -1462,7 +1463,9 @@
var IsQuoteTrial=this.quo.IsQuoteTrial__c;
if(!IsQuoteTrial){
var mp=this.quo.MultiYearWarrantyTotalPrice__c;
+ var ex =this.ExtendedWarrantyAmountTotalPrice__c;
mp=localParseFloat(mp);
+ ex=localParseFloat(ex);
var num=this.quo.Quote_Adjust_Calculate__c;
num=localParseFloat(num);
this.quo.Quote_Adjust_Calculate__c=toNumComma(num);
@@ -1471,7 +1474,7 @@
var rh=this.oppInfo.rate_hospital;
var ra=this.oppInfo.rate_agency1;
this.quo.Dealer_Final_Price_Page__c=toNumComma(z*rh);
- this.quo.OCM_Agent1_Price_Page__c=this.Saleslet ? toNumComma(z*num*ra+mp) : '';
+ this.quo.OCM_Agent1_Price_Page__c=this.Saleslet ? toNumComma(z*num*ra+mp+ex) : '';
this.setOCMAmount();
this.calFromContactPrice();
}
@@ -1665,7 +1668,11 @@
this.quoteAgencyTotalPriceAction();
this.AgencyDiscountCalculation1();
}
+ debugger
this.updateNoDiscountPricetotal();
+ // chenjingwu
+ this.updateExPricetotal()
+ // chenjingwu
this.EstimationListPrice();
this.calUnitPriceTotal();
this.quoteTotalPrice();
@@ -1689,6 +1696,17 @@
this.jzDataToBeproduct =[].concat(this.jzDataToBeproduct);
this.hidden_MultiYearWarrantyTotalPrice=noDiscountPriceTotal;
this.quo.MultiYearWarrantyTotalPrice__c=toNumComma(noDiscountPriceTotal);
+ }
+ updateExPricetotal() {
+ var ExPricetotal=0;
+ this.jzDataToBeproduct.forEach(jzdtbt=>{
+ var exPrice=jzdtbt.exPrice;
+ exPrice=localParseFloat(exPrice);
+ var Quantity=jzdtbt.Quantity__c;
+ Quantity=localParseFloat(Quantity);
+ ExPricetotal=ExPricetotal + exPrice * Quantity;
+ });
+ this.quo.ExtendedWarrantyAmountTotalPrice__c=toNumComma(ExPricetotal);
}
handleRowAction(event){
const actionName=event.detail.row;
@@ -1830,7 +1848,7 @@
var errormessage = tempArr[0];
var quoteLineItem = JSON.parse(tempArr[1]);
quoteLineItem = InitializeProductAssignment(quoteLineItem);
- this.tobeflag=true;
+ this.tobeflag=false;
this.jzDataToBeproduct = quoteLineItem;
// cjw
console.log('xxx');
@@ -1841,8 +1859,8 @@
});
addOptions({idList: idList}).then(result=>{
this.addOptionsLogic(result);
+ this.tobeflag=true;
});
- this.tobeflag=false;
if(quoteLineItem.length!=num){
this.quo.IsQuoteTrial__c = false;
}
--
Gitblit v1.9.1