From 75d427ca021ea10b6097cebfd53da6d4ef1c9a4e Mon Sep 17 00:00:00 2001
From: 李金换 <lijinhuan@prec-tech.com>
Date: 星期一, 21 三月 2022 13:35:59 +0800
Subject: [PATCH] 【委托】 【优先紧急对应】I/F010&I/F110传输检查修复和预测修复

---
 force-app/main/default/classes/LogAutoSendBatch.cls |   27 ++++++++++++++-------------
 1 files changed, 14 insertions(+), 13 deletions(-)

diff --git a/force-app/main/default/classes/LogAutoSendBatch.cls b/force-app/main/default/classes/LogAutoSendBatch.cls
index d51e626..7104f78 100644
--- a/force-app/main/default/classes/LogAutoSendBatch.cls
+++ b/force-app/main/default/classes/LogAutoSendBatch.cls
@@ -29,8 +29,21 @@
     global Database.QueryLocator start(Database.BatchableContext BC) {
 
         String profileId = UserInfo.getProfileId();
+        // 20220318 ljh SWAG-CC54R2 add start
+        if(String.isNotBlank(typeNFM) && typeNFM == 'NFM010' && String.isBlank(messageGroupNumber)){
+            return Database.getQueryLocator(
+                [SELECT Id, Name, Log__c, ErrorLog__c, Log2__c, Log3__c, Log4__c, Log5__c, Log6__c,
+                 Log7__c, Log8__c, Log9__c, Log10__c, Log11__c, Log12__c, MessageGroupNumber__c, Type__c,
+                 retry_cnt__c, NFM501Future_Count__c, NFM501_Web_Annex_Count__c
+                 FROM BatchIF_Log__c
+                 WHERE RowDataFlg__c = true
+                 AND (retry_cnt__c = null OR (retry_cnt__c != null AND retry_cnt__c > 0 AND retry_cnt__c < : max_cnt))
+                 AND Type__c = : typeNFM ]
+                );
+        } else if (String.isNotBlank(typeNFM) && String.isNotBlank(messageGroupNumber) && times != null) {
+        // 20220318 ljh SWAG-CC54R2 add end
         //20191224 HWAG-BK65E8 add start
-        if (String.isNotBlank(typeNFM) && String.isNotBlank(messageGroupNumber) && times != null) {
+        // if (String.isNotBlank(typeNFM) && String.isNotBlank(messageGroupNumber) && times != null) {
             return Database.getQueryLocator(
                 [SELECT Id, Name, Log__c, ErrorLog__c, Log2__c, Log3__c, Log4__c, Log5__c, Log6__c,
                  Log7__c, Log8__c, Log9__c, Log10__c, Log11__c, Log12__c, MessageGroupNumber__c, Type__c,
@@ -54,18 +67,6 @@
                                             OR(NFM501_Web_Annex_Count__c != null
                                                AND NFM501_Web_Annex_Count__c > 0 AND NFM501_Web_Annex_Count__c < : max_cnt))]
                 );
-        // 20220318 ljh SWAG-CC54R2 add start
-        } else if(String.isNotBlank(typeNFM) && typeNFM == 'NFM010'){
-            return Database.getQueryLocator(
-                [SELECT Id, Name, Log__c, ErrorLog__c, Log2__c, Log3__c, Log4__c, Log5__c, Log6__c,
-                 Log7__c, Log8__c, Log9__c, Log10__c, Log11__c, Log12__c, MessageGroupNumber__c, Type__c,
-                 retry_cnt__c, NFM501Future_Count__c, NFM501_Web_Annex_Count__c
-                 FROM BatchIF_Log__c
-                 WHERE RowDataFlg__c = true
-                 AND (retry_cnt__c = null OR (retry_cnt__c != null AND retry_cnt__c > 0 AND retry_cnt__c < : max_cnt))
-                 AND Type__c = : typeNFM ]
-                );
-        // 20220318 ljh SWAG-CC54R2 add end
         } else {
             return Database.getQueryLocator(
                 [SELECT Id, Name, Log__c, ErrorLog__c, Log2__c, Log3__c, Log4__c, Log5__c, Log6__c,

--
Gitblit v1.9.1