Browse Source

模块类型新增内容详情

feature/syp_points
songyunpeng 4 years ago
parent
commit
4f04101030
  1. 23
      src/views/modules/news/modulecategory-add-or-update.vue

23
src/views/modules/news/modulecategory-add-or-update.vue

@ -23,6 +23,16 @@
<el-button type="primary" @click="openModuleStyleSelect">点击选择模块样式</el-button> <el-button type="primary" @click="openModuleStyleSelect">点击选择模块样式</el-button>
{{moduleStyleName}} {{moduleStyleName}}
</el-form-item> </el-form-item>
<el-form-item label="详情样式">
<el-select v-model="dataForm.detailStyle" multiple placeholder="请选择">
<el-option
v-for="item in detailStyleList"
:key="item.dictValue"
:label="item.dictName"
:value="item.dictValue">
</el-option>
</el-select>
</el-form-item>
<el-form-item prop="parentName" label="上级分类" class="category-list"> <el-form-item prop="parentName" label="上级分类" class="category-list">
<el-popover v-model="categoryListVisible" ref="categoryListPopover" placement="bottom-start" trigger="click"> <el-popover v-model="categoryListVisible" ref="categoryListPopover" placement="bottom-start" trigger="click">
<el-tree :data="categoryList" <el-tree :data="categoryList"
@ -125,7 +135,8 @@ export default {
imgUrl: '', imgUrl: '',
moduleStyle: '', moduleStyle: '',
bannerFlag: '', bannerFlag: '',
commentFlag: '' commentFlag: '',
detailStyle: []
}, },
secondOrgDictList: [], secondOrgDictList: [],
// //
@ -148,6 +159,7 @@ export default {
moduleStyleName: '', moduleStyleName: '',
moduleStyleListVisible: false, moduleStyleListVisible: false,
moduleStyleList: [], moduleStyleList: [],
detailStyleList: [],
categoryTypeList: [] categoryTypeList: []
} }
}, },
@ -159,6 +171,7 @@ export default {
this.dataForm.imgUrl = '' this.dataForm.imgUrl = ''
this.getModuleStyleList() this.getModuleStyleList()
this.getCategoryTypeList() this.getCategoryTypeList()
this.getDetailStyleList()
}, },
computed: { computed: {
dataRule () { dataRule () {
@ -216,6 +229,14 @@ export default {
this.moduleStyleList = res.data this.moduleStyleList = res.data
}).catch(() => {}) }).catch(() => {})
}, },
getDetailStyleList () {
this.$http.get(`/sys/dict/listSimple/detail_style`).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.detailStyleList = res.data
}).catch(() => {})
},
getCategoryTypeList () { getCategoryTypeList () {
this.$http.get(`/sys/dict/listSimple/module_category_type`).then(({ data: res }) => { this.$http.get(`/sys/dict/listSimple/module_category_type`).then(({ data: res }) => {
if (res.code !== 0) { if (res.code !== 0) {

Loading…
Cancel
Save