From a139dba9262dbb4b70f34d3c2034c255561abcad Mon Sep 17 00:00:00 2001
From: Pu Zhibing <393733352@qq.com>
Date: 星期六, 26 七月 2025 18:04:58 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 ManagementQYTTravel/guns-admin/src/main/webapp/static/modular/system/tCompany/tCompany_info.js |   40 ++++++++++++++++++++++++++--------------
 1 files changed, 26 insertions(+), 14 deletions(-)

diff --git a/ManagementQYTTravel/guns-admin/src/main/webapp/static/modular/system/tCompany/tCompany_info.js b/ManagementQYTTravel/guns-admin/src/main/webapp/static/modular/system/tCompany/tCompany_info.js
index 18cfc0d..909a5a9 100644
--- a/ManagementQYTTravel/guns-admin/src/main/webapp/static/modular/system/tCompany/tCompany_info.js
+++ b/ManagementQYTTravel/guns-admin/src/main/webapp/static/modular/system/tCompany/tCompany_info.js
@@ -325,9 +325,13 @@
             Feng.error("登录账户已存在,请重新输入");
             return;
         }
-        Feng.success("添加成功!");
-        window.parent.TCompany.table.refresh();
-        TCompanyInfoDlg.close();
+        if(200 == data.code){
+            Feng.success("添加成功!");
+            window.parent.TCompany.table.refresh();
+            TCompanyInfoDlg.close();
+        }else{
+            Feng.error("添加失败!" + data.message + "!");
+        }
     },function(data){
         Feng.error("添加失败!" + data.responseJSON.message + "!");
     });
@@ -804,16 +808,24 @@
 };
 
 function deleteSub(e) {
-
-    var ajax = new $ax(Feng.ctxPath + '/tCompany/searchArea', function (data) {
-        if (data === "该区域正被打车卡使用,不允许移除"){
-            Feng.error(data);
-            return false;
-        }else {
-            $(e).parent().parent().remove();
-        }
+    swal({
+        title: "您是否确认删除该区域?",
+        type: "warning",
+        showCancelButton: true,
+        confirmButtonColor: "#DD6B55",
+        confirmButtonText: "删除",
+        closeOnConfirm: false
+    }, function () {
+        var ajax = new $ax(Feng.ctxPath + '/tCompany/searchArea', function (data) {
+            if (data === "该区域正被打车卡使用,不允许移除") {
+                Feng.error(data);
+                return false;
+            } else {
+                $(e).parent().parent().remove();
+            }
+        });
+        ajax.set("companyId", $("#id").val());   ///   适用地区id
+        ajax.set("id", $($(e).parent('td').prev('td').find('input')[0]).val());   ///   适用地区id
+        ajax.start();
     });
-    ajax.set("companyId",$("#id").val());   ///   适用地区id
-    ajax.set("id",$($(e).parent('td').prev('td').find('input')[0]).val());   ///   适用地区id
-    ajax.start();
 }
\ No newline at end of file

--
Gitblit v1.7.1