From d3e29108e70d52efa2e0fc239b0daa0586b732b8 Mon Sep 17 00:00:00 2001 From: Administrator <15274802129@163.com> Date: Mon, 28 Apr 2025 15:23:27 +0800 Subject: [PATCH] feat(mall): 添加活动预期数量和剩余数量字段 --- src/main/resources/templates/febs/views/modules/votesActivity/orderList.html | 36 ++++++++---------------------------- 1 files changed, 8 insertions(+), 28 deletions(-) diff --git a/src/main/resources/templates/febs/views/modules/votesActivity/orderList.html b/src/main/resources/templates/febs/views/modules/votesActivity/orderList.html index b2e2b84..a53230f 100644 --- a/src/main/resources/templates/febs/views/modules/votesActivity/orderList.html +++ b/src/main/resources/templates/febs/views/modules/votesActivity/orderList.html @@ -68,7 +68,7 @@ <script type="text/html" id="orderActivityOption"> <!-- <button class="layui-btn layui-btn-normal layui-btn-sm" type="button" shiro:hasPermission="orderActivity:info" lay-event="orderActivity">详情</button>--> - <button class="layui-btn layui-btn-danger layui-btn-sm" type="button" shiro:hasPermission="orderActivity:info" lay-event="groupDelete">删除</button> + <button class="layui-btn layui-btn-danger layui-btn-sm" type="button" shiro:hasPermission="orderActivity:info" lay-event="orderActivityDel">删除</button> <!-- <button class="layui-btn layui-btn-danger layui-btn-sm" type="button" shiro:hasPermission="orderActivity:returnOrder" lay-event="returnOrder">售后退款</button>--> </script> <script type="text/html" id="orderStateOption"> @@ -78,6 +78,9 @@ 2: {title: '待使用', color: 'orange'}, 3: {title: '已使用', color: 'green'}, 4: {title: '售后', color: 'red'}, + 5: {title: '已评价', color: 'black'}, + 6: {title: '删除', color: 'black'}, + 7: {title: '已失效', color: 'black'}, }[d.state]; }} <span class="layui-badge febs-bg-{{state.color}}">{{ state.title }}</span> @@ -144,9 +147,9 @@ table.on('tool(orderActivityTable)', function (obj) { var data = obj.data, layEvent = obj.event; - if (layEvent === 'groupDelete') { + if (layEvent === 'orderActivityDel') { febs.modal.confirm('删除', '确认删除?', function () { - groupDelete(data.id); + orderActivityDel(data.id); }); } if (layEvent === 'groupInfo') { @@ -162,7 +165,7 @@ }); } }); - function groupDelete(id) { + function orderActivityDel(id) { febs.get(ctx + 'admin/happyActivity/activityOrderDel/' + id, null, function (data) { febs.alert.success(data.message); $query.click(); @@ -222,6 +225,7 @@ toolbar:"#orderActivityToolbar", defaultToolbar:[], cols: [[ + {type: 'checkbox'}, {type: 'numbers', title: '', width: 80}, {title: '操作', toolbar: '#orderActivityOption', minWidth: 200, align: 'center'}, {field: 'name', title: '名称', minWidth: 100,align:'center'}, @@ -237,30 +241,6 @@ ]] }); } - - form.on('switch(hotStateSwitch)', function (data) { - if (data.elem.checked) { - groupState(data.value,1); - } else { - groupState(data.value,1); - } - }) - - form.on('switch(groupStatusSwitch)', function (data) { - if (data.elem.checked) { - groupState(data.value,2); - } else { - groupState(data.value,2); - } - }) - function groupState(id,type) { - febs.get(ctx + 'admin/happyActivity/groupState/' + id+'/' + type, null, function (data) { - febs.alert.success(data.message); - $query.click(); - }); - } - - // 查询按钮 $query.on('click', function () { -- Gitblit v1.9.1