From d9ba49392dfc5a6f74e867607372b12ebbf2f5c4 Mon Sep 17 00:00:00 2001 From: joylink_fanyuhong <18706759286@163.com> Date: Thu, 22 Feb 2024 11:10:39 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AB=9E=E8=B5=9B=E8=B0=83=E6=95=B4=E6=9A=82?= =?UTF-8?q?=E6=8F=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/contest.js | 123 +++++++++++++ src/router/index.js | 10 +- .../contestSceneManage/ContestSceneManage.vue | 114 +++++++++++- .../ContestSeasonManage.vue | 119 +++++++++++- .../contestSeasonManage/add.vue | 107 +++++++++++ .../ContestTaskScoreManage.vue | 106 ++++++++++- .../contestTaskScoreManage/add.vue | 71 +++++++ .../contestTaskScoreManage/detailAdd.vue | 100 ++++++++++ .../contestTaskScoreManage/edit.vue | 131 +++++++++++++ .../contestTaskScoreManage/importScene.vue | 173 ++++++++++++++++++ .../contestTaskScoreManage/selectScene.vue | 113 ++++++++++++ 11 files changed, 1161 insertions(+), 6 deletions(-) create mode 100644 src/views/contestDataManage/contestSeasonManage/add.vue create mode 100644 src/views/contestDataManage/contestTaskScoreManage/add.vue create mode 100644 src/views/contestDataManage/contestTaskScoreManage/detailAdd.vue create mode 100644 src/views/contestDataManage/contestTaskScoreManage/edit.vue create mode 100644 src/views/contestDataManage/contestTaskScoreManage/importScene.vue create mode 100644 src/views/contestDataManage/contestTaskScoreManage/selectScene.vue diff --git a/src/api/contest.js b/src/api/contest.js index e69de29bb..123007ad1 100644 --- a/src/api/contest.js +++ b/src/api/contest.js @@ -0,0 +1,123 @@ +import request from '@/utils/request'; + +// 竞赛赛季添加 +export function addContestSeason(data) { + return request({ + url: '/api/exercise/race/season', + method: 'post', + data + }); +} +// 竞赛赛季分页查询 +export function queryContestSeasonPaged(params) { + return request({ + url: '/api/exercise/race/season/page', + method: 'get', + params + }); +} +// 竞赛赛季修改 +export function updateContestSeason(id, data) { + return request({ + url: `/api/exercise/race/season/${id}`, + method: 'post', + data + }); +} +// 竞赛赛季删除 +export function deleteContestSeason(id) { + return request({ + url: `/api/exercise/race/season/${id}`, + method: 'delete' + }); +} +// 竞赛场景分页查询 +export function queryContestSencePaged(params) { + return request({ + url: '/api/exercise/race/scene/page', + method: 'get', + params + }); +} +// 竞赛场景删除 +export function deleteContestSence(id) { + return request({ + url: `/api/exercise/race/scene/${id}`, + method: 'delete' + }); +} +// 竞赛评分创建基本信息 +export function createContextScore(data) { + return request({ + url: '/api/exercise/race/score', + method: 'post', + data + }); +} +// 竞赛评分列表分页 +export function queryContextScorePaged(params) { + return request({ + url: '/api/exercise/race/score/page', + method: 'get', + params + }); +} +// 竞赛评分删除 +export function deleteContextScore(id) { + return request({ + url: `/api/exercise/race/score/${id}`, + method: 'delete' + }); +} +// 竞赛评分修改评分详情内容 +export function updateContextScoreDetail(id, data) { + return request({ + url: `/api/exercise/race/score/edit/rule/${id}`, + method: 'post', + data + }); +} +// 竞赛评分绑定任务(废弃) +/* export function contextScoreBindTask(ruleId, taskId) { + return request({ + url: `/api/exercise/race/score/${ruleId}/${taskId}/bind/task`, + method: 'post' + }); +}*/ +// 竞赛评分详情 +export function getContextScoreDetail(id) { + return request({ + url: `/api/exercise/race/score/${id}`, + method: 'get' + }); +} +// 竞赛场景分页列表 +export function queryContextSencePaged(params) { + return request({ + url: '/api/exercise/race/scene/page', + method: 'get', + params + }); +} +// 竞赛场景删除 +export function deleteContextSence(id) { + return request({ + url: `/api/exercise/race/scene/${id}`, + method: 'delete' + }); +} +// 竞赛场景详情 +export function getContextSenceDetail(id) { + return request({ + url: `/api/exercise/race/scene/${id}`, + method: 'get' + }); +} +// 实训场景发布到大赛场景 +export function publishContextSence(data) { + return request({ + url: `/api/exercise/race/scene/publish/training`, + method: 'post', + data + }); +} diff --git a/src/router/index.js b/src/router/index.js index 796366d38..e1ea739b9 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -227,7 +227,8 @@ const ContestModuleManage = () => import('@/views/contestDataManage/contestModul const ContestTaskManage = () => import('@/views/contestDataManage/contestTaskManage/ContestTaskManage'); const ContestSceneManage = () => import('@/views/contestDataManage/contestSceneManage/ContestSceneManage'); const ContestTaskScoreManage = () => import('@/views/contestDataManage/contestTaskScoreManage/ContestTaskScoreManage'); -const ContestSeasonManage = () => import('@/views/contestDataManage/contestSceneManage/ContestSceneManage'); +const ContestSeasonManage = () => import('@/views/contestDataManage/contestSeasonManage/ContestSeasonManage'); +const ContestScoreEdit = () => import('@/views/contestDataManage/contestTaskScoreManage/edit'); // import { GenerateRouteProjectList } from '@/scripts/ProjectConfig'; // import { getSessionStorage } from '@/utils/auth'; @@ -2072,7 +2073,12 @@ export const asyncRouter = [ } }, { - // 竞赛场景草稿管理 + path: 'contestTaskScoreEdit', + component: ContestScoreEdit, + hidden: true + }, + { + // 竞赛赛季管理 path: 'contestSeasonManage', component: ContestSeasonManage, meta: { diff --git a/src/views/contestDataManage/contestSceneManage/ContestSceneManage.vue b/src/views/contestDataManage/contestSceneManage/ContestSceneManage.vue index d4073f7d6..6de1f793f 100644 --- a/src/views/contestDataManage/contestSceneManage/ContestSceneManage.vue +++ b/src/views/contestDataManage/contestSceneManage/ContestSceneManage.vue @@ -1,3 +1,115 @@ - 竞赛场景管理 + + + + + + + diff --git a/src/views/contestDataManage/contestSeasonManage/ContestSeasonManage.vue b/src/views/contestDataManage/contestSeasonManage/ContestSeasonManage.vue index 1bde31f0e..50ea3cf75 100644 --- a/src/views/contestDataManage/contestSeasonManage/ContestSeasonManage.vue +++ b/src/views/contestDataManage/contestSeasonManage/ContestSeasonManage.vue @@ -1,10 +1,125 @@ - 竞赛赛季管理 + + + + diff --git a/src/views/contestDataManage/contestSeasonManage/add.vue b/src/views/contestDataManage/contestSeasonManage/add.vue new file mode 100644 index 000000000..ba311037c --- /dev/null +++ b/src/views/contestDataManage/contestSeasonManage/add.vue @@ -0,0 +1,107 @@ + + + + + + + + + + + + + + + + + {{ $t('global.confirm') }} + {{ $t('global.cancel') }} + + + + + diff --git a/src/views/contestDataManage/contestTaskScoreManage/ContestTaskScoreManage.vue b/src/views/contestDataManage/contestTaskScoreManage/ContestTaskScoreManage.vue index 333be95c2..104115f03 100644 --- a/src/views/contestDataManage/contestTaskScoreManage/ContestTaskScoreManage.vue +++ b/src/views/contestDataManage/contestTaskScoreManage/ContestTaskScoreManage.vue @@ -1,3 +1,107 @@ - 竞赛任务评分管理 + + + + + + + + diff --git a/src/views/contestDataManage/contestTaskScoreManage/add.vue b/src/views/contestDataManage/contestTaskScoreManage/add.vue new file mode 100644 index 000000000..ed02864ed --- /dev/null +++ b/src/views/contestDataManage/contestTaskScoreManage/add.vue @@ -0,0 +1,71 @@ + + + + + + + + + {{ $t('global.confirm') }} + {{ $t('global.cancel') }} + + + + + diff --git a/src/views/contestDataManage/contestTaskScoreManage/detailAdd.vue b/src/views/contestDataManage/contestTaskScoreManage/detailAdd.vue new file mode 100644 index 000000000..77ded7491 --- /dev/null +++ b/src/views/contestDataManage/contestTaskScoreManage/detailAdd.vue @@ -0,0 +1,100 @@ + + + + + + + + + + + + + + + + + + + + + {{ $t('global.confirm') }} + {{ $t('global.cancel') }} + + + + + diff --git a/src/views/contestDataManage/contestTaskScoreManage/edit.vue b/src/views/contestDataManage/contestTaskScoreManage/edit.vue new file mode 100644 index 000000000..3ebccd532 --- /dev/null +++ b/src/views/contestDataManage/contestTaskScoreManage/edit.vue @@ -0,0 +1,131 @@ + + + + + 评分规则详情 + + 添加 + 场景导入 + 清空 + 保存 + 返回 + + + + + + + + + + + + 编辑 + 删除 + + + + + + + + + + + + + diff --git a/src/views/contestDataManage/contestTaskScoreManage/importScene.vue b/src/views/contestDataManage/contestTaskScoreManage/importScene.vue new file mode 100644 index 000000000..d204ac74b --- /dev/null +++ b/src/views/contestDataManage/contestTaskScoreManage/importScene.vue @@ -0,0 +1,173 @@ + + + + + + + + + + + + + 导入 + + + + + + + + + + + + + + + + + diff --git a/src/views/contestDataManage/contestTaskScoreManage/selectScene.vue b/src/views/contestDataManage/contestTaskScoreManage/selectScene.vue new file mode 100644 index 000000000..38524d43b --- /dev/null +++ b/src/views/contestDataManage/contestTaskScoreManage/selectScene.vue @@ -0,0 +1,113 @@ + + + + + + + + +