|
|
@ -225,7 +225,7 @@ |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<el-table ref="table" :data="permissionData" class="table" stripe header-align="center" |
|
|
|
<el-table ref="table" :data="permissionData" class="table" stripe header-align="center" |
|
|
|
@selection-change="handleSelectionChange"> |
|
|
|
@selection-change="handleSelectionChange"> |
|
|
|
<el-table-column type="selection" width="55" align="center"></el-table-column> |
|
|
|
<el-table-column type="selection" :selectable="practiceSelectable" width="55" align="center"></el-table-column> |
|
|
|
<el-table-column type="index" width="100" label="序号" align="center"></el-table-column> |
|
|
|
<el-table-column type="index" width="100" label="序号" align="center"></el-table-column> |
|
|
|
<el-table-column prop="systemName" label="系统名称" align="center"></el-table-column> |
|
|
|
<el-table-column prop="systemName" label="系统名称" align="center"></el-table-column> |
|
|
|
<el-table-column prop="type" label="系统类型" align="center"> |
|
|
|
<el-table-column prop="type" label="系统类型" align="center"> |
|
|
@ -455,6 +455,25 @@ export default { |
|
|
|
}).catch(err => { |
|
|
|
}).catch(err => { |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
practiceSelectable(row, index) { // 禁止勾选已经选过的系统 |
|
|
|
|
|
|
|
// console.log(row,index); |
|
|
|
|
|
|
|
let boolean = true; |
|
|
|
|
|
|
|
if (this.permissions) { |
|
|
|
|
|
|
|
this.assessmentData.length && this.assessmentData.some(e => { |
|
|
|
|
|
|
|
if (e.systemId == row.systemId) { |
|
|
|
|
|
|
|
boolean = false; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
this.practiceData.length && this.practiceData.some(e => { |
|
|
|
|
|
|
|
// console.log(e.systemId, row.systemId); |
|
|
|
|
|
|
|
if (e.systemId == row.systemId) { |
|
|
|
|
|
|
|
boolean = false; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
return boolean; |
|
|
|
|
|
|
|
}, |
|
|
|
initData() { |
|
|
|
initData() { |
|
|
|
this.$refs.table.clearSelection(); |
|
|
|
this.$refs.table.clearSelection(); |
|
|
|
this.pageNo = 1; |
|
|
|
this.pageNo = 1; |
|
|
@ -471,16 +490,14 @@ export default { |
|
|
|
if (!this.multipleSelection.length) { |
|
|
|
if (!this.multipleSelection.length) { |
|
|
|
this.$message.warning("请选择系统!"); |
|
|
|
this.$message.warning("请选择系统!"); |
|
|
|
return; |
|
|
|
return; |
|
|
|
} else if (this.multipleSelection.length > 1) { |
|
|
|
|
|
|
|
this.$message.warning("只能选择一个系统!"); |
|
|
|
|
|
|
|
return; |
|
|
|
|
|
|
|
} else { |
|
|
|
} else { |
|
|
|
this.getConfigData(); |
|
|
|
this.getConfigData(); |
|
|
|
this.configVisible = false; |
|
|
|
this.configVisible = false; |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
getConfigData() { // 查询实训配置 |
|
|
|
getConfigData() { // 查询实训配置 |
|
|
|
this.$get(`${this.api.getInternalProjectBySystemId}?permissions=${this.permissions}&systemId=${this.multipleSelection[0].systemId}`).then((res) => { |
|
|
|
let ids = this.multipleSelection.map(i => i.systemId); |
|
|
|
|
|
|
|
this.$get(`${this.api.getInternalProjectBySystemId}?permissions=${this.permissions}&systemId=${ids.toString()}`).then((res) => { |
|
|
|
let data = res.map((item, index) => { |
|
|
|
let data = res.map((item, index) => { |
|
|
|
item.isShow = 0; // isShow是否展示(默认0:展示 1:不展示) |
|
|
|
item.isShow = 0; // isShow是否展示(默认0:展示 1:不展示) |
|
|
|
item.sort = index + 1; |
|
|
|
item.sort = index + 1; |
|
|
|