From 6ea917ffd94638d96d2a64316e0c971985ca47d6 Mon Sep 17 00:00:00 2001 From: 涂煌豪 <tuhuanghao@prec-tech.com> Date: 星期二, 24 五月 2022 13:25:48 +0800 Subject: [PATCH] 修改客户人员更新逻辑 --- force-app/main/default/classes/ContactTriggerHandlerTest.cls | 17 ++++++++++++++--- 1 files changed, 14 insertions(+), 3 deletions(-) diff --git a/force-app/main/default/classes/ContactTriggerHandlerTest.cls b/force-app/main/default/classes/ContactTriggerHandlerTest.cls index 5f26f37..fc2e86a 100644 --- a/force-app/main/default/classes/ContactTriggerHandlerTest.cls +++ b/force-app/main/default/classes/ContactTriggerHandlerTest.cls @@ -29,7 +29,6 @@ // account1.RecordTypeId = '01210000000QemG'; account1.RecordTypeId = HPrectCo[0].Id; insert account1; - // 鍙栧紩鍏堣铂浠昏�� contact1.AccountId = account1.Id; contact1.FirstName = '璨换鑰�'; @@ -41,6 +40,16 @@ contact1.RecordTypeId = DoctorrectCo[0].Id; contact1.UnifiedI_Contact_ID__c = '100000'; insert contact1; + + contact2.FirstName = 'test'; + contact2.LastName = 'Data'; + // contact2.RecordTypeId = '01210000000QfWi'; + contact2.RecordTypeId = DoctorrectCo[0].Id; + contact2.AccountId = account1.Id; + contact2.Agency_User__c = true; + contact2.MobilePhone = '18999999999'; + insert contact2; + MeetingManagement__c a = new MeetingManagement__c(Contact__c =contact1.id ,pollingTime__c = 1, @@ -84,8 +93,6 @@ contact2.Agency_User__c = true; contact2.MobilePhone = '18999999999'; insert contact2; - contact2.MobilePhone = '1899999999A'; - update contact2; Contact contact3 = new Contact(); contact3.FirstName = 'test'; @@ -97,6 +104,10 @@ contact3.Ignore_Same_Name__c = true; contact3.MobilePhone = ''; insert contact3; + + contact2.MobilePhone = '1899999999A'; + update contact2; + List<account> accList = [select Dealer_Num__c From account]; system.assertEquals(accList[0].Dealer_Num__c,1); -- Gitblit v1.9.1