zx 3 years ago
parent f092035eb9
commit 55e26d4000

@ -111,6 +111,7 @@ export default defineComponent({
const setForm = reactive({
title: '',
fileUrl: '',
duration: undefined,
})
const visible = ref(false);
const editVisible = ref(false);
@ -158,6 +159,7 @@ export default defineComponent({
const data = res.data;
this.setForm.title = data.title;
this.setForm.fileUrl = data.fileUrl;
this.setForm.duration = data.duration;
}).catch(() => {});
this.editVisible = true;
},
@ -168,6 +170,7 @@ export default defineComponent({
this.editVisible = false;
this.setForm.title = '';
this.setForm.fileUrl = '';
this.setForm.duration = undefined;
this.$message.success(res.data)
}).catch(() => {});
},
@ -178,6 +181,7 @@ export default defineComponent({
this.visible = false;
this.setForm.title = '';
this.setForm.fileUrl = '';
this.setForm.duration = undefined;
this.$message.success(res.data)
}).catch(() => {});
},
@ -196,10 +200,12 @@ export default defineComponent({
},
//
handlerUpload(data) {
this.setForm.fileUrl = data.fileUrl
this.setForm.fileUrl = data.fileUrl;
this.setForm.duration = data.duration;
},
handlerCoverUpload(data) {
this.setForm.fileUrl = data.fileUrl
this.setForm.fileUrl = data.fileUrl;
this.setForm.duration = data.duration;
},
//
editCancel() {

@ -77,7 +77,8 @@ export default defineComponent({
subtitle: '',
type: 1,
content: '',
cover:''
cover:'',
duration: undefined,
});
const { proxy } = getCurrentInstance();
/////////////
@ -124,7 +125,8 @@ export default defineComponent({
this.form.type = res.data.type;
this.form.subtitle = res.data.subtitle;
this.form.content = res.data.content;
this.form.cover = res.data.cover
this.form.cover = res.data.cover;
this.form.duration = res.data.duration;
}).catch(() => {});
}
},
@ -158,6 +160,7 @@ export default defineComponent({
},
handlerUploadVideo(data) {
this.form.content = data.fileUrl;
this.form.duration = data.duration;
}
}
})

@ -70,6 +70,7 @@ export default defineComponent({
subtitle: '',
type: 1,
content: '<p>请在此输入内容</p>',
duration: undefined,
cover:''
});
const { proxy } = getCurrentInstance();
@ -150,7 +151,8 @@ export default defineComponent({
this.form.content = data.fileUrl
},
handlerUploadVideo(data) {
this.form.content = data.fileUrl
this.form.content = data.fileUrl;
this.form.duration = data.duration;
}
}
})

@ -150,6 +150,18 @@ export default defineComponent({
this.isEditing = true;
this.addVisible = true;
this.activeId = value;
this.proxy.$post("/admin/detail", {id: value}).then(res => {
if(res.code == 200) {
const data = res.data
this.addForm.name = data.name;
this.addForm.realName = data.realName;
this.addForm.roleIds = data.roleIds * 1;
this.addForm.tel = data.tel;
this.addForm.password = data.password;
} else {
this.$message.error(res.msg)
}
}).catch(() => {});
},
addConfirm() {
this.addForm.roleIds = this.addForm.roleIds.toString();

Loading…
Cancel
Save