From 71b93327e8f3fb3bffffc7c033c1f782e7b6ab32 Mon Sep 17 00:00:00 2001
From: buli <137736985@qq.com>
Date: 星期一, 22 五月 2023 17:37:16 +0800
Subject: [PATCH] test

---
 force-app/main/default/classes/ArriveGoodsController.cls |   12 ++++++++++--
 1 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/force-app/main/default/classes/ArriveGoodsController.cls b/force-app/main/default/classes/ArriveGoodsController.cls
index c7c0db6..4ed9dff 100644
--- a/force-app/main/default/classes/ArriveGoodsController.cls
+++ b/force-app/main/default/classes/ArriveGoodsController.cls
@@ -3604,7 +3604,11 @@
                     }
 
                     if(codi.esd.Return_reason__c==null||codi.esd.Return_reason__c==''){
-                        codi.esd.Return_reason__c.addError('璇疯ˉ鍏呰繑鍝佸師鍥�');
+                        if(isLwc){
+                            returnError = '璇疯ˉ鍏呰繑鍝佸師鍥�';
+                        }else {
+                            codi.esd.Return_reason__c.addError('璇疯ˉ鍏呰繑鍝佸師鍥�');
+                        }
                         return null;
                     }
 
@@ -3613,7 +3617,11 @@
                         String key = '' + codi.esd.Consumable_ZS_order__c + codi.esd.Bar_Code__c;
                         Integer deliverycnt = BarcodeCntMap.get(key);
                         if(codi.esd.Rrturn_count__c > deliverycnt){
-                            codi.esd.Rrturn_count__c.addError('瓒呭嚭鍑哄簱鏁伴噺');
+                            if(isLwc){
+                                returnError = '瓒呭嚭鍑哄簱鏁伴噺';
+                            }else {
+                                codi.esd.Rrturn_count__c.addError('瓒呭嚭鍑哄簱鏁伴噺');
+                            }
                             return null;
                         }  
                     }

--
Gitblit v1.9.1