From bc52f606d965585ab8a14730a2ec96e5f7197c67 Mon Sep 17 00:00:00 2001
From: liujie <1793218484@qq.com>
Date: 星期一, 18 八月 2025 10:40:41 +0800
Subject: [PATCH] 赛事模块

---
 cloud-server-management/src/main/webapp/static/modular/system/worldCup/worldCup.js |   34 ++++++++++++++++++++++++++++++++--
 1 files changed, 32 insertions(+), 2 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 92d5ee9..658d6d0 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,13 @@
 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: 'type', visible: true, align: 'center', valign: 'middle',width:'20%',
+            formatter:function (data) {
+                return {1:"智慧赛事",2:"非智慧赛事"}[data]
+            }
+        },
         {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,7 +96,30 @@
 };
 
 
+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("取消成功");
+                    WorldCup.search();
+                    layer.closeAll();
+                }else{
+                    Feng.error(res.msg);
+                }
+            }, function (data) {
+                Feng.error("取消失败!" + data.responseJSON.message + "!");
+            });
+            ajax.set("id", id);
+            ajax.set("state", 3);
+            ajax.start();
+        };
+        Feng.confirm("是否取消赛事:       " + WorldCup.seItem.name + "?",operation);
 
+    }
+}
 
 
 
@@ -131,6 +159,7 @@
     queryData['startTime'] =$("#startTime").val();
     queryData['endTime'] =$("#endTime").val();
     queryData['status'] =$("#status").val();
+    queryData['type'] =$("#type").val();
     WorldCup.table.refresh({query: queryData});
 };
 
@@ -139,6 +168,7 @@
     $("#startTime").val("");
     $("#endTime").val("");
     $("#status").val("");
+    $("#type").val("");
     WorldCup.search();
 };
 

--
Gitblit v1.7.1