From 3b43925ca3211c861a2818a089907d34b5480aa5 Mon Sep 17 00:00:00 2001
From: 张宇恒 <bxyun0@163.com>
Date: 星期五, 06 五月 2022 10:41:15 +0800
Subject: [PATCH] 批量数据拆分处理
---
force-app/main/default/classes/LeadIntentionController.cls | 25 +++++++++++--------------
1 files changed, 11 insertions(+), 14 deletions(-)
diff --git a/force-app/main/default/classes/LeadIntentionController.cls b/force-app/main/default/classes/LeadIntentionController.cls
index c21db34..c50d0e9 100644
--- a/force-app/main/default/classes/LeadIntentionController.cls
+++ b/force-app/main/default/classes/LeadIntentionController.cls
@@ -143,7 +143,10 @@
public PageReference init() {
system.debug('test:12345');
onlyOpp = false;
- String uidParam = System.currentPageReference().getParameters().get('uid');
+ // String uidParam = System.currentPageReference().getParameters().get('uid');
+ //棣栭〉浜у搧鍜ㄨ鍗曟暟閲忎慨鏀� thh 20220406 start
+ String uidParam = UserInfo.getUserId();
+ //棣栭〉浜у搧鍜ㄨ鍗曟暟閲忎慨鏀� thh 20220406 end
if (uidParam != null){
User u = [select Id, FirstName, LastName from User where Id = :uidParam];
ownerSearch = u.LastName + ' ' + u.FirstName;
@@ -163,7 +166,7 @@
text, condition, value, text2, condition2, value2, text3, condition3, value3);
String soqlForMoney = soqlForMoneyWithoutSort + ' order by CreatedDate desc limit ' + Integer.valueOf(System.Label.TotalLimit);
System.debug('soqlWithoutSort:' + soqlWithoutSort);
- system.debug('aaaaaaaaaa'+soql);
+ system.debug('aaaaaaaaaa:'+soql);
system.debug('bbbbbbb:'+soqlForMoney);
List<Inquiry_form__c> queryList = Database.query(soql);
List<Inquiry_form__c> queryListForMoney = Database.query(soqlForMoney);
@@ -172,11 +175,6 @@
system.debug('ppppppppp鐨剆ize():'+queryList.size());
system.debug('ooooooooo鐨剆ize():'+queryListForMoney.size());
- BatchIF_Log__c iflog = new BatchIF_Log__c();
- iflog.Type__c = 'TestTaskManage';
-
- iflog.Log__c = '杩涘叆浜唅nit鏂规硶: queryListForMoney sql: '+soqlWithoutSort;
- insert iflog;
this.makeOppRecordsForView(queryList, queryListForMoney);
this.sortKey = '0';
@@ -241,11 +239,9 @@
String soql = soqlWithoutSort
+ ' order by ' + this.columus[Integer.valueOf(this.sortKey)] + ' ' + (this.sortOrderAsc == true ? 'asc nulls first' : 'desc nulls last') + ' limit ' + Integer.valueOf(limits);
-system.debug('sort:::::'+ soql);
List<Inquiry_form__c> queryList = Database.query(soql);
String soqlForMoney = soqlForMoneyWithoutSort
+ ' order by ' + this.columus[Integer.valueOf(this.sortKey)] + ' ' + (this.sortOrderAsc == true ? 'asc nulls first' : 'desc nulls last')+ ' limit ' + Integer.valueOf(System.Label.TotalLimit) ;
-system.debug('sort:::::'+ soqlForMoney);
List<Inquiry_form__c> queryListForMoney = Database.query(soqlForMoney);
@@ -398,13 +394,14 @@
soql += ' and Hospital_Name__r.Name like \'%' + v + '%\'';
}
}
+ //棣栭〉浜у搧鍜ㄨ鍗曟暟閲忎慨鏀� thh 20220406 start
if (!String.isBlank(ownerStr)) {
- String[] vals = ownerStr.split(' ');
- for (String v : vals) {
- soql += ' and Name like \'%' + v + '%\'';
- }
+ // String[] vals = ownerStr.split(' ');
+ // for (String v : vals) {
+ soql += ' and owner.Name like \'%' + ownerStr + '%\'';
+ // }
}
-
+ //棣栭〉浜у搧鍜ㄨ鍗曟暟閲忎慨鏀� thh 20220406 end
soql += this.makeTextSql(txt, con, val);
soql += this.makeTextSql(txt2, con2, val2);
soql += this.makeTextSql(txt3, con3, val3);
--
Gitblit v1.9.1