Commit c21244b7 authored by 姬鋆屾's avatar 姬鋆屾

fixed:修改线上企业频道不显示关联企业选择框得问题

parent 98478996
...@@ -36,11 +36,12 @@ ...@@ -36,11 +36,12 @@
prop="categoryId" prop="categoryId"
v-model="form.categoryId" v-model="form.categoryId"
type="radio" type="radio"
@change="handlechange"
:enum-data="dict.categoryId" :enum-data="dict.categoryId"
placeholder="请输入分类id" placeholder="请输入分类id"
/> />
<template v-if="form.categoryId == 1"> <template v-if="showCompany">
<Field <Field
label="所属企业" label="所属企业"
:span="40" :span="40"
...@@ -154,6 +155,7 @@ export default { ...@@ -154,6 +155,7 @@ export default {
companyData: [], companyData: [],
relatedCompany: {}, relatedCompany: {},
// 遮罩层 // 遮罩层
showCompany: false,
loading: true, loading: true,
// 弹出层标题 // 弹出层标题
title: "新闻", title: "新闻",
...@@ -183,6 +185,12 @@ export default { ...@@ -183,6 +185,12 @@ export default {
}, },
methods: { methods: {
handlechange(val) {
this.dict.categoryId[val].indexOf("企业") > -1
? (this.showCompany = true)
: (this.showCompany = false);
this.showCompany ? "" : (this.form.relatedCompany = "");
},
/** 编辑 */ /** 编辑 */
edit(row) { edit(row) {
this.reset(); this.reset();
......
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