From 250e5afb499bfa4bb96cbcbfd335b678dd076f5e Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@163.com>
Date: 星期六, 13 六月 2020 14:18:20 +0800
Subject: [PATCH] #

---
 src/main/webapp/static/js/pakStore/emptyOut.js |   44 ++++++++++++++++++++++++--------------------
 1 files changed, 24 insertions(+), 20 deletions(-)

diff --git a/src/main/webapp/static/js/pakStore/emptyOut.js b/src/main/webapp/static/js/pakStore/emptyOut.js
index 12eb095..fb1d52f 100644
--- a/src/main/webapp/static/js/pakStore/emptyOut.js
+++ b/src/main/webapp/static/js/pakStore/emptyOut.js
@@ -6,25 +6,28 @@
     var layDate = layui.laydate;
     var form = layui.form;
 
-    // 鑾峰彇鍙敤鍏ュ簱绔欑偣
-    $.ajax({
-        url: baseUrl+"/available/take/site",
-        headers: {'token': localStorage.getItem('token')},
-        method: 'POST',
-        success: function (res) {
-            if (res.code === 200){
-                var tpl = $("#takeSiteSelectTemplate").html();
-                var template = Handlebars.compile(tpl);
-                var html = template(res);
-                $('#staNoSelect').append(html);
-                form.render('select');
-            } else if (res.code === 403){
-                top.location.href = baseUrl+"/";
-            }else {
-                layer.msg(res.msg)
+    // 鑾峰彇鍑哄簱鍙�
+    function getOutBound(){
+        $.ajax({
+            url: baseUrl+"/available/take/site",
+            headers: {'token': localStorage.getItem('token')},
+            method: 'POST',
+            asymc: false,
+            success: function (res) {
+                if (res.code === 200){
+                    var tpl = $("#takeSiteSelectTemplate").html();
+                    var template = Handlebars.compile(tpl);
+                    var html = template(res);
+                    $('#staNoSelect').append(html);
+                    form.render('select');
+                } else if (res.code === 403){
+                    top.location.href = baseUrl+"/";
+                }else {
+                    layer.msg(res.msg)
+                }
             }
-        }
-    })
+        })
+    }
 
     // 鏁版嵁娓叉煋
     tableIns = table.render({
@@ -76,6 +79,7 @@
                 top.location.href = baseUrl+"/";
             }
             pageCurr=curr;
+            getOutBound();
             limit();
             form.on('checkbox(tableCheckbox)', function (data) {
                 var _index = $(data.elem).attr('table-index')||0;
@@ -106,6 +110,7 @@
         pageCurr = 1;
         $('#detlTable').css("display", 'none');
         tableReload(false);
+        getOutBound();
     });
 
     // 鎼滅储鏍忛噸缃簨浠�
@@ -114,6 +119,7 @@
         clearFormVal($('#search-box'));
         $('#detlTable').css("display", 'none');
         tableReload(false);
+        getOutBound();
     });
 
 })
@@ -146,5 +152,3 @@
         }
     });
 }
-
-

--
Gitblit v1.9.1