| | |
| | | pakout.setBatch(mat.getBatch()); |
| | | pakout.setUnit(mat.getUnit()); |
| | | pakout.setBarcode(mat.getBarcode()); |
| | | pakout.setCustName(mat.getCustName()); |
| | | // pakout.setCustName(mat.getCustName()); |
| | | pakout.setItemNum(mat.getItemNum()); |
| | | pakout.setCount(mat.getCount()); |
| | | pakout.setPrice(mat.getPrice()); |
| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | import zy.cloud.wms.common.web.BaseController; |
| | | import zy.cloud.wms.manager.entity.Cstmr; |
| | | import zy.cloud.wms.manager.entity.Mat; |
| | | import zy.cloud.wms.manager.service.CstmrService; |
| | | |
| | | import java.util.*; |
| | |
| | | @Autowired |
| | | private CstmrService cstmrService; |
| | | |
| | | @RequestMapping(value = "/cstmr/list/pda/auth") |
| | | @ManagerAuth |
| | | public R pdaList(@RequestParam(required = false)Long cstmrId){ |
| | | EntityWrapper<Cstmr> wrapper = new EntityWrapper<>(); |
| | | // wrapper.eq("id", cstmrId); |
| | | wrapper.orderBy("create_time", false); |
| | | hostEq(wrapper); |
| | | List<Cstmr> cstmrs = cstmrService.selectList(wrapper); |
| | | return R.ok().add(cstmrs); |
| | | } |
| | | |
| | | @RequestMapping(value = "/cstmr/search/pda/auth") |
| | | @ManagerAuth |
| | | public R pdaSearch(@RequestParam(required = false)String condition){ |
| | | EntityWrapper<Cstmr> wrapper = new EntityWrapper<>(); |
| | | if (!Cools.isEmpty(condition)) { |
| | | wrapper.like("name", condition); |
| | | } |
| | | wrapper.orderBy("create_time", false); |
| | | hostEq(wrapper); |
| | | List<Cstmr> cstmrs = cstmrService.selectList(wrapper); |
| | | return R.ok().add(cstmrs); |
| | | } |
| | | |
| | | @RequestMapping(value = "/cstmr/{id}/auth") |
| | | @ManagerAuth |
| | | public R get(@PathVariable("id") String id) { |
| | |
| | | import zy.cloud.wms.manager.service.CstmrService; |
| | | import zy.cloud.wms.manager.service.OrderDetlService; |
| | | import zy.cloud.wms.manager.service.OrderService; |
| | | import zy.cloud.wms.system.entity.Host; |
| | | import zy.cloud.wms.system.service.HostService; |
| | | |
| | | import java.util.*; |
| | | |
| | |
| | | private OrderDetlService orderDetlService; |
| | | @Autowired |
| | | private CstmrService cstmrService; |
| | | @Autowired |
| | | private HostService hostService; |
| | | |
| | | @RequestMapping(value = "/delivery/head/page/auth") |
| | | @ManagerAuth |
| | |
| | | } |
| | | Date now = new Date(); |
| | | |
| | | Host host = hostService.selectById(getHostId()); |
| | | // 返回视图对象 |
| | | List<Map<String, Object>> vos = new ArrayList<>(); |
| | | length = Optional.ofNullable(length).orElse(10); |
| | |
| | | vo.setCstmrContacts(cstmr.getContacts()); |
| | | vo.setCstmrAddr(cstmr.getAddr()); |
| | | } |
| | | vo.setCompany("浙江中扬立库技术有限公司"); |
| | | vo.setCompany(host.getMemo()); |
| | | vo.setOrderId(orderId); |
| | | vo.setOrderNo(order.getOrderNo()); |
| | | vo.setTime(DateUtils.convert(now, DateUtils.yyyyMMdd_F)); |
| | |
| | | |
| | | private Double count; |
| | | |
| | | private String cstmr; |
| | | |
| | | } |
| | |
| | | null, // SKC |
| | | null, // 单据类型 |
| | | null, // 单据编号 |
| | | null, // 客户名称 |
| | | param.getCstmr(), // 客户名称 |
| | | null, // 品项数 |
| | | null, // 数量 |
| | | null, // 重量 |
| | |
| | | select * from man_loc_detl mld left join man_node mn on mld.node_id = mn.id |
| | | where 1=1 |
| | | and mn.uuid = #{uuid} |
| | | and mld.hostId = #{hostId} |
| | | and mld.host_id = #{hostId} |
| | | and mld.status = 1 |
| | | order by mld.create_time |
| | | </select> |
| | |
| | | ,{field: 'model', align: 'center',title: '型号', hide: true} |
| | | ,{field: 'batch', align: 'center',title: '批号', hide: true} |
| | | ,{field: 'unit', align: 'center',title: '单位', hide: true} |
| | | ,{field: 'barcode', align: 'center',title: 'SKC', hide: false} |
| | | ,{field: 'barcode', align: 'center',title: 'SKC', hide: true} |
| | | ,{field: 'docId', align: 'center',title: '单据类型', hide: true} |
| | | ,{field: 'docNum', align: 'center',title: '单据编号'} |
| | | ,{field: 'custName', align: 'center',title: '客户名称', hide: true} |
| | | ,{field: 'custName', align: 'center',title: '客户名称', hide: false} |
| | | ,{field: 'itemNum', align: 'center',title: '品项数', hide: true} |
| | | ,{field: 'count', align: 'center',title: '数量', hide: true} |
| | | ,{field: 'weight', align: 'center',title: '重量', hide: true} |
| | |
| | | <div class="layui-body"></div> |
| | | <!-- 底部 --> |
| | | <div class="layui-footer layui-text"> |
| | | copyright © 2021 浙江中扬立库技术有限公司 all rights reserved. |
| | | copyright © 2021 绍兴孚惠科技有限公司 all rights reserved. |
| | | <span class="pull-right">Version 1.0.0</span> |
| | | </div> |
| | | |
| | |
| | | </form> |
| | | </div> |
| | | </div> |
| | | <div class="loginbm">技术支持: 浙江中扬立库技术有限公司 CopyRight@ 2021 </div> |
| | | <div class="loginbm">技术支持: 绍兴孚惠科技有限公司 CopyRight@ 2021 </div> |
| | | </div> |
| | | |
| | | <!--初始化加载层--> |
| | |
| | | height: 40px; |
| | | } |
| | | |
| | | #selectBtn { |
| | | float: right; |
| | | vertical-align: middle; |
| | | padding: 1px 3px; |
| | | height: 26px; |
| | | } |
| | | |
| | | |
| | | .number-tool { |
| | | margin-left: 10px; |
| | | padding: 1px 0 1px 5px; |
| | |
| | | <span>名称</span> |
| | | <input id="maktx" type="text" disabled="disabled" style="width: 70%"> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span>客户</span> |
| | | <input id="cstmr" type="text" disabled="disabled" style="width: 60%"> |
| | | <input id="cstmrId" type="hidden"> |
| | | <button id="selectBtn">选</button> |
| | | </div> |
| | | <div class="form-item" style="margin-top: 5px"> |
| | | <span style="vertical-align: middle">数量</span> |
| | | <div class="number-tool" style="vertical-align: middle"> |
| | |
| | | offset: '20px', |
| | | title: '直接出库', |
| | | shadeClose: true, |
| | | area: ['80%', '200px'], |
| | | area: ['80%', '240px'], |
| | | content: $("#pakout"), |
| | | success: function (layero, index) { |
| | | $('#matnr').val(data.matnr); |
| | |
| | | } |
| | | } |
| | | |
| | | function findBySelect(val, cstmrId) { |
| | | $("#cstmr").val(val); |
| | | $("#cstmrId").val(cstmrId); |
| | | layer.close(cstmrSelectIdx); |
| | | } |
| | | |
| | | var cstmrSelectIdx; |
| | | $(document).on('click','#selectBtn', function () { |
| | | cstmrSelectIdx = layer.open({ |
| | | type: 2, |
| | | title: false, |
| | | area: ['80%', '58%'], |
| | | content: 'selectCstmr.html', |
| | | success: function(layero, index){ |
| | | $('.layui-layer-setwin .layui-layer-close2').hide(); |
| | | } |
| | | }); |
| | | }) |
| | | |
| | | |
| | | /************************************* 弹窗 ****************************************/ |
| | | var countDom = $('#count'); |
| | |
| | | function yes(){ |
| | | var matnr = $('#matnr').val(); |
| | | var count = $('#count').val(); |
| | | var cstmr = $('#cstmr').val(); |
| | | for (var j=0;j<locDetlData.length;j++){ |
| | | if (matnr === locDetlData[j].matnr) { |
| | | if (count <= minCount) { |
| | |
| | | data: JSON.stringify({ |
| | | nodeUuid: nodeUuid, |
| | | matnr: matnr, |
| | | count: count |
| | | count: count, |
| | | cstmr: cstmr |
| | | }), |
| | | contentType:'application/json;charset=UTF-8', |
| | | async: false, |
| | | method: 'POST', |
| | | success: function (res) { |
| | | layer.close(anfmeLayer); |
| | | $('#cstmr').val(''); |
| | | if (res.code === 200) { |
| | | tips("出库成功"); |
| | | findLoc(document.getElementById("locNo")); |
| New file |
| | |
| | | <!DOCTYPE html> |
| | | <html lang="en"> |
| | | <head> |
| | | <meta charset="UTF-8"> |
| | | <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"/> |
| | | <title>商品选择</title> |
| | | <link rel="stylesheet" href="../../static/layui/css/layui.css" media="all"> |
| | | <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/layui/layer_mobile/layer.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> |
| | | <style> |
| | | html { |
| | | height: 100%; |
| | | } |
| | | body { |
| | | height: 100%; |
| | | background-color: #f1f1f1; |
| | | padding: 5px; |
| | | position: relative; |
| | | } |
| | | |
| | | /*header {*/ |
| | | /* position: absolute;*/ |
| | | /*}*/ |
| | | main { |
| | | padding-bottom: 5px; |
| | | } |
| | | |
| | | /* 头部搜索栏 */ |
| | | .search-box { |
| | | height: 36px; |
| | | padding: 3px 15px; |
| | | } |
| | | .search-box input { |
| | | border: none; |
| | | border-radius: 20px; |
| | | height: 30px; |
| | | box-shadow: 0 0 3px rgba(0,0,0,.3); |
| | | width: 73%; |
| | | padding-left: 15px; |
| | | vertical-align: middle; |
| | | } |
| | | .search-box button { |
| | | border: none; |
| | | background-color: white; |
| | | box-shadow: 0 0 3px rgba(0,0,0,.3); |
| | | height: 33px; |
| | | margin-left: 5px; |
| | | border-radius: 20px; |
| | | width: 15%; |
| | | vertical-align: middle; |
| | | } |
| | | .search-box button:hover { |
| | | background-color: #dedede; |
| | | } |
| | | |
| | | /* 主体 */ |
| | | |
| | | /* 归类标签 */ |
| | | .box-cstmr-item { |
| | | height: 100px; |
| | | border-bottom: 1px solid #dedede; |
| | | background-color: #fff; |
| | | border-radius: 5px; |
| | | box-shadow: 0 0 3px rgba(0,0,0,.3); |
| | | margin-top: 2px; |
| | | } |
| | | .box-cstmr-item:hover { |
| | | background-color: #eaeaea; |
| | | } |
| | | .box-cstmr-item-label { |
| | | padding: 5px 10px; |
| | | border-bottom: 1px solid #f6f6f6; |
| | | } |
| | | .box-cstmr-item-content { |
| | | font-size: x-large; |
| | | font-weight: bold; |
| | | padding: 15px 0 0 20px; |
| | | } |
| | | </style> |
| | | </head> |
| | | <body> |
| | | |
| | | <header> |
| | | <div class="search-box"> |
| | | <input id="search-msg" type="text" placeholder="请输入客户名称"> |
| | | <button onclick="search()"> |
| | | <i class="layui-icon"></i> |
| | | </button> |
| | | </div> |
| | | </header> |
| | | |
| | | <main id="main-contain"> |
| | | </main> |
| | | |
| | | </body> |
| | | <script> |
| | | $(function () { |
| | | showCstmr(); |
| | | }) |
| | | |
| | | // 搜索 |
| | | function search(){ |
| | | var condition = $('#search-msg').val(); |
| | | $.ajax({ |
| | | url: baseUrl + "/cstmr/search/pda/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | data: { |
| | | condition: condition |
| | | }, |
| | | method: 'POST', |
| | | success: function (res) { |
| | | if (res.code === 200) { |
| | | if (res.data != null && res.data.length > 0) { |
| | | var tplDom = $("#matTpl"); |
| | | var tpl = tplDom.html(); |
| | | var template = Handlebars.compile(tpl); |
| | | var html = template(res); |
| | | $('#main-contain').html(html); |
| | | } else { |
| | | $('#main-contain').html('<div style="text-align: center; margin-top: 15px"><span style="font-size: large">暂无商品</span></div>'); |
| | | } |
| | | } else if (res.code === 403) { |
| | | top.location.href = baseUrl + "/pda"; |
| | | } else { |
| | | parent.layer.msg(res.msg, {icon: 2}); |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | |
| | | // 归类点击 |
| | | $(document).on('click','.box-cstmr-item', function () { |
| | | var cstmrId = $(this).children('input').get(0).value; |
| | | var cstmrName = $(this).children('.box-cstmr-item-content').get(0).innerHTML; |
| | | parent.findBySelect(cstmrName,cstmrId) |
| | | }) |
| | | |
| | | // 展示归类 |
| | | function showCstmr(){ |
| | | $.ajax({ |
| | | url: baseUrl + "/cstmr/list/pda/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | data: { |
| | | }, |
| | | method: 'POST', |
| | | success: function (res) { |
| | | if (res.code === 200) { |
| | | if (res.data != null && res.data.length > 0) { |
| | | var tplDom = $("#cstmrTpl"); |
| | | var tpl = tplDom.html(); |
| | | var template = Handlebars.compile(tpl); |
| | | var html = template(res); |
| | | $('#main-contain').html(html); |
| | | toTop(); |
| | | } |
| | | } else if (res.code === 403) { |
| | | top.location.href = baseUrl + "/pda"; |
| | | } else { |
| | | parent.layer.msg(res.msg, {icon: 2}); |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | |
| | | |
| | | function toTop() { |
| | | window.scrollTo({ |
| | | left: 0, |
| | | top: 0, |
| | | behavior: 'smooth' |
| | | }) |
| | | } |
| | | |
| | | |
| | | </script> |
| | | <script type="text/template" id="cstmrTpl"> |
| | | {{#each data}} |
| | | <div class="box-cstmr-item"> |
| | | <input name="cstmrId" type="hidden" value="{{this.id}}"> |
| | | <div class="box-cstmr-item-label"> |
| | | <span class="layui-badge layui-badge-green pull-right">客户</span> |
| | | </div> |
| | | <div class="box-cstmr-item-content">{{this.name}}</div> |
| | | </div> |
| | | {{/each}} |
| | | </script> |
| | | </html> |