This commit is contained in:
fan 2024-03-01 13:53:30 +08:00
commit a69657c8e6
6 changed files with 98 additions and 62 deletions

View File

@ -230,6 +230,7 @@ const ContestSeasonManage = () => import('@/views/contestDataManage/contestSeaso
const ContestScoreEdit = () => import('@/views/contestDataManage/contestTaskScoreManage/edit');
const ContestList = () => import('@/views/contest/contestList');
const ContestDetail = () => import('@/views/contest/contestDetail');
const ScoringSettlement = () => import('@/views/contest/ScoringSettlement');
// import { GenerateRouteProjectList } from '@/scripts/ProjectConfig';
// import { getSessionStorage } from '@/utils/auth';
@ -690,6 +691,11 @@ export const publicAsyncRoute = [
path: 'detail',
component: ContestDetail,
hidden: true
},
{
path: 'scoringSettlement',
component: ScoringSettlement,
hidden: true
}
]
}

View File

@ -0,0 +1,13 @@
<template>
<div>打分结算</div>
</template>
<script>
export default {
name: 'ScoringSettlement'
};
</script>
<style scoped>
</style>

View File

@ -146,7 +146,7 @@ export default {
this.$router.push('/contest/list');
},
submit() {
this.$router.push('/contest/list');
this.$router.push('/contest/scoringSettlement');
}
}
};

View File

@ -1,11 +1,11 @@
<template>
<div class="trainingPlatform" :style="'padding-left:'+(widthLeft)+'px'">
<div class="trainingPubMapList" :style="{width: widthLeft+'px'}">
<div class="contestPlatform" :style="'padding-left:'+(widthLeft)+'px'">
<div class="contestPaperList" :style="{width: widthLeft+'px'}">
<paper-list ref="paperList" @changeModuleData="changeModuleData" />
<drap-left :width-left="widthLeft" @drapWidth="drapWidth" />
</div>
<div>
<div style="height: 50px;text-align: center;line-height: 50px;font-size: 26px;font-weight: bolder;">{{ paperName }}</div>
<div class="module-box">
<div style="height: 50px;text-align: center;line-height: 50px;font-size: 26px;font-weight: bolder;color: #fff;">{{ paperName }}</div>
<el-tabs v-model="activeModuleName" class="tabs-box" type="border-card" @tab-click="handleTabClick">
<template v-for="(mod, modIndex) in moduleList">
<el-tab-pane :key="modIndex" :label="mod.moduleName" :name="mod.customModuleId+''">
@ -37,7 +37,9 @@
<el-table-column label="评分标准" prop="criteria" />
</el-table>
</el-card>
<el-button type="primary" size="medium" style="margin-top: 10px;" @click="beginExercise(mod.customModuleId)">开始训练</el-button>
<div style="display: flex; justify-content: center;margin-top: 10px;">
<el-button type="primary" size="medium" @click="beginExercise(mod.customModuleId)">开始训练</el-button>
</div>
</el-tab-pane>
</template>
</el-tabs>
@ -53,7 +55,7 @@ import { getPaperDetail, getContextScoreDetail} from '@/api/contest';
let id = 1;
export default {
name: 'TrainingPlatform',
name: 'ContestList',
components: {
paperList,
drapLeft
@ -157,32 +159,60 @@ export default {
};
</script>
<style lang="scss" scoped>
.trainingPlatform {
.contestPlatform {
position: relative;
height: 100%;
width: 100%;
overflow: hidden;
.contestPaperList {
position:absolute;
left:0;
top:0;
height: 100%;
background: #00172E;
}
.module-box{
height: 100%;
width: 100%;
padding-bottom: 20px;
background: #00172E;
.tabs-box{
height: calc(100% - 30px);
margin: 0 10px;
overflow-y: auto;
background: transparent;
&::-webkit-scrollbar{
background: #06284a;
}
&::-webkit-scrollbar-thumb{
background: #0c0909;
}
&::-webkit-scrollbar-track{
background: #06284a;
}
}
}
.trainingPubMapList {
position:absolute;
left:0;
top:0;
height: 100%;
}
/deep/{
.el-tabs__nav-scroll{
background: #00172E;
}
.tabs-box{
height: calc(100% - 30px);
margin: 0 10px;
overflow-y: auto;
background: transparent;
&::-webkit-scrollbar{
background: #06284a;
}
&::-webkit-scrollbar-thumb{
background: #0c0909;
.el-tabs--border-card>.el-tabs__header .el-tabs__item{
color: #fff;
border: solid 1px #01468B;
}
&::-webkit-scrollbar-track{
background: #06284a;
.el-tabs--border-card>.el-tabs__header .el-tabs__item.is-active{
background: #01468B;
}
.el-tabs--border-card{
border: solid 1px #01468B;
}
.el-table th.el-table__cell{
background-color: #01468B;
color: #fff;
}
.el-table--border, .el-table--group{
border-width: 0;
}
}
</style>

View File

@ -3,8 +3,8 @@
<div id="trainingMapTree" class="left-paper-list">
<div class="paperListName">
<el-form :inline="true" :model="formModel" class="demo-form-inline">
<el-form-item label="组别" :label-style="{ color: 'red' }">
<el-select v-model="formModel.group" placeholder="请选择" clearable>
<el-form-item label="组别">
<el-select v-model="formModel.group" placeholder="请选择" clearable style="width: 120px;" @change="queryPaper">
<el-option
v-for="item in groupOption"
:key="item.value"
@ -14,7 +14,7 @@
</el-select>
</el-form-item>
<el-form-item label="赛季">
<el-select v-model="formModel.seasonId" placeholder="请选择" clearable>
<el-select v-model="formModel.seasonId" placeholder="请选择" clearable style="width: 120px;" @change="filterPaper">
<el-option
v-for="item in seasonOptions"
:key="item.id"
@ -22,9 +22,6 @@
:value="item.id"
/>
</el-select>
<el-form-item>
<el-button type="primary" size="medium" @click="queryPaper">查询</el-button>
</el-form-item>
</el-form-item>
</el-form>
</div>
@ -35,7 +32,7 @@
active-text-color="#ffd04b"
>
<template v-for="(paper,paperIndex) in paperList">
<el-menu-item :key="paperIndex" :index="paper.id+''" @click="showPaperDetail(paper)">
<el-menu-item v-show="!formModel.seasonId||paper.seasonId==formModel.seasonId" :key="paperIndex" :index="paper.id+''" @click="showPaperDetail(paper)">
{{ paper.name }}
</el-menu-item>
</template>
@ -46,7 +43,7 @@
<script>
import { queryContestSeasonPaged, getPaperList} from '@/api/contest';
export default {
name: 'DemonList',
name: 'PaperList',
components: {
},
data() {
@ -70,21 +67,34 @@ export default {
},
mounted() {
this.loading = false;
queryContestSeasonPaged({pageSize:999}).then((res) => {
this.seasonOptions = res.data.list;
});
getPaperList({ group:'GZ', pageSize:999}).then((res) => {
this.paperList = res.data.list;
this.defaultIndex = this.paperList[0].id + '';
this.$emit('changeModuleData', this.paperList[0]);
});
this.querySeason();
},
methods: {
queryPaper() {
const data = Object.assign({pageSize:999}, this.formModel);
getPaperList(data).then((res) => {
getPaperList({ group:this.formModel.group, pageSize:999}).then((res) => {
this.paperList = res.data.list;
});
this.querySeason();
},
querySeason() {
queryContestSeasonPaged({pageSize:999, group:this.formModel.group }).then((res) => {
this.seasonOptions = res.data.list;
});
},
filterPaper() {
if (this.formModel.seasonId) {
const paper = this.paperList.find(paper=>paper.seasonId == this.formModel.seasonId);
this.defaultIndex = paper.id + '';
this.$emit('changeModuleData', paper);
} else {
this.defaultIndex = this.paperList[0].id + '';
this.$emit('changeModuleData', this.paperList[0]);
}
},
showPaperDetail(paper) {

View File

@ -7,16 +7,6 @@
<el-form-item label="试卷描述:" prop="desc">
<el-input v-model="formModel.desc" type="textarea" style="width:350px;" />
</el-form-item>
<el-form-item label="组别:" prop="group">
<el-select v-model="formModel.group" placeholder="请选择" style="width:350px;">
<el-option
v-for="item in groupOption"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item label="所属赛季:" prop="seasonId">
<el-select v-model="formModel.seasonId" placeholder="请选择" style="width:350px;">
<el-option
@ -45,17 +35,9 @@ export default {
id: '',
name: '', //
desc: '', //
seasonId: '', // id
group:'' //
seasonId: '' // id
},
seasonOptions:[],
groupOption:[{
value: 'ZZ',
label: '中职'
}, {
value: 'GZ',
label: '高职'
}],
loading: false
};
},
@ -68,9 +50,6 @@ export default {
desc: [
{ required: true, message: '请输入试卷描述', trigger: 'blur' }
],
group: [
{ required: true, message: '请选择试卷所属赛季', trigger: 'blur' }
],
seasonId: [
{ required: true, message: '请选择试卷所属赛季', trigger: 'blur' }
]
@ -92,13 +71,11 @@ export default {
this.formModel.name = row.name;
this.formModel.desc = row.desc;
this.formModel.seasonId = row.seasonId;
this.formModel.group = row.group;
} else {
this.formModel = {
id: '',
name: '',
desc: '',
group:'',
seasonId: ''
};
}