From c0abf1b8be71aef5089151ca8601a3b69b21a09d Mon Sep 17 00:00:00 2001 From: 无关风月 <443237572@qq.com> Date: 星期二, 01 四月 2025 18:10:10 +0800 Subject: [PATCH] 惠民卡代码 --- cloud-server-management/src/main/webapp/static/modular/system/worldCup/worldCup.js | 58 +++++++++++++++++++++++----------------------------------- 1 files changed, 23 insertions(+), 35 deletions(-) diff --git a/cloud-server-management/src/main/webapp/static/modular/system/worldCup/worldCup.js b/cloud-server-management/src/main/webapp/static/modular/system/worldCup/worldCup.js index 7c71ebd..432c659 100644 --- a/cloud-server-management/src/main/webapp/static/modular/system/worldCup/worldCup.js +++ b/cloud-server-management/src/main/webapp/static/modular/system/worldCup/worldCup.js @@ -13,8 +13,8 @@ WorldCup.initColumn = function () { return [ {field: 'selectItem', checkbox: true}, - {title: 'id', field: 'id', visible: false, align: 'center', valign: 'middle'}, - {title: '比赛名字', field: 'name', visible: true, align: 'center', valign: 'middle',width:'20%',}, + {title: 'id', field: 'id', visible: true, align: 'center', valign: 'middle'}, + {title: '比赛名称', field: 'name', visible: true, align: 'center', valign: 'middle',width:'20%',}, {title: '开始时间', field: 'startTime', visible: true, align: 'center', valign: 'middle',}, {title: '结束时间', field: 'endTime', visible: true, align: 'center', valign: 'middle'}, {title: '报名条件', field: 'age', visible: true, align: 'center', valign: 'middle', @@ -91,30 +91,28 @@ }; -/** - * 删除 - */ -WorldCup.cancelWorldCup = function (){ +WorldCup.cancelWorldCup = function(){ if(this.check()){ var operation = function(){ + layer.load(); + var id = WorldCup.seItem.id; var ajax = new $ax(Feng.ctxPath + "/worldCup/updateState", function (res) { - if (res.code == 200) { - Feng.success("删除成功"); + if(res.code == 200){ + Feng.success("取消成功"); + WorldCup.search(); layer.closeAll(); - WorldCup.table.refresh(); - } else { + }else{ Feng.error(res.msg); } }, function (data) { - Feng.error("添加失败!" + data.responseJSON.message + "!"); + Feng.error("取消失败!" + data.responseJSON.message + "!"); }); - ajax.setData({ - 'id': WorldCup.seItem.id, - 'state': 4 - }); + ajax.set("id", id); + ajax.set("state", 3); ajax.start(); }; - Feng.confirm("确认取消所选比赛吗?",operation); + Feng.confirm("是否取消赛事: " + WorldCup.seItem.name + "?",operation); + } } @@ -126,25 +124,15 @@ */ WorldCup.registeredPersonnel = function () { if(this.check()){ - var operation = function(){ - var ajax = new $ax(Feng.ctxPath + "/worldCup/updateState", function (res) { - if (res.code == 200) { - Feng.success("删除成功"); - layer.closeAll(); - WorldCup.table.refresh(); - } else { - Feng.error(res.msg); - } - }, function (data) { - Feng.error("添加失败!" + data.responseJSON.message + "!"); - }); - ajax.setData({ - 'id': WorldCup.seItem.id, - 'state': 2 - }); - ajax.start(); - }; - Feng.confirm("是否冻结裁判:" + WorldCup.seItem.name + "?",operation); + var index = layer.open({ + type: 2, + title: '已报名人员', + area: ['100%', '100%'], //宽高 + fix: false, //不固定 + maxmin: true, + content: Feng.ctxPath + '/worldCup/openRegisteredPersonnel?id=' + WorldCup.seItem.id + }); + this.layerIndex = index; } }; -- Gitblit v1.7.1