fix:标题判断错误问题

This commit is contained in:
暮光:城中城
2022-07-05 23:28:24 +08:00
parent 4a142cee31
commit 77ac039168

View File

@@ -154,10 +154,6 @@
});
},
createWikiSave(saveAfter) {
if (!this.wikiPageEdit.pageTitle) {
this.$message.warning("标题不能为空");
return;
}
let content = '', preview = '';
if (this.wikiPageEdit.editorType === 2) {
content = this.markdownContent;
@@ -168,6 +164,10 @@
preview = pageData.text;
this.wikiPageEdit.pageTitle = pageData.title;
}
if (!this.wikiPageEdit.pageTitle) {
this.$message.warning("标题不能为空");
return;
}
// 修改内容时强制不能修改父路径,只能在目录上拖动修改
let parentId = (this.pageId > 0) ? '' : this.parentId;
let param = {