diff --git a/src/views/parnerOperation/learnMg.vue b/src/views/parnerOperation/learnMg.vue index 6d399ba..32040f2 100644 --- a/src/views/parnerOperation/learnMg.vue +++ b/src/views/parnerOperation/learnMg.vue @@ -333,12 +333,12 @@ export default { // 文章详情 getArticle() { const { id } = this.form - id && this.$post(`${this.api.findByIdParnerArticle}?id=${id}`).then(({ data }) => { + id ? this.$post(`${this.api.findByIdParnerArticle}?id=${id}`).then(({ data }) => { data.lableId = data.lableId ? data.lableId.split(',').map(e => +e) : [] data.fileList.forEach(e => e.name = e.fileName) this.form = data this.getClassification(1) - }).catch(err => {}) + }).catch(err => {}) : this.getClassification(1) }, // 获取所属分类 getClassification(detail) { diff --git a/src/views/parnerOperation/schemeSet.vue b/src/views/parnerOperation/schemeSet.vue index d7ce72a..24aa043 100644 --- a/src/views/parnerOperation/schemeSet.vue +++ b/src/views/parnerOperation/schemeSet.vue @@ -217,11 +217,11 @@ export default { // 详情 getArticle() { const { id } = this.form - id && this.$post(`${this.api.findByIdScheme}?id=${id}`).then(({ data }) => { + id ? this.$post(`${this.api.findByIdScheme}?id=${id}`).then(({ data }) => { if (data.schemeFile) this.fileList = [{name: data.fileName, url: data.schemeFile}] this.form = data this.getClassification(1) - }).catch(err => {}) + }).catch(err => {}) : this.getClassification(1) }, // 获取所属分类 getClassification(detail) {