|
|
@ -302,7 +302,6 @@ export default { |
|
|
|
projectManage: {} |
|
|
|
projectManage: {} |
|
|
|
}, // 复制之后,提交到后台的数据 |
|
|
|
}, // 复制之后,提交到后台的数据 |
|
|
|
listDataAll: [], |
|
|
|
listDataAll: [], |
|
|
|
isFirst: true |
|
|
|
|
|
|
|
}; |
|
|
|
}; |
|
|
|
}, |
|
|
|
}, |
|
|
|
computed: { |
|
|
|
computed: { |
|
|
@ -330,7 +329,6 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
this.getSystemData() |
|
|
|
this.getSystemData() |
|
|
|
this.getData() |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
|
...mapActions("project", [ |
|
|
|
...mapActions("project", [ |
|
|
@ -338,14 +336,12 @@ export default { |
|
|
|
]), |
|
|
|
]), |
|
|
|
getData () { |
|
|
|
getData () { |
|
|
|
this.setSystemId(this.form.systemId); |
|
|
|
this.setSystemId(this.form.systemId); |
|
|
|
if (this.isFirst) this.page = +this.$route.query.page || 1 |
|
|
|
|
|
|
|
let data = { |
|
|
|
let data = { |
|
|
|
...this.form, |
|
|
|
...this.form, |
|
|
|
pageNum: this.page, |
|
|
|
pageNum: this.page, |
|
|
|
pageSize: this.pageSize, |
|
|
|
pageSize: this.pageSize, |
|
|
|
}; |
|
|
|
}; |
|
|
|
this.$post(this.api.queryProjectManage, data).then(res => { |
|
|
|
this.$post(this.api.queryProjectManage, data).then(res => { |
|
|
|
this.isFirst = false |
|
|
|
|
|
|
|
this.listData = res.data.records; |
|
|
|
this.listData = res.data.records; |
|
|
|
this.total = res.data.total; |
|
|
|
this.total = res.data.total; |
|
|
|
}).catch(err => { |
|
|
|
}).catch(err => { |
|
|
@ -372,7 +368,7 @@ export default { |
|
|
|
e.children = all.filter(n => e.systemId.split(',').includes(n.id + '')) // 筛选出该课程下的系统 |
|
|
|
e.children = all.filter(n => e.systemId.split(',').includes(n.id + '')) // 筛选出该课程下的系统 |
|
|
|
}) |
|
|
|
}) |
|
|
|
this.curs = data |
|
|
|
this.curs = data |
|
|
|
this.curChange(this.cid) |
|
|
|
this.curChange(this.cid, 1) |
|
|
|
} |
|
|
|
} |
|
|
|
}).catch(err => { }) |
|
|
|
}).catch(err => { }) |
|
|
|
}, |
|
|
|
}, |
|
|
@ -459,12 +455,10 @@ export default { |
|
|
|
this.$get(`${this.api.updateIsOpen}?isOpen=${row.ccupationlabOpen}&projectId=${row.projectId}&platformId=${this.form.platformId}`).then(res => { |
|
|
|
this.$get(`${this.api.updateIsOpen}?isOpen=${row.ccupationlabOpen}&projectId=${row.projectId}&platformId=${this.form.platformId}`).then(res => { |
|
|
|
util.successMsg("更新启用状态成功"); |
|
|
|
util.successMsg("更新启用状态成功"); |
|
|
|
this.getData(); |
|
|
|
this.getData(); |
|
|
|
}).catch(err => { |
|
|
|
}).catch(err => { }); |
|
|
|
console.log(err); |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
// 课程选择回调 |
|
|
|
// 课程选择回调 |
|
|
|
curChange (val) { |
|
|
|
curChange (val, first) { |
|
|
|
const mallId = val[0] |
|
|
|
const mallId = val[0] |
|
|
|
if (val.length === 1) { |
|
|
|
if (val.length === 1) { |
|
|
|
// 如果选择的是课程,则默认选中下面第一个系统 |
|
|
|
// 如果选择的是课程,则默认选中下面第一个系统 |
|
|
@ -473,7 +467,7 @@ export default { |
|
|
|
this.form.mallId = mallId |
|
|
|
this.form.mallId = mallId |
|
|
|
this.form.cid = this.curs.find(e => e.id === mallId).cid |
|
|
|
this.form.cid = this.curs.find(e => e.id === mallId).cid |
|
|
|
this.form.systemId = this.cid[1] |
|
|
|
this.form.systemId = this.cid[1] |
|
|
|
this.initData() |
|
|
|
first ? this.getData() : this.initData() |
|
|
|
}, |
|
|
|
}, |
|
|
|
copyData (projectId) { // 复制,根据项目id查询详情 |
|
|
|
copyData (projectId) { // 复制,根据项目id查询详情 |
|
|
|
this.copyVisible = true; |
|
|
|
this.copyVisible = true; |
|
|
@ -530,6 +524,11 @@ export default { |
|
|
|
i.projectId = '' |
|
|
|
i.projectId = '' |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.$post(`${this.api.copyProjectManage}`, row).then(res => { |
|
|
|
this.$post(`${this.api.copyProjectManage}`, row).then(res => { |
|
|
|
|
|
|
|
this.form.projectName = '' |
|
|
|
|
|
|
|
this.form.state = '' |
|
|
|
|
|
|
|
this.form.permissions = '' |
|
|
|
|
|
|
|
this.form.founder = 2 |
|
|
|
|
|
|
|
|
|
|
|
this.initData(); |
|
|
|
this.initData(); |
|
|
|
util.successMsg("复制实验项目成功"); |
|
|
|
util.successMsg("复制实验项目成功"); |
|
|
|
this.copyVisible = false; |
|
|
|
this.copyVisible = false; |
|
|
|