| | |
| | | OPDPlan__c OPDPlan01 = new OPDPlan__c(); |
| | | OPDPlan01.Status__c = '提交'; |
| | | OPDPlan01.NoOpp_Reason__c= 'HCP对应'; |
| | | OPDPlan01.OPDType__c = '事件'; |
| | | insert OPDPlan01; |
| | | |
| | | OPDPlan__c OPDPlan02 = new OPDPlan__c(); |
| | | OPDPlan02.Status__c = '草案中'; |
| | | OPDPlan02.NoOpp_Reason__c= 'HCP对应'; |
| | | OPDPlan02.OPDType__c = '询价'; |
| | | insert OPDPlan02; |
| | | /** |
| | | OPDPlan__c OPDPlan03 = new OPDPlan__c(); |
| | |
| | | oPDPlan1.OPD_Customers_Target_Last__c=null; |
| | | oPDPlan1.OPDPlan_ImplementDate__c = Date.today().addDays(3); |
| | | oPDPlan1.NoOpp_Reason__c = 'HCP对应'; |
| | | OPDPlan1.OPDType__c = '学会'; |
| | | insert oPDPlan1; |
| | | oPDPlan0.Account_Laboratory__c =dpt.Id; |
| | | oPDPlan0.OPDPlan_ImplementDate__c = oPDPlan1.OPDPlan_ImplementDate__c.addDays(40); |
| | |
| | | oPDPlan3.OPD_Customers_Target_Last__c=null; |
| | | oPDPlan3.OPDPlan_ImplementDate__c = Date.today().addDays(3); |
| | | oPDPlan3.NoOpp_Reason__c = 'HCP对应'; |
| | | OPDPlan3.OPDType__c = '学会'; |
| | | insert oPDPlan3; |
| | | |
| | | /*OPDPlan__c oPDPlan4 = new OPDPlan__c(); |
| | |
| | | oPDPlan2.OPD_Customers_Target__c =anot1.id; |
| | | oPDPlan2.PlanProdDetail__c ='CV-290*4; GI-290镜子*1; GI-290镜子CF*1;'; |
| | | // oPDPlan2.OriginalOpdPlan__c = oPDPlan3.Id; |
| | | oPDPlan2.OPDType__c = '学会'; |
| | | insert oPDPlan2; |
| | | oPDPlan2.Status__c = '审批中'; |
| | | |
| | |
| | | oPDPlan4.OPD_Customers_Target_Last__c=anot.id; |
| | | oPDPlan4.OPD_Customers_Target__c =anot1.id; |
| | | oPDPlan4.PlanProdDetail__c ='CV-290*4; GI-290镜子*1; GI-290镜子CF*1;'; |
| | | oPDPlan4.OPDType__c = '学会'; |
| | | insert oPDPlan4; |
| | | |
| | | //取消 |
| | |
| | | oPDPlan5.OPD_Customers_Target__c =anot1.id; |
| | | oPDPlan5.PlanProdDetail__c ='CV-290*4; GI-290镜子*1; GI-290镜子CF*1;'; |
| | | oPDPlan5.OriginalOpdPlan__c = oPDPlan4.Id; |
| | | oPDPlan5.OPDType__c = '学会'; |
| | | insert oPDPlan5; |
| | | |
| | | |
| | | |
| | | |
| | | OPDPlan__c oPDPlan6 = new OPDPlan__c(); |
| | | oPDPlan6.Status__c = '计划中'; |
| | | oPDPlan6.Account_Laboratory__c =dpt.Id; |
| | | oPDPlan6.OPDPlan_ImplementDate__c = Date.today().addDays(3); |
| | | //oPDPlan6.OPDPlan_ImplementDate__c = Date.today().addDays(3); |
| | | oPDPlan6.OPDPlan_ImplementDate__c = oPDPlan3.OPDPlan_ImplementDate__c; |
| | | oPDPlan6.NoOpp_Reason__c = 'HCP对应'; |
| | | oPDPlan6.if_OPDTarget__c=1; |
| | | oPDPlan6.if_HaveSalestarget__c =1; |
| | |
| | | oPDPlan6.PlanProdDetail__c ='CV-290*4; GI-290镜子*1; GI-290镜子CF*1;'; |
| | | oPDPlan6.OriginalOpdPlanApplication__c = oPDPlan3.Id; |
| | | oPDPlan6.RentalReson__c = '追加配套'; |
| | | insert oPDPlan6; |
| | | oPDPlan6.OPDType__c = '学会'; |
| | | oPDPlan6.OriginalOpdPlanRental__c = oPDPlan3.Id; |
| | | insert oPDPlan6; //2022-4-29 yjk update |
| | | |
| | | //oPDPlan6 = [select Id,Status__c from OPDPlan__c where id = :opdPlan6.Id]; |
| | | //System.assertEquals('',oPDPlan6.Status__c); |
| | |
| | | insertTarget.Opd_Plan__c = oPDPlan0.Id; |
| | | insertTarget.Task_ID__c = task.Id; |
| | | insertTarget.PlanProdDetail__c = 'CV-290*4; GI-290镜子*1; GI-290镜子CF*1;'; |
| | | insertTarget.eventStatus__c = '02 接受'; |
| | | insert insertTarget; |
| | | |
| | | OPDPlan__C opd = [SELECT Id,OPDPlan_ImplementDate__c FROM OPDPlan__C WHERE id =: oPDPlan0.Id]; |
| | |
| | | |
| | | update opd; |
| | | |
| | | oPDPlan0.Status__c = '完毕'; |
| | | update oPDPlan0; |
| | | |
| | | |
| | | } |
| | | //2021-06-26 mzy end |