Răsfoiți Sursa

refactor(system): 优化游戏事件相关接口调用

- 在调用列表接口时添加排序参数 orderByColumn 和 isAsc
- 移除游戏得分查询中的冗余注释
zhou 2 săptămâni în urmă
părinte
comite
5e0e9d7434
2 a modificat fișierele cu 26 adăugiri și 13 ștergeri
  1. 24 8
      src/views/system/gameEvent/edit.vue
  2. 2 5
      src/views/system/gameScore/index.vue

+ 24 - 8
src/views/system/gameEvent/edit.vue

@@ -499,7 +499,9 @@ const loadGroupData = async (eventId: string | number) => {
     const res = await listGameEventGroup({
       eventId,
       pageNum: 1,
-      pageSize: 1000
+      pageSize: 1000,
+      orderByColumn: '',
+      isAsc: ''
     });
     groupItems.value = Array.isArray(res.rows) ? res.rows : [];
   } catch (error) {
@@ -555,7 +557,9 @@ const loadMenuData = async (eventId: string | number) => {
     const res = await listGameEventMenu({
       eventId,
       pageNum: 1,
-      pageSize: 1000
+      pageSize: 1000,
+      orderByColumn: '',
+      isAsc: ''
     });
     menuItems.value = Array.isArray(res.rows) ? res.rows : [];
   } catch (error) {
@@ -618,7 +622,9 @@ const loadImageConfigData = async (eventId: string | number) => {
     const templateRes = await listGameEventConfig({
       configType: 'IMAGE',
       pageNum: 1,
-      pageSize: 100
+      pageSize: 100,
+      orderByColumn: '',
+      isAsc: ''
     });
     
     // 获取所有图片配置模板
@@ -629,7 +635,9 @@ const loadImageConfigData = async (eventId: string | number) => {
       eventId: eventId,
       configType: 'IMAGE',
       pageNum: 1,
-      pageSize: 100
+      pageSize: 100,
+      orderByColumn: '',
+      isAsc: ''
     });
 
     const eventImageConfigs = Array.isArray(eventRes.rows) ? eventRes.rows : [];
@@ -744,7 +752,9 @@ const loadProjectData = async (eventId: string | number) => {
     const res = await listGameEventProject({
       eventId,
       pageNum: 1,
-      pageSize: 1000
+      pageSize: 1000,
+      orderByColumn: '',
+      isAsc: ''
     });
     projectItems.value = Array.isArray(res.rows) ? res.rows : [];
   } catch (error) {
@@ -806,7 +816,9 @@ const loadConfigTypes = async () => {
   try {
     const res = await listGameEventConfigType({
       pageNum: 1,
-      pageSize: 1000
+      pageSize: 1000,
+      orderByColumn: '',
+      isAsc: ''
     });
     configTypes.value = Array.isArray(res.rows) ? res.rows : [];
   } catch (error) {
@@ -820,7 +832,9 @@ const loadConfigData = async (eventId: string | number) => {
     const res = await listGameEventConfig({
       eventId,
       pageNum: 1,
-      pageSize: 10
+      pageSize: 10,
+      orderByColumn: '',
+      isAsc: ''
     });
     configItems.value = Array.isArray(res.rows) ? res.rows : [];
   } catch (error) {
@@ -880,7 +894,9 @@ const loadTeamData = async (eventId: string | number) => {
     const res = await listGameTeam({
       eventId,
       pageNum: 1,
-      pageSize: 1000
+      pageSize: 1000,
+      orderByColumn: '',
+      isAsc: ''
     });
     teamItems.value = Array.isArray(res.rows) ? res.rows : [];
   } catch (error) {

+ 2 - 5
src/views/system/gameScore/index.vue

@@ -145,11 +145,8 @@ const data = reactive<PageData<GameScoreForm, GameScoreQuery>>({
     pageNum: 1,
     pageSize: 10,
     eventId: undefined,
-    // projectId: undefined,
-    // athleteId: undefined,
-    // teamId: undefined,
-    // statusFlag: undefined,
-    // params: {}
+    orderByColumn: '',
+    isAsc: ''
   },
   rules: {}
 });