| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">提货方式:</label> |
| | | <div class="layui-input-inline"> |
| | | <select name="deliverType"> |
| | | <option value="">请选择</option> |
| | | <option value="1">快递寄送</option> |
| | | <option value="2">到店自提</option> |
| | | </select> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">订单状态:</label> |
| | | <div class="layui-input-inline"> |
| | | <select name="status"> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">支付状态:</label> |
| | | <label class="layui-form-label">发货状态:</label> |
| | | <div class="layui-input-inline"> |
| | | <select name="payResult"> |
| | | <select name="deliverState"> |
| | | <option value="">请选择</option> |
| | | <option value="1">成功</option> |
| | | <option value="2">未成功</option> |
| | | <option value="1">待发货</option> |
| | | <option value="2">已发货</option> |
| | | <option value="3">已签收</option> |
| | | </select> |
| | | </div> |
| | | </div> |
| | |
| | | </div> |
| | | </form> |
| | | <table lay-filter="orderTable" lay-data="{id: 'orderTable'}"></table> |
| | | <style type="text/css"> |
| | | .layui-table-cell{ |
| | | text-align:center; |
| | | height: auto; |
| | | white-space: nowrap; /*文本不会换行,在同一行显示*/ |
| | | overflow: hidden; /*超出隐藏*/ |
| | | text-overflow: ellipsis; /*省略号显示*/ |
| | | } |
| | | .layui-table img{ |
| | | max-width:100px |
| | | } |
| | | </style> |
| | | <!-- <style type="text/css">--> |
| | | <!-- .layui-table-cell{--> |
| | | <!-- text-align:center;--> |
| | | <!-- height: auto;--> |
| | | <!-- white-space: nowrap; /*文本不会换行,在同一行显示*/--> |
| | | <!-- overflow: hidden; /*超出隐藏*/--> |
| | | <!-- text-overflow: ellipsis; /*省略号显示*/--> |
| | | <!-- }--> |
| | | <!-- .layui-table img{--> |
| | | <!-- max-width:100px--> |
| | | <!-- }--> |
| | | <!-- </style>--> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <!-- 表格操作栏 start --> |
| | | <script type="text/html" id="mall-order-option"> |
| | | {{# if(d.status === 2) { }} |
| | | <button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="deliverGoods">发货</button> |
| | | <button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="orderMoneyFlow">资金流水</button> |
| | | {{# } else if(d.status === 3) { }} |
| | | <button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="delOrder">删除</button> |
| | | {{# } else { }} |
| | | {{# } }} |
| | | </script> |
| | | <script type="text/html" id="user-option"> |
| | | <span shiro:lacksPermission="user:view,user:update,user:delete"> |
| | | <span class="layui-badge-dot febs-bg-orange"></span> 无权限 |
| | |
| | | }); |
| | | |
| | | function delOrder(id) { |
| | | febs.get(ctx + 'admin/order/delOrder/' + id, null, function () { |
| | | febs.get(ctx + 'admin/goods/delOrder/' + id, null, function () { |
| | | febs.alert.success('操作成功'); |
| | | $query.click(); |
| | | }); |
| | |
| | | {field: 'address', title: '购买人', minWidth: 120,align:'left'}, |
| | | {field: 'goodsName', title: '商品信息', minWidth: 200,align:'left'}, |
| | | {field: 'amount', title: '订单金额', minWidth: 120,align:'left',totalRow: '{{= parseInt(d.amount) }}'}, |
| | | {field: 'status', title: '状态', |
| | | {field: 'deliverType', title: '提货方式', |
| | | templet: function (d) { |
| | | if (d.deliverType === 1) { |
| | | return '<span style="color:blue;">快递寄送</span>' |
| | | } else if (d.deliverType === 2) { |
| | | return '<span style="color:green;">到店自提</span>' |
| | | }else{ |
| | | return '' |
| | | } |
| | | }, minWidth: 80,align:'center'}, |
| | | {field: 'status', title: '订单状态', |
| | | templet: function (d) { |
| | | if (d.status === 1) { |
| | | return '<span style="color:blue;">待支付</span>' |
| | |
| | | return '' |
| | | } |
| | | }, minWidth: 80,align:'center'}, |
| | | {field: 'deliverState', title: '发货状态', |
| | | templet: function (d) { |
| | | if (d.deliverState === 1) { |
| | | return '<span style="color:red;">待发货</span>' |
| | | } else if (d.deliverState === 2) { |
| | | return '<span style="color:green;">已发货</span>' |
| | | }else if (d.deliverState === 3) { |
| | | return '<span style="color:blue;">已签收</span>' |
| | | }else{ |
| | | return '' |
| | | } |
| | | }, minWidth: 80,align:'center'}, |
| | | {field: 'orderTime', title: '下单时间', minWidth: 200,align:'left'}, |
| | | {field: 'payMethod', title: '支付方式', minWidth: 120,align:'left'}, |
| | | {field: 'payTime', title: '支付时间', minWidth: 200,align:'left'}, |
| | | {field: 'payOrderNo', title: '支付订单号', minWidth: 200,align:'left'}, |
| | | |
| | | {title: '操作', minWidth: 200 ,toolbar: '#mall-order-option',hide:mallOrderOption,align:'left', fixed:'right'}, |
| | | {title: '操作', |
| | | templet: function (d) { |
| | | if (d.status === 2) { |
| | | if(d.deliverType === 1){ |
| | | if(d.deliverState === 1){ |
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="deliverGoods">发货</button>' |
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="orderMoneyFlow">资金流水</button>' |
| | | }else{ |
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="orderMoneyFlow">资金流水</button>' |
| | | } |
| | | }else{ |
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="orderMoneyFlow">资金流水</button>' |
| | | } |
| | | }else if(d.status === 3){ |
| | | return '<button class="layui-btn layui-btn-warm layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="delOrder">删除</button>' |
| | | }else{ |
| | | return '<button class="layui-btn layui-btn-warm layui-btn-xs" type="button" shiro:hasPermission="orderMoneyFlow:update" lay-event="delOrder">删除</button>' |
| | | } |
| | | },minWidth: 200,align:'center', fixed:'right'} |
| | | ]] |
| | | }); |
| | | } |
| | |
| | | name: $searchForm.find('input[name="name"]').val().trim(), |
| | | orderNo: $searchForm.find('input[name="orderNo"]').val().trim(), |
| | | goodsName: $searchForm.find('input[name="goodsName"]').val().trim(), |
| | | payResult: $searchForm.find("select[name='payResult']").val(), |
| | | deliverState: $searchForm.find("select[name='deliverState']").val(), |
| | | deliverType: $searchForm.find("select[name='deliverType']").val(), |
| | | status: $searchForm.find("select[name='status']").val(), |
| | | }; |
| | | } |