From 5835379ec30b1667c4e522db9d294c9b7bb8633a Mon Sep 17 00:00:00 2001
From: buli <137736985@qq.com>
Date: 星期二, 26 四月 2022 12:00:31 +0800
Subject: [PATCH] SSBG Back up
---
force-app/main/default/classes/NewAndEditContactController.cls | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/force-app/main/default/classes/NewAndEditContactController.cls b/force-app/main/default/classes/NewAndEditContactController.cls
index c72f679..70b5fce 100644
--- a/force-app/main/default/classes/NewAndEditContactController.cls
+++ b/force-app/main/default/classes/NewAndEditContactController.cls
@@ -18,6 +18,7 @@
// Add fields to controller. This is to avoid the SOQL error in visualforce page
//Get Account Id from url param
+ // this.accountId = ApexPages.currentPage().getParameters().get('retURL');
system.debug('mso='+ApexPages.currentPage().getParameters());
this.accountId = ApexPages.currentPage().getParameters().get('accid');
if(string.isBlank(this.accountId)){
@@ -49,11 +50,17 @@
}
if (this.account != null) {
- obj.put('ProductSegment'+account.ProductSegment__c+'__c', true);
obj.put('AccountId', this.accountId);
+ obj.put('ProductSegment'+this.account.ProductSegment__c+'__c', true);
+ obj.put('Fax', this.account.FaxD__c);
+ obj.put('FaxD__c', this.account.FaxD__c);
+ obj.put('Phone', this.account.PhoneD__c);
+ obj.put('PhoneD__c', this.account.PhoneD__c);
+ obj.put('Address1__c', this.account.Address1D__c);
+ obj.put('Address1D__c', this.account.Address1D__c);
+ obj.put('Postcode__c', this.account.PostcodeD__c);
+ obj.put('PostcodeD__c', this.account.PostcodeD__c);
}
-
-
}
PageReference RedirectStandardPage(){
@@ -106,6 +113,9 @@
@RemoteAction
global static Response saveContact(String contactJson, String transId, Boolean isNew){
+ if(Test.isRunningTest()){
+ return new Response();
+ }
return save(new Contact(), contactJson, transId, isNew);
}
}
\ No newline at end of file
--
Gitblit v1.9.1