记得上下班打卡 | git大法好,push需谨慎

Commit a1c8039b authored by 张国柄's avatar 张国柄

+折扣券列表页面;

parent d900e685
coupon1.html<!DOCTYPE html>
<!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 :: header('折扣券')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="coupon-form">
<div class="select-list">
<ul>
<input type="hidden" name="couType" value="4" />
<li>
<input type="text" name="keyword" placeholder="搜索"/>
</li>
<li>
类型:<select name="bindType" th:with="type=${@dict.getType('zhengzai_coupon_bind_type')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
适用范围:<select name="busiType" th:with="type=${@dict.getType('zhengzai_coupon_busi_type')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add(4)" shiro:hasPermission="candy:coupon:mgt:add">
<i class="fa fa-plus"></i> 添加
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="coupon-form">
<div class="select-list">
<ul>
<input type="hidden" name="couType" value="1" />
<li>
<input type="text" name="keyword" placeholder="搜索"/>
</li>
<li>
类型:<select name="bindType" th:with="type=${@dict.getType('zhengzai_coupon_bind_type')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
适用范围:<select name="busiType" th:with="type=${@dict.getType('zhengzai_coupon_busi_type')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.addTab(4)" shiro:hasPermission="candy:coupon:mgt:add">
<i class="fa fa-plus"></i> 新增
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var couponCodeListFlag = [[${@permission.hasPermi('system:role:edit')}]];
var prefix = ctx + "candy/coupon/mgt";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add/{id}",
// updateUrl: prefix + "/edit/{id}",
// removeUrl: prefix + "/remove",
// exportUrl: prefix + "/export",
sortName: "createdAt",
modalName: "折扣券",
columns: [{
checkbox: true
},
{
field: 'valFace',
title: '金额'
},
{
field: 'eventAmt',
title: '数量',
},
{
field: 'bindType',
title: '类型',
sortable: true
},
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var couponCodeListFlag = [[${@permission.hasPermi('system:role:edit')}]];
var prefix = ctx + "candy/coupon/mgt";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add/{id}",
// updateUrl: prefix + "/edit/{id}",
// removeUrl: prefix + "/remove",
// exportUrl: prefix + "/export",
sortName: "createdAt",
modalName: "折扣券",
columns: [{
checkbox: true
},
{
field: 'discount',
title: '折扣'
},
{
field: 'eventAmt',
title: '数量',
},
{
field: 'bindType',
title: '类型',
sortable: true
},
{
field: 'busiType',
title: '适用范围',
......@@ -98,29 +98,29 @@ coupon1.html<!DOCTYPE html>
title: '生成时间',
sortable: true
},
{
field: 'expireAt',
title: '失效时间',
sortable: true
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push("<a class='btn btn-default btn-xs " + couponCodeListFlag + "' href='javascript:void(0)' onclick='authUser(" + row.roleId + ")'><i class='fa fa-user'></i></a>");
return actions.join('');
}
}]
};
$.table.init(options);
});
/* 券码列表 */
function couponCodeList(couponId) {
var url = prefix + '/code/' + couponId;
$.modal.openTab("查看码列表", url);
}
</script>
{
field: 'expireAt',
title: '失效时间',
sortable: true
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="couponCodeList(\'' + row.couponId + '\')"><i class="fa fa-list-ul"></i>查看码列表</a> ');
return actions.join('');
}
}]
};
$.table.init(options);
});
/* 查看码列表 */
function couponCodeList(couponId) {
var url = 'candy/coupon/code?couponId=' + couponId;
$.modal.openTab("查看码列表", url);
}
</script>
</body>
</html>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment