大赛训练产品调整暂提
This commit is contained in:
parent
126507f87f
commit
8b92ce23e4
@ -325,7 +325,7 @@ export function publishContextSence(data) {
|
||||
*/
|
||||
export function getTaskTree(paperId, moduleId) {
|
||||
return request({
|
||||
url: `/api/exercise/race/paper/page/${paperId}/module/${moduleId}/task`,
|
||||
url: `/api/exercise/race/paper/${paperId}/module/${moduleId}/task`,
|
||||
method: 'get'
|
||||
});
|
||||
}
|
||||
|
@ -3,7 +3,7 @@
|
||||
<el-col :span="5" class="container-left">
|
||||
<el-tree
|
||||
:data="taskData"
|
||||
node-key="name"
|
||||
node-key="index"
|
||||
current-node-key
|
||||
:props="defaultProps"
|
||||
default-expand-all
|
||||
@ -12,7 +12,7 @@
|
||||
:expand-on-click-node="false"
|
||||
>
|
||||
<div slot-scope="{ node, data }" class="custom-tree-node">
|
||||
<div :style="{ color: nowData.name === data.name? '#8f079d': '#fff' }">{{ data.groupName||data.name }}</div>
|
||||
<div :style="{ color: nowData.name === data.name? '#8f079d': '#fff' }">{{ data.name }}</div>
|
||||
</div>
|
||||
</el-tree>
|
||||
<div class="button-group">
|
||||
@ -23,7 +23,7 @@
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="19" class="container-right">
|
||||
<el-card class="box-card" style="color: #fff;background-color: transparent;height: 100%">
|
||||
<el-card class="box-card">
|
||||
<div slot="header" style="text-align: center">
|
||||
<span style="font-size: 28px;">{{ nowData.name }}</span>
|
||||
</div>
|
||||
@ -90,109 +90,31 @@ export default {
|
||||
hasDeviceManage: false,
|
||||
hasMemberManage: true
|
||||
}
|
||||
},
|
||||
resp: {
|
||||
customModuleId: 2,
|
||||
child: [
|
||||
{
|
||||
id: 0,
|
||||
name: '车站行车作业',
|
||||
desc: '',
|
||||
content: '',
|
||||
standards: '',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 0,
|
||||
children: [
|
||||
{
|
||||
id: 45,
|
||||
name: '正常行车组织工作',
|
||||
desc: '利用智慧城轨运营模拟训练平台ATS系统,加载既定的列车运行图,选取某时刻(9:00)开始模拟列车运行。',
|
||||
content: '1,组织管辖车站范围内图定列车按计划运行\n2,控制权交接',
|
||||
standards: '。。',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 0,
|
||||
children: [
|
||||
{
|
||||
id: 46,
|
||||
name: '组织管辖车站范围内图定列车按计划运行',
|
||||
desc: '核对运行计划。',
|
||||
content: '行调与车站值班员确认本站站台及相邻区间列车状态。',
|
||||
standards: '车站值班员手指口呼确认本站站台及相邻区间列车占用状态并与行调核对车次及位置正确、用语标准。',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 45,
|
||||
isTask: true
|
||||
},
|
||||
{
|
||||
id: 47,
|
||||
name: '控制权交接',
|
||||
desc: '控制权交接操作。',
|
||||
content: '行调与车站值班员确认ATS站中控状态并进行控制权转换操作。',
|
||||
standards: '车站值班员手指口呼确认本站ATS站中控状态并进行控制权转换操作,正常完成控制权转换。按标准用语汇报。',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 45,
|
||||
isTask: true
|
||||
}
|
||||
],
|
||||
isTask: true
|
||||
},
|
||||
{
|
||||
id: 35,
|
||||
name: '运营工作准备',
|
||||
desc: '利用智慧城轨运营模拟训练平台ATS系统,加载既定的列车运行图,选取运营开始前30分钟,开始运营前检查工作。',
|
||||
content: '1,人员准备\n2,检查ATS设备\n3,检查IBP\n4,站台门检查',
|
||||
standards: '。。',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 0,
|
||||
children: [
|
||||
{
|
||||
id: 41,
|
||||
name: '人员准备',
|
||||
desc: '检查人员工作状态',
|
||||
content: '检查运营前人员形象礼仪及精神状态。',
|
||||
standards: '运营前人员形象礼仪及精神状态符合企业服务标准要求。',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 35,
|
||||
isTask: true
|
||||
},
|
||||
{
|
||||
id: 42,
|
||||
name: '检查本地ATS设备',
|
||||
desc: '检查车站ATS状态。',
|
||||
content: '检查车站ATS工作站中的所有道岔、信号机、计轴区段状态。',
|
||||
standards: '手指口呼确认道岔、信号机、计轴状态等设备状态是否全部正常。',
|
||||
sceneId: 0,
|
||||
ruleId: 0,
|
||||
parentId: 35,
|
||||
isTask: true
|
||||
}
|
||||
],
|
||||
isTask: true
|
||||
}
|
||||
],
|
||||
isTask: false
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
// this.taskData = JSON.parse(this.resp);
|
||||
this.taskData = this.resp.child;
|
||||
this.taskList = [];
|
||||
this.eachTask(this.taskList, this.taskData);
|
||||
this.nowKey = 0;
|
||||
this.nowData = this.taskList[this.nowKey];
|
||||
getTaskTree(this.$route.query.paperId, this.$route.query.moduleId).then(resp => {
|
||||
|
||||
const data = resp.data.child;
|
||||
this.handleData(data, 1);
|
||||
this.taskData = data;
|
||||
this.taskList = [];
|
||||
this.eachTask(this.taskList, this.taskData);
|
||||
this.nowKey = 0;
|
||||
this.nowData = this.taskList[this.nowKey];
|
||||
// console.log(this.taskData, this.taskList, this.nowData, '===', data);
|
||||
}).catch(() => this.$message.error('加载数据失败!'));
|
||||
},
|
||||
methods: {
|
||||
handleData(data, index) {
|
||||
data.forEach((elem, i) => {
|
||||
elem.index = index + '_' + i;
|
||||
if (elem.children) {
|
||||
this.handleData(elem.children, index + 1);
|
||||
}
|
||||
});
|
||||
},
|
||||
handleChange(data, node) {
|
||||
node.isCurrent = false;
|
||||
this.$set(node, 'isCurrent', false);
|
||||
@ -200,7 +122,7 @@ export default {
|
||||
},
|
||||
eachTask(list, data) {
|
||||
data.forEach(ele => {
|
||||
if (ele.isTask) {
|
||||
if (ele.nodeType === 'TASK') {
|
||||
list.push(ele);
|
||||
}
|
||||
if (ele.children) {
|
||||
@ -231,6 +153,12 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.box-card {
|
||||
color: #fff;
|
||||
background-color: transparent;
|
||||
height: 100%;
|
||||
border: 1px solid #01468B;
|
||||
}
|
||||
.container {
|
||||
background: linear-gradient(to bottom, #01468B, #00172E);
|
||||
height: 100%;
|
||||
@ -241,7 +169,7 @@ export default {
|
||||
}
|
||||
.container-right{
|
||||
background: #00172E;
|
||||
border: solid 1px #01468B;
|
||||
border: 1px solid #01468B;
|
||||
height: 100%;
|
||||
padding: 10px;
|
||||
}
|
||||
@ -252,12 +180,15 @@ export default {
|
||||
width: 20.9%;
|
||||
text-align: right;
|
||||
padding: 10px;
|
||||
border-top: 2px solid #01468B;
|
||||
border-top: 1px solid #01468B;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
}
|
||||
/deep/.el-tree-node__content{
|
||||
background-color: transparent !important;
|
||||
}
|
||||
/deep/.el-card__header{
|
||||
border-bottom: 1px solid #01468B;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
@ -1,10 +1,14 @@
|
||||
<template>
|
||||
<el-dialog v-dialogDrag v-loading="loading" title="评分表" :visible.sync="dialogVisible" width="800px" :before-close="handleClose" center :close-on-click-modal="false">
|
||||
<el-table
|
||||
ref="table"
|
||||
:data="tableData"
|
||||
border
|
||||
show-summary
|
||||
default-expand-all
|
||||
row-key="name"
|
||||
:summary-method="getSummaries"
|
||||
:tree-props="{children: 'children'}"
|
||||
style="width: 100%;margin-top: 10px;"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
|
@ -95,7 +95,7 @@ export default {
|
||||
deleteContextScore(row.id).then(resp => {
|
||||
this.reloadTable();
|
||||
}).catch(error => {
|
||||
this.$message.error(`删除删除竞赛评分规则失败: ${error.message}`);
|
||||
this.$message.error(`删除竞赛评分规则失败: ${error.message}`);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
@ -1,11 +1,11 @@
|
||||
<template>
|
||||
<el-dialog v-dialogDrag :title="title" :visible.sync="dialogVisible" width="500px" :before-close="handleClose" center :close-on-click-modal="false">
|
||||
<el-form ref="ruleForm" :model="formModel" :rules="rules" label-width="130px">
|
||||
<el-form-item label="单元描述:" prop="text">
|
||||
<el-input v-model="formModel.text" style="width: 200px;" />
|
||||
<el-form-item label="单元描述:" prop="name">
|
||||
<el-input v-model="formModel.name" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="作业程序:" prop="worker">
|
||||
<el-input v-model="formModel.worker" style="width: 200px;" />
|
||||
<el-form-item label="作业程序:" prop="content">
|
||||
<el-input v-model="formModel.content" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="场景步骤ID:" prop="sceneStepId">-->
|
||||
<!-- <el-input v-model="formModel.sceneStepId" style="width: 200px;" />-->
|
||||
@ -30,8 +30,8 @@ export default {
|
||||
return {
|
||||
dialogVisible: false,
|
||||
formModel: {
|
||||
text: '',
|
||||
worker: '',
|
||||
name: '',
|
||||
content: '',
|
||||
score: 0,
|
||||
criteria: '',
|
||||
sceneStepId: '',
|
||||
@ -45,10 +45,10 @@ export default {
|
||||
computed: {
|
||||
rules() {
|
||||
const crules = {
|
||||
text: [
|
||||
name: [
|
||||
{ required: true, message: '请输入单元描述', trigger: 'blur' }
|
||||
],
|
||||
worker: [
|
||||
content: [
|
||||
{ required: true, message: '请输入作业程序', trigger: 'blur' }
|
||||
],
|
||||
criteria: [
|
||||
@ -67,8 +67,8 @@ export default {
|
||||
this.type = type;
|
||||
this.index = index;
|
||||
if (row) {
|
||||
this.formModel.text = row.text;
|
||||
this.formModel.worker = row.worker;
|
||||
this.formModel.name = row.name;
|
||||
this.formModel.content = row.content;
|
||||
this.formModel.score = row.score;
|
||||
this.formModel.criteria = row.criteria;
|
||||
this.formModel.sceneStepId = row.sceneStepId;
|
||||
@ -78,8 +78,8 @@ export default {
|
||||
handleClose() {
|
||||
this.type = 'edit';
|
||||
this.formModel = {
|
||||
text: '',
|
||||
worker: '',
|
||||
name: '',
|
||||
content: '',
|
||||
score: 0,
|
||||
criteria: '',
|
||||
sceneStepId: '',
|
||||
|
@ -16,14 +16,15 @@
|
||||
:data="tableData"
|
||||
border
|
||||
show-summary
|
||||
row-key="text"
|
||||
default-expand-all
|
||||
row-key="name"
|
||||
:summary-method="getSummaries"
|
||||
:tree-props="{children: 'children'}"
|
||||
style="width: 100%;margin-top: 10px;"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="描述" prop="text" />
|
||||
<el-table-column label="作业程序" prop="worker" />
|
||||
<el-table-column label="描述" prop="name" />
|
||||
<el-table-column label="作业程序" prop="content" />
|
||||
<el-table-column label="分值" prop="score" width="50" />
|
||||
<el-table-column label="评分标准" prop="criteria" />
|
||||
<!-- <el-table-column label="场景步骤ID" prop="sceneStepId" width="100">-->
|
||||
@ -82,23 +83,6 @@ export default {
|
||||
getContextScoreDetail(this.$route.query.id).then(resp => {
|
||||
this.tableData = resp.data.rule ? resp.data.rule.units : [];
|
||||
}).catch(() => { this.$message.error('初始化数据失败!'); });
|
||||
this.tableData = [{
|
||||
text: 'w',
|
||||
worker: 'w',
|
||||
score: 1,
|
||||
criteria: 'w',
|
||||
sceneStepId: 'w',
|
||||
children: [
|
||||
{
|
||||
text: 'q',
|
||||
worker: 'q',
|
||||
score: 2,
|
||||
criteria: 'q',
|
||||
sceneStepId: 'q',
|
||||
children: []
|
||||
}
|
||||
]
|
||||
}];
|
||||
},
|
||||
goBack() {
|
||||
this.$router.go(-1);
|
||||
|
Loading…
Reference in New Issue
Block a user