From bfca7a84bec815da594f1d12558535ed06d2490b Mon Sep 17 00:00:00 2001
From: 沙世明 <shashiming@prec-tech.com>
Date: 星期二, 13 九月 2022 09:57:32 +0800
Subject: [PATCH] 本地提交备份
---
force-app/main/default/classes/ChoiceAssetController.cls | 72 ++++++++++++++++++++++++-----------
1 files changed, 49 insertions(+), 23 deletions(-)
diff --git a/force-app/main/default/classes/ChoiceAssetController.cls b/force-app/main/default/classes/ChoiceAssetController.cls
index 495e38a..3c92bab 100644
--- a/force-app/main/default/classes/ChoiceAssetController.cls
+++ b/force-app/main/default/classes/ChoiceAssetController.cls
@@ -182,23 +182,27 @@
String ActualVisitDateThird_Id= '';//涓夋涓婇棬鏃�
String SubOrderCompleteDate_Id= '';//鎶ヤ慨鍗曞鐞嗗畬鎴愭棩
String SubOrderCreatedDate_Id= '';//鎶ヤ慨鍗曠敵璇蜂慨鐞嗘棩
+ //LLIU-CGX5E9 LY 20220812 start
+ String DateReceiptQuestions_Id = '';//闂鑱旂粶鏀跺埌鏃�
+ //LLIU-CGX5E9 LY 20220812 end
String engineerSendDate_Id= '';//宸ョ▼甯堜慨鐞嗗搧瀵勯�佹棩
- if (NFMUtil.isSandbox()) { //娴嬭瘯鐜
- RepairApplicant_Id = '00N1m0000054ufW'; //鎶ヤ慨浜�
- // RepairApplicantPosition_Id = '00N1m0000054ufV'; //鎶ヤ慨浜哄矖浣�
- RepairApplicantHospital_Id = '00N1m0000054ufU'; //鎶ヤ慨浜哄尰闄�
- RepairApplicantDepartment_Id = '00N1m0000054ufT'; //鎶ヤ慨浜虹瀹�
- baoxiuzidan = '00N1m0000054ufZ'; //鎶ヤ慨瀛愬崟
- faqiri = '00N1m0000054ufa'; //鎶ヤ慨鍙戣捣鏃�
- shouliri = '00N1m0000054ufS'; //宸ョ▼甯堝彈鐞嗘棩
+ // if (NFMUtil.isSandbox()) { //娴嬭瘯鐜
+ // RepairApplicant_Id = '00N1m0000054ufW'; //鎶ヤ慨浜�
+ // // RepairApplicantPosition_Id = '00N1m0000054ufV'; //鎶ヤ慨浜哄矖浣�
+ // RepairApplicantHospital_Id = '00N1m0000054ufU'; //鎶ヤ慨浜哄尰闄�
+ // RepairApplicantDepartment_Id = '00N1m0000054ufT'; //鎶ヤ慨浜虹瀹�
+ // //baoxiuzidan = '00N1m0000054ufZ'; //鎶ヤ慨瀛愬崟
+ // baoxiuzidan = '00N10000009H1rR'; //鎶ヤ慨瀛愬崟
+ // faqiri = '00N1m0000054ufa'; //鎶ヤ慨鍙戣捣鏃�
+ // shouliri = '00N1m0000054ufS'; //宸ョ▼甯堝彈鐞嗘棩
- PlannedVisitDay_Id= '00N1m000005SRiF';//璁″垝涓婇棬鏃�
- ActualVisitDateFirst_Id= '00N1m000005SRiK';//涓�娆′笂闂ㄦ棩
- ActualVisitDateSecond_Id= '00N1m000005SRiP';//浜屾涓婇棬鏃�
- ActualVisitDateThird_Id= '00N1m000005SRiU';//涓夋涓婇棬鏃�
- SubOrderCompleteDate_Id= '00N1m000005SRmg';//鎶ヤ慨鍗曞鐞嗗畬鎴愭棩
- SubOrderCreatedDate_Id= '00N1m000005SRmW';//鎶ヤ慨鍗曠敵璇蜂慨鐞嗘棩
- } else { //姝e紡鐜
+ // PlannedVisitDay_Id= '00N1m000005SRiF';//璁″垝涓婇棬鏃�
+ // ActualVisitDateFirst_Id= '00N1m000005SRiK';//涓�娆′笂闂ㄦ棩
+ // ActualVisitDateSecond_Id= '00N1m000005SRiP';//浜屾涓婇棬鏃�
+ // ActualVisitDateThird_Id= '00N1m000005SRiU';//涓夋涓婇棬鏃�
+ // SubOrderCompleteDate_Id= '00N1m000005SRmg';//鎶ヤ慨鍗曞鐞嗗畬鎴愭棩
+ // SubOrderCreatedDate_Id= '00N1m000005SRmW';//鎶ヤ慨鍗曠敵璇蜂慨鐞嗘棩
+ // } else { //姝e紡鐜
RepairApplicant_Id = '00N10000009H1rQ'; //鎶ヤ慨浜�
// RepairApplicantPosition_Id = ''; //鎶ヤ慨浜哄矖浣�
RepairApplicantHospital_Id = '00N10000009H1rP'; //鎶ヤ慨浜哄尰闄�
@@ -214,7 +218,10 @@
ActualVisitDateThird_Id= '00N10000009H1r8';//涓夋涓婇棬鏃�
SubOrderCompleteDate_Id= '00N10000009H1ri';//鎶ヤ慨鍗曞鐞嗗畬鎴愭棩
SubOrderCreatedDate_Id= '00N10000009H1rj';//鎶ヤ慨鍗曠敵璇蜂慨鐞嗘棩
- }
+ //LLIU-CGX5E9 LY 20220812 start
+ DateReceiptQuestions_Id= '00N10000008rsVQ';//闂鑱旂粶鏀跺埌鏃�
+ //LLIU-CGX5E9 LY 20220812 end
+ //}
url += 'a0J/e?retURL=%2F';
url += joint_3 + Delivered_Product_Id + joint_1 + ast.Name;
@@ -253,6 +260,9 @@
url += joint_4 + ActualVisitDateSecond_Id+ joint_1 + NFMUtil.formatDateTime2StrSprit(repairSubOrder.ActualVisitDateSecon__c);//浜屾涓婇棬鏃�
url += joint_4 + ActualVisitDateThird_Id+ joint_1 + NFMUtil.formatDateTime2StrSprit(repairSubOrder.ActualVisitDateThird__c);//涓夋涓婇棬鏃�
url += joint_4 + SubOrderCompleteDate_Id+ joint_1 + NFMUtil.formatDateTime2StrSprit(repairSubOrder.ApplicationTime__c);//鎶ヤ慨鍗曞鐞嗗畬鎴愭棩
+ //LLIU-CGX5E9 LY 20220812 start
+ url += joint_4 + DateReceiptQuestions_Id+ joint_1 + NFMUtil.formatDateTime2StrSprit(repairSubOrder.ApplicationTime__c);//闂鑱旂粶鏀跺埌鏃�
+ //LLIU-CGX5E9 LY 20220812 end
url += joint_4 + SubOrderCreatedDate_Id+ joint_1 + NFMUtil.formatDateTime2StrSprit(Date.today());//鎶ヤ慨鍗曠敵璇蜂慨鐞嗘棩
url += joint_4 + shouliri + joint_1 + NFMUtil.formatDateTime2StrSprit(repairSubOrder.ReceiverTime__c);
@@ -262,14 +272,30 @@
//add wangweipeng 2022/01/26 end
//add zhangyuheng 2022/04/07 start
if (String.isNotBlank(ast.Account.RecordTypeId)) {
- if (ast.Account.RecordTypeId == '01210000000QemQAAS') { //鎴樼暐绉戝
+ if (ast.Account.RecordTypeId == '01210000000QemQAAS' || //鎴樼暐绉戝 ET
+ ast.Account.RecordTypeId == '01210000000QemL' || //鎴樼暐绉戝 娑堝寲绉�
+ ast.Account.RecordTypeId == '01210000000Qezy' || //鎴樼暐绉戝 鍏朵粬
+ ast.Account.RecordTypeId == '01210000000Qf03' || //鎴樼暐绉戝 涓嶆槑
+ ast.Account.RecordTypeId == '01210000000QezZ' || //鎴樼暐绉戝 鍛煎惛绉�
+ ast.Account.RecordTypeId == '01210000000Qezo' || //鎴樼暐绉戝 濡囩
+ ast.Account.RecordTypeId == '01210000000Qeze' || //鎴樼暐绉戝 鏅绉�
+ ast.Account.RecordTypeId == '01210000000Qezj' || //鎴樼暐绉戝 娉屽翱绉�
+ ast.Account.RecordTypeId == '01210000000Qezt' //鎴樼暐绉戝 鑰抽蓟鍠夌
+ ) { //鎴樼暐绉戝
if (String.isNotBlank(ast.Account.Parent.FSE_SP_Main_Leader__r.Work_Location__c)) {
url += joint_4 + SalesOfficeCode_selection_Id+ joint_1 + ast.Account.Parent.FSE_SP_Main_Leader__r.Work_Location__c;//淇悊鍝佽繑閫佸湴
}else {
// continue;
}
}
- if (ast.Account.RecordTypeId == '01210000000QfmRAAS') { //绉戝
+ if (ast.Account.RecordTypeId == '01210000000QfmRAAS' || //绉戝 鍛煎惛绉�
+ ast.Account.RecordTypeId == '01210000000QfmH' || //绉戝 鏅绉�
+ ast.Account.RecordTypeId == '01210000000Qfmb' || //绉戝 鍏朵粬
+ ast.Account.RecordTypeId == '01210000000QfmM' || //绉戝 濡囩
+ ast.Account.RecordTypeId == '01210000000QfmC' || //绉戝 娉屽翱绉�
+ ast.Account.RecordTypeId == '01210000000Qfm7' || //绉戝 娑堝寲绉�
+ ast.Account.RecordTypeId == '01210000000Qfm2' //绉戝 鑰抽蓟鍠夌
+ ) { //绉戝
if (String.isNotBlank(ast.Account.Parent.Parent.FSE_SP_Main_Leader__r.Work_Location__c)) {
url += joint_4 + SalesOfficeCode_selection_Id+ joint_1 + ast.Account.Parent.Parent.FSE_SP_Main_Leader__r.Work_Location__c;//淇悊鍝佽繑閫佸湴
}else {
@@ -295,11 +321,11 @@
String Generation_Source_Id = '00N10000002FHF6';//QIS鏉ユ簮
String Name_Id = 'Name';//QIS绠$悊鍙风爜
- if (NFMUtil.isSandbox()) {
- baoxiuzidan = '00N1m000005STFv'; //鎶ヤ慨瀛愬崟
- } else {
+ // if (NFMUtil.isSandbox()) {
+ // baoxiuzidan = '00N1m000005STFv'; //鎶ヤ慨瀛愬崟
+ // } else {
baoxiuzidan = '00N10000009H22X'; //鎶ヤ慨瀛愬崟
- }
+ // }
url += 'a0f/e?retURL=%2Fa0f%2Fo&RecordType=01210000000RLWc&ent=01I10000000T5b1';
url += joint_3 + Delivered_Product_Id + joint_1 + ast.Name;
@@ -339,7 +365,7 @@
String soql = 'select Id,name,SerialNumber,InstallDate,Information_From__c,Asset_situation__c,Order_No__c,Account.Name,Status,Department_Class__c, ';
soql += 'Hospital__r.Owner.Name,Hospital__r.Owner.Phone,Installation_Site__c,CurrentContract__c,Product2.Asset_Model_No__c,Hospital__r.Name,Department_Class__r.Name ,Department_Class__r.Id,';
- soql += 'Ji_Zhong_Guan_Li_Ku_Cun__c,Account.Parent.Parent.FSE_SP_Main_Leader__r.Work_Location__c';
+ soql += 'Ji_Zhong_Guan_Li_Ku_Cun__c,Account.Parent.Parent.FSE_SP_Main_Leader__r.Work_Location__c,Account.RecordTypeId';
soql += ' from Asset where Id != null AND Repairing_Count__c = 0 ';
if (String.isNotBlank(FuselageNumber) || String.isNotBlank(AssetModel) || String.isNotBlank(HospitalName)) {
soql += ' AND (';
--
Gitblit v1.9.1