+
@@ -222,7 +222,8 @@
-
+
@@ -267,37 +268,39 @@
已选择项目({{ checkeds.length }}个)
-
-
-
-
-
-
- {{ scope.row.type === 1 ? '流程类' : scope.row.type === 3 ? '理论' : '编程类' }}
-
-
-
-
-
- {{ scope.row.projectName || scope.row.paperName }}
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+ {{ scope.row.type === 1 ? '流程类' : scope.row.type === 3 ? '理论' : '编程类' }}
+
+
+
+
+
+ {{ scope.row.projectName || scope.row.paperName }}
+
+
+
+
+
+
+
+
+
-
@@ -382,7 +385,6 @@ export default {
multiplePractice: [],
submiting: false, // 新增编辑防抖标识
- loadIns: null,
updateTime: 0,
systems: [],
systemsAll: [],
@@ -442,6 +444,7 @@ export default {
methods: {
getInfoData () {
this.$post(`${this.api.curriculumDetail}?cid=${this.cid}`).then(({ data }) => {
+ if (!data.coverUrl) data.coverUrl = 'https://izhixinyun.com/images/course-cover.png'
if (data.supplier) data.supplier = data.supplier.split(',').map(e => +e)
this.form = data
this.$nextTick(() => {
@@ -807,17 +810,17 @@ export default {
this.step--
},
async save (next) {
+ if (this.submiting) return false
const { step, cid } = this
// 第一步
if (step === 1) {
this.$refs.form.validate(async (valid) => {
if (valid) {
- if (this.submiting) return false
const form = JSON.parse(JSON.stringify(this.form))
form.supplier = form.supplier.join()
form.platformId = Setting.platformId
this.submiting = true
- this.loadIns = this.$loading({
+ const load = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
@@ -825,7 +828,6 @@ export default {
})
try {
const res = await this.$post(this.api[cid ? 'modifyCourse' : 'createCurriculum'], form)
- this.loadIns.close()
if (next) {
this.step = 2
if (!cid) {
@@ -837,7 +839,7 @@ export default {
}
} finally {
this.submiting = false
- this.loadIns.close()
+ load.close()
}
}
})
@@ -846,6 +848,13 @@ export default {
if (!this.practiceData.length) {
return this.$message.warning("请添加练习项目配置")
} else {
+ this.submiting = true
+ const load = this.$loading({
+ lock: true,
+ text: 'Loading',
+ spinner: 'el-icon-loading',
+ background: 'rgba(0, 0, 0, 0.7)'
+ })
const list = this.practiceData.map(i => {
let obj = {
isShow: i.isShow,
@@ -857,14 +866,19 @@ export default {
return obj
});
list.sort((a, b) => a.sort - b.sort)
- await this.$post(this.api.configureCourseProject, {
- cid: this.cid,
- systemIdByPractice: list
- })
- if (next) {
- this.step = 3
- } else {
- this.back()
+ try {
+ await this.$post(this.api.configureCourseProject, {
+ cid: this.cid,
+ systemIdByPractice: list
+ })
+ if (next) {
+ this.step = 3
+ } else {
+ this.back()
+ }
+ } finally {
+ this.submiting = false
+ load.close()
}
}
} else if (step === 3) {
@@ -872,6 +886,13 @@ export default {
if (!this.assessmentData.length) {
return this.$message.warning("请添加考核项目配置")
} else {
+ this.submiting = true
+ const load = this.$loading({
+ lock: true,
+ text: 'Loading',
+ spinner: 'el-icon-loading',
+ background: 'rgba(0, 0, 0, 0.7)'
+ })
const list = this.assessmentData.map(i => {
let obj = {
isShow: i.isShow,
@@ -883,11 +904,16 @@ export default {
return obj;
});
list.sort((a, b) => a.sort - b.sort)
- await this.$post(this.api.configureCourseProject, {
- cid: this.cid,
- systemIdByAssessment: list
- })
- this.step = 4
+ try {
+ await this.$post(this.api.configureCourseProject, {
+ cid: this.cid,
+ systemIdByAssessment: list
+ })
+ this.step = 4
+ } finally {
+ this.submiting = false
+ load.close()
+ }
}
}
},
@@ -1068,8 +1094,16 @@ export default {
}
/deep/.config-dia {
+ .el-drawer__header {
+ padding-bottom: 20px;
+ margin-bottom: 0;
+ border-bottom: 1px solid #eee;
+ }
+
.config-wrap {
display: flex;
+ padding: 15px;
+ gap: 20px;
}
.title-wrap {
@@ -1078,9 +1112,8 @@ export default {
.item {
width: 250px;
- max-height: 600px;
+ height: calc(100vh - 161px);
padding: 10px;
- margin-right: 20px;
overflow: hidden;
}
@@ -1089,8 +1122,8 @@ export default {
}
.systems {
+ max-height: calc(100vh - 230px);
margin-top: 10px;
- max-height: 520px;
overflow: auto;
li {
diff --git a/src/views/match/add/set.vue b/src/views/match/add/set.vue
index e4b678f..449c0f9 100644
--- a/src/views/match/add/set.vue
+++ b/src/views/match/add/set.vue
@@ -25,21 +25,25 @@
-
-