From d780ce5e45bf41278f554288bb4b0ac6c37b2c4a Mon Sep 17 00:00:00 2001
From: lsh <lsh@163.com>
Date: 星期六, 08 十一月 2025 16:06:13 +0800
Subject: [PATCH] *

---
 src/main/webapp/static/js/locDetl/locDetl.js                |    2 
 src/main/webapp/static/js/pakStore/stockOutUnqualified.js   |  179 ++++++++++++++
 src/main/webapp/views/pakStore/locDetlQueryUnqualified.html |  241 ++++++++++++++++++++
 src/main/java/com/zy/asrs/controller/LocDetlController.java |   22 +
 src/main/resources/mapper/LocDetlMapper.xml                 |    6 
 src/main/webapp/static/js/manLocDetl/manLocDetl.js          |    2 
 src/main/webapp/views/pakStore/locDetlQuery.html            |   22 +
 src/main/webapp/views/pakStore/stockOutUnqualified.html     |  132 +++++++++++
 src/main/webapp/static/js/common.js                         |    2 
 src/main/java/com/zy/asrs/controller/WorkController.java    |   62 +++-
 10 files changed, 651 insertions(+), 19 deletions(-)

diff --git a/src/main/java/com/zy/asrs/controller/LocDetlController.java b/src/main/java/com/zy/asrs/controller/LocDetlController.java
index feda529..ff7875f 100644
--- a/src/main/java/com/zy/asrs/controller/LocDetlController.java
+++ b/src/main/java/com/zy/asrs/controller/LocDetlController.java
@@ -90,6 +90,28 @@
         return R.ok(stockOut);
     }
 
+    @RequestMapping(value = "/unqualified/stock/out/list/auth")
+    @ManagerAuth
+    public R stockOutListUnqualified(@RequestParam(defaultValue = "1")Integer curr,
+                          @RequestParam(defaultValue = "10")Integer limit,
+                          @RequestParam Map<String, Object> param){
+        param.put("danger",2);
+        if (!Cools.isEmpty(param.get("modi_time"))){
+            String val = String.valueOf(param.get("modi_time"));
+            if (val.contains(RANGE_TIME_LINK)) {
+                String[] dates = val.split(RANGE_TIME_LINK);
+                param.put("startTime", DateUtils.convert(dates[0]));
+                param.put("endTime", DateUtils.convert(dates[1]));
+                param.remove("modi_time");
+            }
+        }
+        Page<LocDetl> stockOut = locDetlService.getStockOut(toPage(curr, limit, param, LocDetl.class));
+        if (stockOut.getRecords().size()==0){
+            stockOut = locDetlService.getStockOut(toPage(1, limit, param, LocDetl.class));
+        }
+        return R.ok(stockOut);
+    }
+
     @RequestMapping(value = "/locDetl/list/auth")// /locDetl/list/auth 鎺ュ彛闂
     @ManagerAuth
     public R list(@RequestParam(defaultValue = "1")Integer curr,
diff --git a/src/main/java/com/zy/asrs/controller/WorkController.java b/src/main/java/com/zy/asrs/controller/WorkController.java
index c55fc5f..7417d1d 100644
--- a/src/main/java/com/zy/asrs/controller/WorkController.java
+++ b/src/main/java/com/zy/asrs/controller/WorkController.java
@@ -18,10 +18,7 @@
 import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.RestController;
 
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 
 /**
  * 宸ヤ綔娴佹帴鍙f帶鍒跺櫒
@@ -52,19 +49,46 @@
     public R availableTakeSite(){
         List<Map<String, Object>> result = new ArrayList<>();
         List<Integer> outSite = basDevpService.getAvailableOutSite(101);
-        for (Integer siteId : outSite) {
-            Map<String, Object> map = new HashMap<>();
-            map.put("siteId", siteId);
-            map.put("desc", siteId + "锛堝叏鏉垮嚭搴撳彛锛�");
-            result.add(map);
-        }
         List<Integer> pickOutSite = basDevpService.getAvailableOutSite(103);
-        for (Integer siteId : pickOutSite) {
-            Map<String, Object> map = new HashMap<>();
-            map.put("siteId", siteId);
-            map.put("desc", siteId + "锛堟嫞鏂欏嚭搴撳彛锛�");
-            result.add(map);
+        List<Integer> siteList = new ArrayList<>();
+        for (Integer siteOut : outSite) {
+            for (Integer sitePickOut : pickOutSite) {
+                if (siteOut.equals(sitePickOut)) {
+                    Map<String, Object> map = new HashMap<>();
+                    map.put("siteId", siteOut);
+                    map.put("desc", siteOut + "锛堝嚭搴撳彛锛�");
+                    result.add(map);
+                    siteList.add(siteOut);
+                }
+            }
         }
+        for (Integer siteId : outSite) {
+            if (!siteList.contains(siteId)) {
+                Map<String, Object> map = new HashMap<>();
+                map.put("siteId", siteId);
+                map.put("desc", siteId + "锛堝叏鏉垮嚭搴撳彛锛�");
+                result.add(map);
+            }
+        }
+        for (Integer siteId : pickOutSite) {
+            if (!siteList.contains(siteId)) {
+                Map<String, Object> map = new HashMap<>();
+                map.put("siteId", siteId);
+                map.put("desc", siteId + "锛堟嫞鏂欏嚭搴撳彛锛�");
+                result.add(map);
+            }
+        }
+        return R.ok().add(result);
+    }
+
+    @RequestMapping("/unqualified/available/take/site")
+    @ManagerAuth()
+    public R availableTakeSiteUnqualified(){
+        List<Map<String, Object>> result = new ArrayList<>();
+        Map<String, Object> map = new HashMap<>();
+        map.put("siteId", 212);
+        map.put("desc", 212 + "锛堥��搴撳彛锛�");
+        result.add(map);
         return R.ok().add(result);
     }
 
@@ -93,6 +117,14 @@
         return R.ok("鍑哄簱鍚姩鎴愬姛");
     }
 
+    @RequestMapping("/unqualified/plate/out/start")
+    @ManagerAuth(memo = "涓嶅悎鏍煎搧鍑哄簱")
+    public R fullStoreTakeStartUnqualified(@RequestBody StockOutParam param) {
+        param.setOrderNo("涓嶅悎鏍煎搧鍑哄簱");
+        workService.startupFullTakeStore(param, getUserId());
+        return R.ok("鍑哄簱鍚姩鎴愬姛");
+    }
+
     @RequestMapping("/plate/order/out/start")
     @ManagerAuth(memo = "鎵嬪姩璁㈠崟鍑哄簱浣滀笟")
     public R fullStoreTakeStartOrder(@RequestBody StockOutParam param) {
diff --git a/src/main/resources/mapper/LocDetlMapper.xml b/src/main/resources/mapper/LocDetlMapper.xml
index adb8138..655435c 100644
--- a/src/main/resources/mapper/LocDetlMapper.xml
+++ b/src/main/resources/mapper/LocDetlMapper.xml
@@ -110,6 +110,12 @@
         <if test="specs!=null and specs!='' ">
             and a.specs like '%' + #{specs} + '%'
         </if>
+        <if test="model!=null and model!='' ">
+            and a.model like '%' + #{model} + '%'
+        </if>
+        <if test="danger!=null">
+            and a.danger = #{danger}
+        </if>
     </sql>
 
     <select id="getStockOutPage" resultMap="BaseResultMap">
diff --git a/src/main/webapp/static/js/common.js b/src/main/webapp/static/js/common.js
index c2f93d8..f839655 100644
--- a/src/main/webapp/static/js/common.js
+++ b/src/main/webapp/static/js/common.js
@@ -225,7 +225,7 @@
 var detlCols = [
     {field: 'matnr', align: 'center',title: '瑙勬牸', sort:false, hide: false}
     ,{field: 'maktx', align: 'center',title: '鍝佸悕', sort:true, hide: true}
-    ,{field: 'orderNo', align: 'center',title: '鍗曟嵁缂栧彿', hide: true}
+    ,{field: 'orderNo', align: 'center',title: '鍗曟嵁缂栧彿', hide: false}
     ,{field: 'batch', align: 'center',title: '绠卞彿', hide: false, sort:true}
     ,{field: 'model', align: 'center',title: '鍗峰彿', hide: false}
     ,{field: 'brand', align: 'center',title: '鏈ㄧ绫诲瀷', hide: true, sort:true}
diff --git a/src/main/webapp/static/js/locDetl/locDetl.js b/src/main/webapp/static/js/locDetl/locDetl.js
index a5c21d6..042a7bb 100644
--- a/src/main/webapp/static/js/locDetl/locDetl.js
+++ b/src/main/webapp/static/js/locDetl/locDetl.js
@@ -4,7 +4,7 @@
         {field: 'locNo$', align: 'center',title: '搴撲綅鍙�'},
         {field: 'matnr', align: 'center',title: '瑙勬牸', sort:true}
         ,{field: 'maktx', align: 'center',title: '鍟嗗搧鍚嶇О', sort:true}
-        ,{field: 'orderNo', align: 'center',title: '鍗曟嵁缂栧彿', hide: true}
+        ,{field: 'orderNo', align: 'center',title: '鍗曟嵁缂栧彿', hide: false}
         ,{field: 'batch', align: 'center',title: '绠卞彿', width: 300, sort:true}
         ,{field: 'anfme', align: 'center',title: '鏁伴噺'}
         ,{field: 'zpallet', align: 'center',title: '鎵樼洏鏉$爜'}
diff --git a/src/main/webapp/static/js/manLocDetl/manLocDetl.js b/src/main/webapp/static/js/manLocDetl/manLocDetl.js
index 5cfaef9..477e948 100644
--- a/src/main/webapp/static/js/manLocDetl/manLocDetl.js
+++ b/src/main/webapp/static/js/manLocDetl/manLocDetl.js
@@ -4,7 +4,7 @@
         {field: 'locNo', align: 'center',title: '搴撲綅鍙�'},
         {field: 'matnr', align: 'center',title: '瑙勬牸', sort:true}
         ,{field: 'maktx', align: 'center',title: '鍟嗗搧鍚嶇О', sort:true}
-        ,{field: 'orderNo', align: 'center',title: '鍗曟嵁缂栧彿', hide: true}
+        ,{field: 'orderNo', align: 'center',title: '鍗曟嵁缂栧彿', hide: false}
         ,{field: 'batch', align: 'center',title: '绠卞彿', width: 300, sort:true}
         ,{field: 'anfme', align: 'center',title: '鏁伴噺'}
         //,{field: 'zpallet', align: 'center',title: '鎵樼洏鏉$爜'}
diff --git a/src/main/webapp/static/js/pakStore/stockOutUnqualified.js b/src/main/webapp/static/js/pakStore/stockOutUnqualified.js
new file mode 100644
index 0000000..6abe44d
--- /dev/null
+++ b/src/main/webapp/static/js/pakStore/stockOutUnqualified.js
@@ -0,0 +1,179 @@
+var locDetlLayerIdx;
+var locDetlData = [];
+var admin;
+function getCol() {
+    var cols = [
+        // {field: 'count', align: 'center',title: '鍑哄簱鏁伴噺', edit:'text', width: 130,  style:'color: blue;font-weight: bold'},
+        {field: 'anfme', align: 'center',title: '鏁伴噺'}
+        ,{field: 'locNo$', align: 'center',title: '搴撲綅鍙�'}
+    ];
+    arrRemove(detlCols,  'field', 'anfme');
+    cols.push.apply(cols, detlCols);
+    cols.push({fixed: 'right', title:'鎿嶄綔', align: 'center', toolbar: '#operate', width: 80})
+    return cols;
+}
+
+layui.config({
+    base: baseUrl + "/static/layui/lay/modules/"
+}).use(['table','laydate', 'form', 'admin'], function() {
+    var table = layui.table;
+    var $ = layui.jquery;
+    var layer = layui.layer;
+    var form = layui.form;
+    admin = layui.admin;
+
+    tableIns = table.render({
+        elem: '#chooseData',
+        headers: {token: localStorage.getItem('token')},
+        data: [],
+        even: true,
+        toolbar: '#toolbar',
+        cellMinWidth: 50,
+        limit: 500,
+        cols: [getCol()],
+        done: function(res, curr, count) {
+            limit();
+            getOutBound();
+        }
+    });
+
+    // 椤甸潰淇敼
+    table.on('edit(chooseData)', function (obj) {
+        let index = obj.tr.attr("data-index");
+        let data = locDetlData[index];
+        let modify = true;
+        // if (obj.field === 'count'){
+        //     let vle = Number(obj.value);
+        //     if (isNaN(vle)) {
+        //         layer.msg("璇疯緭鍏ユ暟瀛�", {icon: 2});
+        //         modify = false;
+        //     } else {
+        //         if (vle <= 0) {
+        //             layer.msg("鏁伴噺蹇呴』澶т簬闆�", {icon: 2});
+        //             modify = false;
+        //         }
+        //         if (vle > Number(data.anfme)) {
+        //             layer.msg("鍑哄簱鏁伴噺涓嶅緱澶т簬搴撳瓨鏁伴噺", {icon: 2});
+        //             modify = false;
+        //         }
+        //     }
+        // }
+        if (modify) {
+            data[obj.field] = obj.value;
+        }
+        tableIns.reload({data: locDetlData});
+    });
+
+    // 鐩戝惉澶村伐鍏锋爮浜嬩欢
+    table.on('toolbar(chooseData)', function (obj) {
+        switch (obj.event) {
+            case 'outbound':
+                if (locDetlData.length === 0){
+                    layer.msg('璇峰厛鎻愬彇鍟嗗搧搴撳瓨', {icon: 2});
+                } else {
+                    var staNo = $("#staNoSelect").val();
+                    if (staNo === "" || staNo === null){
+                        layer.msg("璇烽�夋嫨鍑哄簱鍙�", {icon: 2});
+                        return;
+                    }
+                    let param = {
+                        outSite: staNo,
+                        locDetls: locDetlData
+                    }
+                    $.ajax({
+                        url: baseUrl+"/unqualified/plate/out/start",
+                        headers: {'token': localStorage.getItem('token')},
+                        data: JSON.stringify(param),
+                        contentType:'application/json;charset=UTF-8',
+                        method: 'POST',
+                        success: function (res) {
+                            if (res.code === 200){
+                                locDetlData = [];
+                                tableIns.reload({data: locDetlData,done:function (res) {limit();getOutBound();}});
+                                layer.msg(res.msg, {icon: 1});
+                            } else if (res.code === 403){
+                                top.location.href = baseUrl+"/";
+                            } else {
+                                layer.msg(res.msg, {icon: 2})
+                            }
+                        }
+                    });
+                }
+                break;
+        }
+    });
+
+    // 鐩戝惉琛屽伐鍏蜂簨浠�
+    table.on('tool(chooseData)', function(obj){
+        switch (obj.event) {
+            case 'remove':
+                let index = obj.tr.attr("data-index");
+                locDetlData.splice(index, 1);
+                tableIns.reload({data: locDetlData});
+                break;
+        }
+    });
+
+    // 鑾峰彇鍑哄簱鍙�
+    function getOutBound(){
+        $.ajax({
+            url: baseUrl+"/unqualified/available/take/site",
+            headers: {'token': localStorage.getItem('token')},
+            method: 'POST',
+            async: 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)
+                }
+            }
+        })
+    }
+
+
+    $(document).on('click','#mat-query', function () {
+        let loadIndex = layer.msg('璇锋眰涓�...', {icon: 16, shade: 0.01, time: false});
+        locDetlLayerIdx = layer.open({
+            type: 2,
+            title: false,
+            closeBtn: false,
+            maxmin: false,
+            area: ['90%', '85%'],
+            shadeClose: true,
+            content: 'locDetlQueryUnqualified.html',
+            success: function(layero, index){
+                layer.close(loadIndex);
+            }
+        });
+    })
+
+})
+
+// 娣诲姞琛ㄦ牸鏁版嵁
+function addTableData(data) {
+    for (var i=0;i<data.length;i++){
+        let pass = false;
+        for (var j=0;j<locDetlData.length;j++){
+            if (data[i].matnr === locDetlData[j].matnr && data[i].batch === locDetlData[j].batch && data[i].locNo$ === locDetlData[j].locNo$) {
+                pass = true;
+                break;
+            }
+        }
+        if (pass) {
+            data.splice(i--, 1);
+        } else {
+            data[i]["count"] = data[i]["anfme"];
+        }
+    }
+    locDetlData.push.apply(locDetlData, data);
+    tableIns.reload({data: locDetlData});
+    layer.close(locDetlLayerIdx);
+}
+
diff --git a/src/main/webapp/views/pakStore/locDetlQuery.html b/src/main/webapp/views/pakStore/locDetlQuery.html
index 154ff98..4564c85 100644
--- a/src/main/webapp/views/pakStore/locDetlQuery.html
+++ b/src/main/webapp/views/pakStore/locDetlQuery.html
@@ -74,7 +74,12 @@
         </div>
         <div class="layui-inline">
             <div class="layui-input-inline">
-                <input class="layui-input" type="text" name="batch" placeholder="鎵瑰彿" autocomplete="off">
+                <input class="layui-input" type="text" name="batch" placeholder="绠卞彿" autocomplete="off">
+            </div>
+        </div>
+        <div class="layui-inline">
+            <div class="layui-input-inline">
+                <input class="layui-input" type="text" name="model" placeholder="鍗峰彿" autocomplete="off">
             </div>
         </div>
         <!-- 鏃ユ湡鑼冨洿 -->
@@ -86,6 +91,7 @@
         <!-- 寰呮坊鍔� -->
         <div id="data-search-btn" class="layui-btn-container layui-form-item" style="display: inline-block">
             <button id="search" class="layui-btn layui-btn-primary layui-btn-radius" lay-submit lay-filter="search">鎼滅储</button>
+            <button id="reset" class="layui-btn layui-btn-primary layui-btn-radius" lay-submit lay-filter="reset">閲嶇疆</button>
         </div>
     </div>
 </fieldset>
@@ -200,6 +206,13 @@
             tableReload();
         });
 
+        // 鎼滅储鏍忛噸缃簨浠�
+        form.on('submit(reset)', function (data) {
+            pageCurr = 1;
+            clearFormVal($('#search-box'));
+            tableReload(false);
+        });
+
         layDate.render({
             elem: '.layui-laydate-range'
             ,type: 'datetime'
@@ -216,6 +229,13 @@
             where: searchData,
         });
     }
+
+    function clearFormVal(el) {
+        $(':input', el)
+            .val('')
+            .removeAttr('checked')
+            .removeAttr('selected');
+    }
 </script>
 </html>
 
diff --git a/src/main/webapp/views/pakStore/locDetlQueryUnqualified.html b/src/main/webapp/views/pakStore/locDetlQueryUnqualified.html
new file mode 100644
index 0000000..c620358
--- /dev/null
+++ b/src/main/webapp/views/pakStore/locDetlQueryUnqualified.html
@@ -0,0 +1,241 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+    <meta charset="utf-8">
+    <title></title>
+    <meta name="renderer" content="webkit">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
+    <link rel="stylesheet" href="../../static/layui/css/layui.css" media="all">
+    <link rel="stylesheet" href="../../static/css/admin.css?v=318" media="all">
+    <link rel="stylesheet" href="../../static/css/cool.css" media="all">
+    <link rel="stylesheet" href="../../static/css/common.css" media="all">
+    <style>
+        body {
+        }
+        .layui-table-box {
+            border-right: 1px solid #9F9F9F;
+            border-left: 1px solid #9F9F9F;
+        }
+
+        #search-box {
+            padding: 30px 0 20px 0;
+        }
+        #search-box .layui-inline:first-child {
+            margin-left: 30px;
+        }
+        #search-box .layui-inline {
+            margin-right: 5px;
+        }
+
+        #data-search-btn {
+            margin-left: 10px;
+            display: inline-block;
+        }
+        #data-search-btn.layui-btn-container .layui-btn {
+            margin-right: 20px;
+        }
+    </style>
+</head>
+<body>
+<div style="padding: 25px; line-height: 22px; background-color: #393D49; color: #fff; font-weight: 300;">
+    <span style="font-size: large; font-weight: bold">鎻愬彇搴撳瓨鍟嗗搧</span>
+</div>
+<!-- 鎼滅储鏍� -->
+<fieldset class="layui-elem-field site-demo-button" style="margin: 20px;">
+    <legend>鎼滅储鏍�</legend>
+    <!-- 鎼滅储鏍� -->
+    <div id="search-box" class="layui-form layui-card-header">
+        <div class="layui-inline">
+            <div class="layui-input-inline cool-auto-complete">
+                <input id="crnNo" class="layui-input" name="crnNo" type="text" placeholder="璇疯緭鍏�" autocomplete="off" style="display: none">
+                <input id="crnNo$" class="layui-input cool-auto-complete-div" onclick="autoShow(this.id)" type="text" placeholder="鍫嗗灈鏈哄彿" onfocus=this.blur()>
+                <div class="cool-auto-complete-window">
+                    <input class="cool-auto-complete-window-input" data-key="basCrnpQueryBycrnNo" onkeyup="autoLoad(this.getAttribute('data-key'))">
+                    <select class="cool-auto-complete-window-select" data-key="basCrnpQueryBycrnNoSelect" onchange="confirmed(this.getAttribute('data-key'))" multiple="multiple">
+                    </select>
+                </div>
+            </div>
+        </div>
+        <div class="layui-inline">
+            <div class="layui-input-inline">
+                <input class="layui-input" type="text" name="loc_no" placeholder="搴撲綅鍙�" autocomplete="off">
+            </div>
+        </div>
+        <div class="layui-inline">
+            <div class="layui-input-inline">
+                <input class="layui-input" type="text" name="matnr" placeholder="瑙勬牸"  autocomplete="off">
+            </div>
+        </div>
+        <div class="layui-inline">
+            <div class="layui-input-inline">
+                <input class="layui-input" type="text" name="maktx" placeholder="鐗╂枡鍚嶇О" autocomplete="off">
+            </div>
+        </div>
+        <div class="layui-inline">
+            <div class="layui-input-inline">
+                <input class="layui-input" type="text" name="batch" placeholder="绠卞彿" autocomplete="off">
+            </div>
+        </div>
+        <div class="layui-inline">
+            <div class="layui-input-inline">
+                <input class="layui-input" type="text" name="model" placeholder="鍗峰彿" autocomplete="off">
+            </div>
+        </div>
+        <!-- 鏃ユ湡鑼冨洿 -->
+        <div class="layui-inline" style="width: 300px">
+            <div class="layui-input-inline">
+                <input class="layui-input layui-laydate-range" name="modi_time" type="text" placeholder="璧峰鏃堕棿 - 缁堟鏃堕棿" autocomplete="off" style="width: 300px">
+            </div>
+        </div>
+        <!-- 寰呮坊鍔� -->
+        <div id="data-search-btn" class="layui-btn-container layui-form-item" style="display: inline-block">
+            <button id="search" class="layui-btn layui-btn-primary layui-btn-radius" lay-submit lay-filter="search">鎼滅储</button>
+            <button id="reset" class="layui-btn layui-btn-primary layui-btn-radius" lay-submit lay-filter="reset">閲嶇疆</button>
+        </div>
+    </div>
+</fieldset>
+
+<script type="text/html" id="toolbar">
+    <div class="layui-btn-container">
+        <button class="layui-btn" id="btn-confirm" lay-event="confirm" style="">鎻愬彇</button>
+    </div>
+</script>
+
+<div class="layui-form">
+    <table class="layui-hide" id="stockOut" lay-filter="stockOut"></table>
+</div>
+
+<script type="text/javascript" src="../../static/js/jquery/jquery-3.3.1.min.js"></script>
+<script type="text/javascript" src="../../static/layui/layui.js" charset="utf-8"></script>
+<script type="text/javascript" src="../../static/js/common.js" charset="utf-8"></script>
+<script type="text/javascript" src="../../static/js/cool.js" charset="utf-8"></script>
+<script type="text/javascript" src="../../static/js/handlebars/handlebars-v4.5.3.js"></script>
+
+</body>
+<script>
+
+    function getCol() {
+        var cols = [
+            {type: 'checkbox', merge: ['locNo']}
+            ,{field: 'locNo', align: 'center',title: '搴撲綅鍙�', merge: true, style: 'font-weight: bold'}
+            // ,{field: 'locNo$', align: 'center',title: '搴撲綅鍙�'}
+        ];
+        cols.push.apply(cols, detlCols);
+        cols.push({field: 'modiUser$', align: 'center',title: '淇敼浜哄憳', hide: true}
+            ,{field: 'modiTime$', align: 'center',title: '淇敼鏃堕棿'})
+        return cols;
+    }
+
+    layui.config({
+        base: baseUrl + "/static/layui/lay/modules/"
+    }).use(['table','laydate', 'form', 'admin', 'tableMerge'], function() {
+        var table = layui.table;
+        var $ = layui.jquery;
+        var layer = layui.layer;
+        var layDate = layui.laydate;
+        var form = layui.form;
+        var admin = layui.admin;
+        var tableMerge = layui.tableMerge;
+        var dataSource = []
+
+        // 鏁版嵁娓叉煋
+        locDetlTableIns = table.render({
+            elem: '#stockOut',
+            headers: {token: localStorage.getItem('token')},
+            url: baseUrl+'/unqualified/stock/out/list/auth',
+            page: true,
+            limits: [16, 30, 50, 100, 200, 500],
+            limit: 16,
+            even: true,
+            toolbar: '#toolbar',
+            cellMinWidth: 50,
+            cols: [getCol()],
+            request: {
+                pageName: 'curr',
+                pageSize: 'limit'
+            },
+            parseData: function (res) {
+                dataSource = res.data.records
+                return {
+                    'code': res.code,
+                    'msg': res.msg,
+                    'count': res.data.total,
+                    'data': res.data.records
+                }
+            },
+            response: {
+                statusCode: 200
+            },
+            done: function(res, curr, count) {
+                tableMerge.render(this);
+                if (res.code === 403) {
+                    top.location.href = baseUrl+"/";
+                }
+            }
+        });
+
+        // 鐩戝惉澶村伐鍏锋爮浜嬩欢
+        table.on('toolbar(stockOut)', function (obj) {
+
+            var checkStatus = table.checkStatus(obj.config.id);
+            var data = checkStatus.data;
+            var dataList = []
+            for (var j = 0; j < data.length; j++) {
+                var locno = data[j].locNo
+                for(var i = 0;i < dataSource.length; i++) {
+                    if (dataSource[i].locNo === locno) {
+                        dataList.push(dataSource[i])
+                    }
+                }
+            }
+
+            switch(obj.event) {
+                case 'confirm':
+                    if (data.length === 0){
+                        layer.msg("璇烽�夋嫨鏁版嵁");
+                        return;
+                    }
+                    parent.addTableData(dataList);
+                    break;
+            }
+        });
+
+        // 鎼滅储鏍忔悳绱簨浠�
+        form.on('submit(search)', function (data) {
+            tableReload();
+        });
+
+        // 鎼滅储鏍忛噸缃簨浠�
+        form.on('submit(reset)', function (data) {
+            pageCurr = 1;
+            clearFormVal($('#search-box'));
+            tableReload(false);
+        });
+
+        layDate.render({
+            elem: '.layui-laydate-range'
+            ,type: 'datetime'
+            ,range: true
+        });
+    })
+
+    function tableReload() {
+        var searchData = {};
+        $.each($('#search-box [name]').serializeArray(), function() {
+            searchData[this.name] = this.value;
+        });
+        locDetlTableIns.reload({
+            where: searchData,
+        });
+    }
+
+    function clearFormVal(el) {
+        $(':input', el)
+            .val('')
+            .removeAttr('checked')
+            .removeAttr('selected');
+    }
+</script>
+</html>
+
diff --git a/src/main/webapp/views/pakStore/stockOutUnqualified.html b/src/main/webapp/views/pakStore/stockOutUnqualified.html
new file mode 100644
index 0000000..147214a
--- /dev/null
+++ b/src/main/webapp/views/pakStore/stockOutUnqualified.html
@@ -0,0 +1,132 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+    <meta charset="utf-8">
+    <title></title>
+    <meta name="renderer" content="webkit">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
+    <link rel="stylesheet" href="../../static/layui/css/layui.css" media="all">
+    <link rel="stylesheet" href="../../static/css/admin.css?v=318" media="all">
+    <link rel="stylesheet" href="../../static/css/cool.css" media="all">
+    <link rel="stylesheet" href="../../static/css/common.css" media="all">
+    <style>
+        html {
+            height: 100%;
+            padding: 10px;
+            background-color: #f1f1f1;
+            box-sizing: border-box;
+        }
+        body {
+            background-color: #fff;
+            border-radius: 5px;
+            box-shadow: 0 0 3px rgba(0,0,0,.3);
+            padding-bottom: 20px;
+        }
+
+        #staNoSpan {
+            text-align: center;
+            display: inline-block;
+            width: 100px;
+            font-size: 13px;
+        }
+        .layui-btn-container .layui-form-select {
+            display: inline-block;
+            width: 150px;
+            height: 30px;
+        }
+        .layui-btn-container .layui-form-select.layui-form-selected {
+            display: inline-block;
+            width: 150px;
+        }
+        .layui-btn-container .layui-select-title input {
+            font-size: 13px;
+        }
+        .layui-btn-container .layui-anim.layui-anim-upbit dd {
+            font-size: 13px;
+        }
+
+        #btn-outbound {
+            margin-left: 60px;
+            display: none;
+        }
+
+        /*----------------------------------*/
+        .function-area {
+            padding: 20px 50px;
+        }
+        .function-btn {
+            font-size: 16px;
+            padding: 1px 2px;
+            width: 100px;
+            height: 50px;
+            border-color: #2b425b;
+            border-radius: 4px;
+            border-width: 2px;
+            background: none;
+            border-style: solid;
+            transition: 0.4s;
+            cursor: pointer;
+            letter-spacing: 1.5px;
+        }
+        .function-btn:hover {
+            background-color: #2b425b;
+            color: #fff;
+        }
+
+        #mat-query {
+            display: none;
+        }
+    </style>
+</head>
+<body>
+
+<!-- 鍔熻兘鍖� -->
+<div class="function-area">
+    <button id="mat-query" class="function-btn">鎻愬彇搴撳瓨</button>
+</div>
+
+<hr>
+
+<!-- 琛ㄦ牸 -->
+<div style="padding-bottom: 5px; margin-bottom: 45px">
+
+    <!-- 澶撮儴 -->
+    <script type="text/html" id="toolbar">
+        <div class="layui-form">
+            <div class="layui-btn-container">
+                <!-- 1.閫夋嫨鍑哄簱鍙� -->
+                <span id="staNoSpan">鍑哄簱鍙o細</span>
+                <select id="staNoSelect" lay-verify="required">
+                    <option value="">璇烽�夋嫨绔欑偣</option>
+                </select>
+                <!-- 2.鍚姩鍑哄簱 -->
+                <button class="layui-btn layui-btn-lg" id="btn-outbound" lay-event="outbound">鍚姩鍑哄簱</button>
+            </div>
+        </div>
+    </script>
+
+    <!-- 琛� -->
+    <script type="text/html" id="operate">
+        <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="remove">绉婚櫎</a>
+    </script>
+
+    <table class="layui-table" id="chooseData" lay-filter="chooseData"></table>
+</div>
+
+<script type="text/javascript" src="../../static/js/jquery/jquery-3.3.1.min.js"></script>
+<script type="text/javascript" src="../../static/layui/layui.js" charset="utf-8"></script>
+<script type="text/javascript" src="../../static/js/jquery/jQuery.print.js"></script>
+<script type="text/javascript" src="../../static/js/common.js" charset="utf-8"></script>
+<script type="text/javascript" src="../../static/js/cool.js" charset="utf-8"></script>
+<script type="text/javascript" src="../../static/js/handlebars/handlebars-v4.5.3.js"></script>
+<script type="text/javascript" src="../../static/js/pakStore/stockOutUnqualified.js" charset="utf-8"></script>
+
+<script type="text/template" id="takeSiteSelectTemplate">
+    {{#each data}}
+    <option value="{{siteId}}">{{desc}}</option>
+    {{/each}}
+</script>
+</body>
+</html>
+

--
Gitblit v1.9.1