Commit 5dc0212d by Lyan

文章管理栏目bug更改

parent 110fb972
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
<p v-show="showInfo">{{dataForm.directpath}}</p> <p v-show="showInfo">{{dataForm.directpath}}</p>
</el-form-item> </el-form-item>
<el-form-item label="栏目:" prop="classid"> <el-form-item label="栏目:" prop="classid">
<el-select v-model="dataForm.classid" @change="getCclassList" style='width:121px!important' v-show="!showInfo"> <el-select v-model="dataForm.classid" @change="getCclassList2" style='width:121px!important' v-show="!showInfo">
<!-- <el-option <!-- <el-option
ref = 'sel1' ref = 'sel1'
v-for="item in classidList" v-for="item in classidList"
...@@ -216,6 +216,10 @@ ...@@ -216,6 +216,10 @@
console.log(this.classidList) console.log(this.classidList)
}, },
methods: { methods: {
getCclassList2 (e) {
this.dataForm.cclassid = ''
this.getCclassList(e)
},
getSelectName (list, id) { getSelectName (list, id) {
let arr = list.filter((item) => { let arr = list.filter((item) => {
return item.id === id return item.id === id
...@@ -238,12 +242,7 @@ ...@@ -238,12 +242,7 @@
this.loading = false this.loading = false
if (data && data.code === 0) { if (data && data.code === 0) {
this.dataForm = data.news this.dataForm = data.news
// this.getClassList([5, 9])
this.dataForm.ishead = parseInt(data.news.ishead) this.dataForm.ishead = parseInt(data.news.ishead)
// this.getClassList([this.dataForm.classid])
this.dataForm.cclassid = this.dataForm.cclassid
this.imgUrlStr = data.news.pic this.imgUrlStr = data.news.pic
this.dialogVisible = true this.dialogVisible = true
this.ueditor.value = this.dataForm.content this.ueditor.value = this.dataForm.content
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment