游畅
2022-03-31 873e4a41dd4d86e9038f32d924075247be7cd449
新建事件报错20220331
1个文件已修改
14 ■■■■■ 已修改文件
force-app/main/default/classes/SimpleEventRegisterController.cls 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/classes/SimpleEventRegisterController.cls
@@ -1038,9 +1038,11 @@
                }
                
            }
            //20201123 zh 创建主动任务与维修合同关联 end
            if (LoginUser.Job_Category__c.equals('销售推广')) {
                if (this.targetEvent.Activity_Type2__c == '病院') {
                   // 2021-06-11 mzy sla 注释掉了询价3 因为现在的页面没有给询价3赋值,所以会显示 询价3不等于空字符串而是等于null ,导致后面的判断进不去
                   // if (this.targetEvent.Related_Opportunity1__c != '' || this.targetEvent.Related_Opportunity2__c != '' || this.targetEvent.Related_Opportunity3__c != '') {
                    System.debug('测试询价任务:' +'询价1:' +this.targetEvent.Related_Opportunity1__c +'---询价2:'+this.targetEvent.Related_Opportunity2__c);
@@ -1048,10 +1050,10 @@
                        taskType = System.Label.OpportunityFollow; // 询价跟进任务
                    } else if (this.targetEvent.OPDPlan_Flag__c) {
                        taskType = System.Label.OPD; // OPD任务
                    } else if (accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).Is_Target_Account_Energy__c == 1 || accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).Is_Target_Account__c == 1) {
                        taskType = System.Label.TargetAccountVisit; // 目标客户拜访任务
                    }  else if (accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).OCM_Category__c == 'H1' || accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).OCM_Category__c == 'H0') {
                        taskType = System.Label.visitHLevel; // H层拜访任务
                    } else if (!accToNumTarget.isEmpty() && !accToDepMap.isEmpty() && (accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).Is_Target_Account_Energy__c == 1 || accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).Is_Target_Account__c == 1)) {
                         taskType = System.Label.TargetAccountVisit; // 目标客户拜访任务
                    }  else if (!accToNumTarget.isEmpty() && !accToDepMap.isEmpty() && (accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).OCM_Category__c == 'H1' || accToNumTarget.get(accToDepMap.get(this.targetEvent.whatid__c)).OCM_Category__c == 'H0')) {
                         taskType = System.Label.visitHLevel; // H层拜访任务
                    } else {
                        taskType = System.Label.DailyVisit;// 日程拜访任务
                    }
@@ -1176,7 +1178,7 @@
                taskAccType = '用户拜访';
            }
            if (this.targetEvent.Activity_Type2__c == '販売店') {
                taskAccType = '经销商支持';
                taskAccType = '经销商拜访';
            }
            if (this.targetEvent.Activity_Type2__c == '社外イベント') {
                taskAccType = '学术会议';
@@ -1209,7 +1211,7 @@
                    taskAccType = '用户拜访';
                }
                if (this.targetEvent.Activity_Type2__c == '販売店') {
                    taskAccType = '经销商支持';
                    taskAccType = '经销商拜访';
                }
                if (this.targetEvent.Activity_Type2__c == '社外イベント') {
                    taskAccType = '学术会议';