From bae4d41e9e63cbeed024cf8209011dd9c854d54c Mon Sep 17 00:00:00 2001
From: 涂煌豪 <tuhuanghao@prec-tech.com>
Date: 星期一, 11 四月 2022 20:01:12 +0800
Subject: [PATCH] Sfdc2PoContactBatch修改2.0
---
force-app/main/default/classes/TenderInformationHandler.cls | 21 +++++++++++++++++++++
1 files changed, 21 insertions(+), 0 deletions(-)
diff --git a/force-app/main/default/classes/TenderInformationHandler.cls b/force-app/main/default/classes/TenderInformationHandler.cls
index 4f8fe52..17de6fe 100644
--- a/force-app/main/default/classes/TenderInformationHandler.cls
+++ b/force-app/main/default/classes/TenderInformationHandler.cls
@@ -46,6 +46,7 @@
if (!StaticParameter.EscapeOtherUpdateTenOwner) {
updateTenOwner();
}
+
}
protected override void afterInsert() {
@@ -58,6 +59,26 @@
addShare();
sednMessage();
updateWin();
+
+ //2022-3-29 yjk SWAG-CCL6R7
+ updateOpportunity();
+ }
+
+
+ //2022-3-29 yjk SWAG-CCL6R7
+ private void updateOpportunity(){
+ for(Tender_information__c newOne : newList){
+ Tender_information__c oldOne = oldMap.get(newOne.id);
+ if(oldOne.ResultDate__c == null && newOne.ResultDate__c != null){
+ List<Opportunity> oppList = [select id,Closing_Bid_Date__c from Opportunity where Bidding_Project_Name_Bid__c = :newOne.id];
+ if(oppList.size() > 0){
+ for(Opportunity opp : oppList){
+ opp.Closing_Bid_Date__c = newOne.ResultDate__c;
+ }
+ update oppList;
+ }
+ }
+ }
}
public void sednMessage() {
--
Gitblit v1.9.1