| | |
| | | <!-- 头部 --> |
| | | <header> |
| | | <div class="layui-input-inline"> |
| | | <label class="layui-form-label">条码</label> |
| | | <label class="layui-form-label">托盘码</label> |
| | | <input class="layui-input" type="number" id="code" onkeyup="findCode(this)" oninput="if(value.length>8)value=value.slice(0,8)" placeholder="扫码 / 输入" autocomplete="off"> |
| | | </div> |
| | | <div style="margin: 5px 5px"> |
| | |
| | | cellMinWidth: 50, |
| | | cols: [[ |
| | | {fixed: 'left', align: 'center', field: 'count', title: '数量', style:'color: blue', width:50}, |
| | | {field: 'matNo', align: 'center', title: '物料编码'}, |
| | | {field: 'matName', align: 'center', title: '物料名称'} |
| | | {field: 'matNo', align: 'center', title: '产品代号'}, |
| | | {field: 'matName', align: 'center', title: '产品名称'}, |
| | | {field: 'supplier', align: 'center', title: '批号'}, |
| | | {field: 'memo', align: 'center', title: '生产日期'} |
| | | |
| | | ]], |
| | | done: function (res, curr, count) { |
| | | } |
| | |
| | | function getMat() { |
| | | matCodeLayerIdx = layer.open({ |
| | | type: 2, |
| | | title: '提取物料', |
| | | title: '提取产品', |
| | | shade: [0.3,'#000'], |
| | | area: ['90%', '80%'], |
| | | content: 'matQuery.html', |
| | |
| | | } |
| | | let toPush = true; |
| | | for (var j=0;j<matData.length;j++){ |
| | | if (data.matNo === matData[j].matNo) { |
| | | if (data.matNo === matData[j].matNo && data.supplier === matData[j].supplier) { |
| | | matData[j].count = Number(matData[j].count) + Number(data.count); |
| | | toPush = false; |
| | | } |
| | |
| | | return; |
| | | } |
| | | if (matData.length === 0) { |
| | | tips("请提取物料", true); |
| | | tips("请提取产品", true); |
| | | return; |
| | | } |
| | | $.ajax({ |