From ddb0231ef7c5cf2bad9d3f1afc2f733674ad38a5 Mon Sep 17 00:00:00 2001
From: unknown <sunxia@prec-tech.com>
Date: 星期四, 24 八月 2023 14:50:51 +0800
Subject: [PATCH] 再修理按钮

---
 force-app/main/default/lwc/lexOSHNogoods/lexOSHNogoods.js |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/force-app/main/default/lwc/lexOSHNogoods/lexOSHNogoods.js b/force-app/main/default/lwc/lexOSHNogoods/lexOSHNogoods.js
index 388856a..b680883 100644
--- a/force-app/main/default/lwc/lexOSHNogoods/lexOSHNogoods.js
+++ b/force-app/main/default/lwc/lexOSHNogoods/lexOSHNogoods.js
@@ -48,7 +48,6 @@
                 this.email = result.email;
 
                 this.OSHNogoods();
-                this.dispatchEvent(new CloseActionScreenEvent());
             }
         }).catch(error => {
             console.log(error);
@@ -59,6 +58,8 @@
     OSHNogoods() {
         if (this.QISStatusC != 'OSH妫�娴嬬敵璇�' && this.QISStatusC != '瀹屾瘯') {
             this.ShowToastEvent("OSH宸茬粡鏀跺埌瀹炵墿", "error")
+            this.dispatchEvent(new CloseActionScreenEvent());
+            return;
         } else {
             updateOSHNogoods({
                 Id: this.Id,
@@ -68,7 +69,8 @@
                 console.log(result);
                 if (result.length > 0) {
                     var split = result.split(", ");
-                    alert(split[1]);
+                    this.ShowToastEvent(split[1], "error");
+                    this.dispatchEvent(new CloseActionScreenEvent());
                 }
             })
         }

--
Gitblit v1.9.1