2022-05-15 14:37:20 +08:00
|
|
|
<!DOCTYPE html>
|
|
|
|
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
|
|
|
|
<head>
|
|
|
|
|
<th:block th:include="include :: header('订单列表')"/>
|
|
|
|
|
<th:block th:include="include :: layout-latest-css"/>
|
|
|
|
|
<th:block th:include="include :: ztree-css"/>
|
|
|
|
|
</head>
|
|
|
|
|
<body class="gray-bg">
|
|
|
|
|
|
|
|
|
|
<div class="ui-layout-center">
|
|
|
|
|
<div class="container-div">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-sm-12 search-collapse">
|
|
|
|
|
<form id="order-form">
|
|
|
|
|
<input type="hidden" id="deptId" name="deptId">
|
|
|
|
|
<input type="hidden" id="parentId" name="parentId">
|
|
|
|
|
<div class="select-list">
|
|
|
|
|
<ul>
|
|
|
|
|
<li>
|
|
|
|
|
订单号:<input type="text" name="code"/>
|
|
|
|
|
</li>
|
2022-07-08 11:10:55 +08:00
|
|
|
<li>
|
|
|
|
|
订单状态:<select name="status" th:with="type=${@dict.getType('order_status')}">
|
|
|
|
|
<option value="">所有</option>
|
|
|
|
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
|
|
|
|
</select>
|
|
|
|
|
</li>
|
2022-05-15 14:37:20 +08:00
|
|
|
<li>
|
|
|
|
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
|
|
|
|
|
class="fa fa-search"></i> 搜索</a>
|
|
|
|
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
|
|
|
|
|
class="fa fa-refresh"></i> 重置</a>
|
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="btn-group-sm" id="toolbar" role="group">
|
|
|
|
|
<a class="btn btn-warning" onclick="$.table.exportExcel()"
|
|
|
|
|
shiro:hasPermission="order:order:export">
|
|
|
|
|
<i class="fa fa-download"></i> 导出
|
|
|
|
|
</a>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="col-sm-12 select-table table-striped">
|
|
|
|
|
<table id="bootstrap-table"></table>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<th:block th:include="include :: footer"/>
|
|
|
|
|
<th:block th:include="include :: layout-latest-js"/>
|
|
|
|
|
<th:block th:include="include :: ztree-js"/>
|
|
|
|
|
<script th:inline="javascript">
|
2022-05-19 19:31:08 +08:00
|
|
|
var payTypes = [[${@dict.getType('pay_type')}]];
|
|
|
|
|
var orderTypes = [[${@dict.getType('goods_category_type')}]];
|
2022-07-08 11:10:55 +08:00
|
|
|
var payStatus = [[${@dict.getType('pay_status')}]];
|
|
|
|
|
var orderStatus = [[${@dict.getType('order_status')}]];
|
2022-05-19 19:31:08 +08:00
|
|
|
|
2022-05-15 14:37:20 +08:00
|
|
|
var editFlag = [[${@permission.hasPermi('order:order:edit')}]];
|
|
|
|
|
var prefix = ctx + "order/master";
|
|
|
|
|
|
|
|
|
|
$(function () {
|
|
|
|
|
var panehHidden = false;
|
|
|
|
|
if ($(this).width() < 769) {
|
|
|
|
|
panehHidden = true;
|
|
|
|
|
}
|
|
|
|
|
$('body').layout({initClosed: panehHidden, west__size: 185});
|
|
|
|
|
// 回到顶部绑定
|
|
|
|
|
if ($.fn.toTop !== undefined) {
|
|
|
|
|
var opt = {
|
|
|
|
|
win: $('.ui-layout-center'),
|
|
|
|
|
doc: $('.ui-layout-center')
|
|
|
|
|
};
|
|
|
|
|
$('#scroll-up').toTop(opt);
|
|
|
|
|
}
|
|
|
|
|
queryOrderList();
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
function queryOrderList() {
|
|
|
|
|
var options = {
|
|
|
|
|
url: prefix + "/list",
|
|
|
|
|
exportUrl: prefix + "/export",
|
|
|
|
|
sortName: "createTime",
|
|
|
|
|
sortOrder: "desc",
|
|
|
|
|
modalName: "订单",
|
|
|
|
|
columns: [
|
|
|
|
|
{
|
|
|
|
|
checkbox: true
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
field: 'id',
|
|
|
|
|
title: '订单ID',
|
|
|
|
|
visible: false
|
|
|
|
|
},
|
|
|
|
|
{
|
2022-06-01 22:14:02 +08:00
|
|
|
field: 'code',
|
2022-07-08 11:10:55 +08:00
|
|
|
title: '订单号'
|
2022-05-15 14:37:20 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'customerName',
|
|
|
|
|
title: '消费者'
|
2022-05-15 14:37:20 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'orderType',
|
|
|
|
|
title: '订单类型',
|
|
|
|
|
align: 'center',
|
|
|
|
|
formatter: function(value, row, index) {
|
|
|
|
|
return $.table.selectDictLabel(orderTypes, value);
|
2022-05-19 19:31:08 +08:00
|
|
|
}
|
2022-05-15 14:37:20 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'orderStatus',
|
|
|
|
|
title: '订单状态',
|
|
|
|
|
align: 'center',
|
|
|
|
|
formatter: function(value, row, index) {
|
|
|
|
|
return $.table.selectDictLabel(orderStatus, value);
|
2022-06-01 14:50:58 +08:00
|
|
|
}
|
2022-05-15 14:37:20 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'payType',
|
|
|
|
|
title: '付款类型',
|
|
|
|
|
align: 'center',
|
|
|
|
|
formatter: function(value, row, index) {
|
|
|
|
|
return $.table.selectDictLabel(payTypes, value);
|
2022-06-01 14:50:58 +08:00
|
|
|
}
|
2022-05-15 14:37:20 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'payStatus',
|
|
|
|
|
title: '付款状态',
|
|
|
|
|
align: 'center',
|
|
|
|
|
formatter: function(value, row, index) {
|
|
|
|
|
return $.table.selectDictLabel(payStatus, value);
|
2022-05-19 19:31:08 +08:00
|
|
|
}
|
2022-06-01 14:50:58 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'payTime',
|
|
|
|
|
title: '付款时间'
|
2022-06-01 14:50:58 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'workerName',
|
|
|
|
|
title: '接单师傅'
|
2022-06-01 14:50:58 +08:00
|
|
|
},
|
|
|
|
|
{
|
2022-07-08 11:10:55 +08:00
|
|
|
field: 'revTime',
|
|
|
|
|
title: '接单时间'
|
2022-06-01 14:50:58 +08:00
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
field: 'createTime',
|
2022-07-08 11:10:55 +08:00
|
|
|
title: '创建时间',
|
|
|
|
|
sortable: true
|
|
|
|
|
}, {
|
|
|
|
|
title: '操作',
|
|
|
|
|
align: 'left',
|
2022-06-01 22:14:02 +08:00
|
|
|
formatter: function (value, row, index) {
|
|
|
|
|
var actions = [];
|
2022-07-08 11:10:55 +08:00
|
|
|
actions.push('<a class="btn btn-success btn-xs " href="javascript:void(0)" onclick="detail(\'' + row.id + '\')"><i class="fa fa-edit"></i>详情</a> ');
|
2022-06-01 22:14:02 +08:00
|
|
|
return actions.join('');
|
|
|
|
|
}
|
2022-07-08 11:10:55 +08:00
|
|
|
}]
|
2022-05-15 14:37:20 +08:00
|
|
|
};
|
|
|
|
|
$.table.init(options);
|
|
|
|
|
}
|
|
|
|
|
|
2022-05-19 19:31:08 +08:00
|
|
|
function detail(id) {
|
2022-05-19 21:40:00 +08:00
|
|
|
var url = "order/goods?orderId=" + id;
|
|
|
|
|
$.modal.open("商品信息", url);
|
2022-05-19 19:31:08 +08:00
|
|
|
}
|
|
|
|
|
|
2022-05-15 14:37:20 +08:00
|
|
|
</script>
|
|
|
|
|
</body>
|
|
|
|
|
|
|
|
|
|
</html>
|