From 36d15f189de2e83ce2576715dac30c3c260388dd Mon Sep 17 00:00:00 2001
From: buli <137736985@qq.com>
Date: 星期五, 14 七月 2023 14:47:50 +0800
Subject: [PATCH] fixconflict

---
 force-app/main/default/triggers/ContactHpDeptUpd.trigger |   95 +++++++++++++++++++++++++----------------------
 1 files changed, 50 insertions(+), 45 deletions(-)

diff --git a/force-app/main/default/triggers/ContactHpDeptUpd.trigger b/force-app/main/default/triggers/ContactHpDeptUpd.trigger
index c7de2bd..9ed9601 100644
--- a/force-app/main/default/triggers/ContactHpDeptUpd.trigger
+++ b/force-app/main/default/triggers/ContactHpDeptUpd.trigger
@@ -26,10 +26,12 @@
         if(Trigger.isInsert&&a.Ignore_Same_Name__c==false){
             FirstNameList.add(a.firstname);
             LastnameList.add(a.Lastname);
-            LastnameEncryptedList.add(a.LastName_Encrypted__c);
+            //zhj MEBG鏂版柟妗堟敼閫� 2022-11-28 start
+            //LastnameEncryptedList.add(a.LastName_Encrypted__c);
             ACCOUNT_id_list.add(a.Accountid);
-            mapCon.put(a.LastName_Encrypted__c,a);
+            //mapCon.put(a.LastName_Encrypted__c,a);
             system.debug('========1111111');
+            //zhj MEBG鏂版柟妗堟敼閫� 2022-11-28 end
         }
 
     }
@@ -55,53 +57,56 @@
                 Hospital_id_list.add(   acc.Id  );
             }
         }
-        List<Contact> CntingList = [    select  
-                                                id,
-                                                Name,
-                                                Department__c,
-                                                Account.Parent.Name,
-                                                Account.name,
-                                                Account.Parent.Parent.Name
-                                        from 
-                                                Contact 
-                                        where   
-                                        //         firstname  in:FirstNameList
-                                        // and
-                                        //         Lastname   in:LastnameList
-                                        LastName_Encrypted__c in : LastnameEncryptedList
-                                        and     
-                                            (   
-                                                Account.Parent.Parentid  in:Hospital_id_list
-                                        or
-                                                Account.Parentid  in:Hospital_id_list
-                                        or
-                                                Account.id  in:Hospital_id_list
-                                            )
-                                ];
+        //zhj MEBG鏂版柟妗堟敼閫� 2022-11-28 start
+        // List<Contact> CntingList = [    select  
+        //                                         id,
+        //                                         Name,
+        //                                         Department__c,
+        //                                         Account.Parent.Name,
+        //                                         Account.name,
+        //                                         Account.Parent.Parent.Name
+        //                                 from 
+        //                                         Contact 
+        //                                 where   
+        //                                 //         firstname  in:FirstNameList
+        //                                 // and
+        //                                 //         Lastname   in:LastnameList
+        //                                 LastName_Encrypted__c in : LastnameEncryptedList
+        //                                 and     
+        //                                     (   
+        //                                         Account.Parent.Parentid  in:Hospital_id_list
+        //                                 or
+        //                                         Account.Parentid  in:Hospital_id_list
+        //                                 or
+        //                                         Account.id  in:Hospital_id_list
+        //                                     )
+        //                         ];
         system.debug('========1212121212'+FirstNameList);
         system.debug('========1212121212'+LastnameList);
-        system.debug('========1212121212'+LastnameEncryptedList);
+        //system.debug('========1212121212'+LastnameEncryptedList);
         system.debug('========1212121212'+Hospital_id_list);
-        if(CntingList.size()>0){
-            system.debug('========2222222'+CntingList.size());
-            Contact Cnting = CntingList[0];
-            for(Contact a : Trigger.new) {
-                system.debug('========3333333');
-                if(mapCon.containsKey(a.LastName_Encrypted__c)){
-                    //For PIPL testing by Li Jun 20220308 Start
-                    // system.debug('========333333');
-                    // if( Cnting.Account.Parent.Parent.Name   !=  null    ){
-                    //         a.addError('璇ュ鎴蜂汉鍛樺悕瀛楀凡瀛樺湪锛屽湪'+Cnting.Account.Parent.Parent.Name+'鍖婚櫌涓嬪睘 '+Cnting.Account.Parent.Name+'鎴樼暐绉戝鐨� '+Cnting.Account.Name+'绉戝锛岃淇敼,鎴栬�呭嬀閫夆�滀笉鏄噸澶嶇殑瀹㈡埛鍚嶁�濆悗锛屽啀娆$偣鍑讳繚瀛�');
-                    //     }   else if (   Cnting.Account.Parent.Name  !=null  ){
-                    //         a.addError('璇ュ鎴蜂汉鍛樺悕瀛楀凡瀛樺湪锛屽湪'+Cnting.Account.Parent.Name+'鍖婚櫌鐨� '+Cnting.Account.Name+' 鎴樼暐绉戝涓嬶紝璇蜂慨鏀�,鎴栬�呭嬀閫夆�滀笉鏄噸澶嶇殑瀹㈡埛鍚嶁�濆悗锛屽啀娆$偣鍑讳繚瀛�');
-                    //     }   else if (   Cnting.Account.Name !=  null    ){
-                    //         a.addError('璇ュ鎴蜂汉鍛樺悕瀛楀凡瀛樺湪锛屽湪'+Cnting.Account.Name+'鍖婚櫌锛岃淇敼,鎴栬�呭嬀閫夆�滀笉鏄噸澶嶇殑瀹㈡埛鍚嶁�濆悗锛屽啀娆$偣鍑讳繚瀛�'); 
-                    //     }
-                    //For PIPL testing by Li Jun 20220308 End
-                    }
-            }   
-        }
+        
+    //     if(CntingList.size()>0){
+    //         system.debug('========2222222'+CntingList.size());
+    //         Contact Cnting = CntingList[0];
+    //         for(Contact a : Trigger.new) {
+    //             system.debug('========3333333');
+    //             if(mapCon.containsKey(a.LastName_Encrypted__c)){
+    //                 //For PIPL testing by Li Jun 20220308 Start
+    //                 // system.debug('========333333');
+    //                 // if( Cnting.Account.Parent.Parent.Name   !=  null    ){
+    //                 //         a.addError('璇ュ鎴蜂汉鍛樺悕瀛楀凡瀛樺湪锛屽湪'+Cnting.Account.Parent.Parent.Name+'鍖婚櫌涓嬪睘 '+Cnting.Account.Parent.Name+'鎴樼暐绉戝鐨� '+Cnting.Account.Name+'绉戝锛岃淇敼,鎴栬�呭嬀閫夆�滀笉鏄噸澶嶇殑瀹㈡埛鍚嶁�濆悗锛屽啀娆$偣鍑讳繚瀛�');
+    //                 //     }   else if (   Cnting.Account.Parent.Name  !=null  ){
+    //                 //         a.addError('璇ュ鎴蜂汉鍛樺悕瀛楀凡瀛樺湪锛屽湪'+Cnting.Account.Parent.Name+'鍖婚櫌鐨� '+Cnting.Account.Name+' 鎴樼暐绉戝涓嬶紝璇蜂慨鏀�,鎴栬�呭嬀閫夆�滀笉鏄噸澶嶇殑瀹㈡埛鍚嶁�濆悗锛屽啀娆$偣鍑讳繚瀛�');
+    //                 //     }   else if (   Cnting.Account.Name !=  null    ){
+    //                 //         a.addError('璇ュ鎴蜂汉鍛樺悕瀛楀凡瀛樺湪锛屽湪'+Cnting.Account.Name+'鍖婚櫌锛岃淇敼,鎴栬�呭嬀閫夆�滀笉鏄噸澶嶇殑瀹㈡埛鍚嶁�濆悗锛屽啀娆$偣鍑讳繚瀛�'); 
+    //                 //     }
+    //                 //For PIPL testing by Li Jun 20220308 End
+    //                 }
+    //         }   
+    //     }
     }
+    //zhj MEBG鏂版柟妗堟敼閫� 2022-11-28 end
 //***************************************INSERT 2016-12-14 By ZDF EDN*************************************
 //          澧炲姞鈥滄柊澧炲鎴蜂汉鍛樺叆渚嬭鍒欌��
 //***************************************INSERT 2016-12-14 By ZDF EDN*************************************

--
Gitblit v1.9.1