Commit 7f638e62 by yanju

博客栏目的全称

parent 07c8f024
...@@ -112,21 +112,13 @@ export default { ...@@ -112,21 +112,13 @@ export default {
dataGetBlogCategory(){ dataGetBlogCategory(){
this.typeList.map((val) => { this.typeList.map((val) => {
if(!val.leaf){
this.list.push({ this.list.push({
label: val.category, label: val.category,
address: '/blog', address: '/blog',
type: val.categoryId.toString(), type: val.categoryId.toString(),
childList:[] childList:[],
title:val.categoryFull
}) })
}else{
this.list.push({
label: val.category,
address: '/blog',
type: val.categoryId.toString(),
})
}
}) })
this.typeList.map(async (val,index) => { this.typeList.map(async (val,index) => {
if(!val.leaf){ if(!val.leaf){
...@@ -137,6 +129,7 @@ export default { ...@@ -137,6 +129,7 @@ export default {
label: val.category, label: val.category,
address: '/blog', address: '/blog',
childId: val.categoryId.toString(), childId: val.categoryId.toString(),
title:val.categoryFull
}) })
}) })
this.list[index+1].childList = childList this.list[index+1].childList = childList
...@@ -151,12 +144,12 @@ export default { ...@@ -151,12 +144,12 @@ export default {
if(val.childList){ if(val.childList){
val.childList.map((chVal) => { val.childList.map((chVal) => {
if(chVal.childId===type){ if(chVal.childId===type){
this.labelTitle = chVal.label this.labelTitle = chVal.title||chVal.label
} }
}) })
} }
if(val.type===type){ if(val.type===type){
this.labelTitle = val.label this.labelTitle = val.title||val.label
} }
}) })
}, },
......
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