|
@@ -27,7 +27,7 @@
|
|
|
<span v-if="tagActive === index">
|
|
|
<el-input v-model="name" class="tagInput" size="mini" placeholder="请输入标签" />
|
|
|
<el-select v-model="propertyId" class="tagSelect" size="mini" placeholder="请选择标签属性">
|
|
|
- <el-option v-for="item in dict.type.label_type" :key="item.value" :label="item.label"
|
|
|
+ <el-option v-for="item in dict.type.audio_type" :key="item.value" :label="item.label"
|
|
|
:value="item.value" />
|
|
|
</el-select>
|
|
|
<el-button type="primary" size="mini" @click="handleInput(index)">添加</el-button>
|
|
@@ -46,7 +46,7 @@
|
|
|
<div v-if="inputVisible_3">
|
|
|
<el-input v-model="name" class="tagInput" size="mini" placeholder="请输入标签" ref="tagInput" />
|
|
|
<el-select v-model="propertyId" class="tagSelect" size="mini" placeholder="请选择标签属性">
|
|
|
- <el-option v-for="item in dict.type.label_type" :key="item.value" :label="item.label"
|
|
|
+ <el-option v-for="item in dict.type.audio_type" :key="item.value" :label="item.label"
|
|
|
:value="item.value" />
|
|
|
</el-select>
|
|
|
<el-button type="primary" size="mini" @click="handleInput">添加</el-button>
|
|
@@ -61,7 +61,7 @@
|
|
|
:value="item.threeId" />
|
|
|
</el-select>
|
|
|
<el-select v-model="dialogForm.type" disabled style="width: 200px; margin-right: 10px">
|
|
|
- <el-option v-for="item in dict.type.label_type" :key="item.propertyId" :label="item.label"
|
|
|
+ <el-option v-for="item in dict.type.audio_type" :key="item.propertyId" :label="item.label"
|
|
|
:value="item.value" />
|
|
|
</el-select>
|
|
|
<el-button type="primary" icon="el-icon-plus" @click="getDialog">
|
|
@@ -128,7 +128,7 @@
|
|
|
<script>
|
|
|
import { create, contentList, findList, detail, edit, createTag, remove } from '@/api/label/tag'
|
|
|
export default {
|
|
|
- dicts: ['label_type', 'free_yes_no'],
|
|
|
+ dicts: ['audio_type', 'free_yes_no'],
|
|
|
data() {
|
|
|
return {
|
|
|
// 遮罩层
|
|
@@ -198,19 +198,20 @@ export default {
|
|
|
},
|
|
|
mounted() {
|
|
|
if (this.$route.query.id) {
|
|
|
- this.form.id = this.$route.query.id
|
|
|
+ this.form.firstId = this.$route.query.id
|
|
|
this.getDetail()
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
// 详情
|
|
|
getDetail() {
|
|
|
- detail(this.form.id).then(res => {
|
|
|
+ detail(this.form.firstId).then(res => {
|
|
|
if (res.code === 0) {
|
|
|
this.form = res.data
|
|
|
res.data.secondTags.length > 0 ? this.inside = true : this.outside = true
|
|
|
res.data.threeTag ? '' : this.form.threeTag = []
|
|
|
- this.typeOptions = res.data.threeTag.length > 0 ? res.data.threeTag : ''
|
|
|
+ console.log(res.data.secondTags);
|
|
|
+ this.typeOptions = res.data.threeTag.length > 0 ? res.data.threeTag : res.data.secondTags.map(i => i.threeTag)
|
|
|
}
|
|
|
})
|
|
|
},
|
|
@@ -419,10 +420,10 @@ export default {
|
|
|
|
|
|
// 字典翻译
|
|
|
propertyFormatter(row) {
|
|
|
- return this.selectDictLabel(this.dict.type.label_type, row)
|
|
|
+ return this.selectDictLabel(this.dict.type.audio_type, row)
|
|
|
},
|
|
|
typeFormatter(row) {
|
|
|
- return this.selectDictLabel(this.dict.type.label_type, row.audioType)
|
|
|
+ return this.selectDictLabel(this.dict.type.audio_type, row.audioType)
|
|
|
},
|
|
|
freeFormatter(row) {
|
|
|
return this.selectDictLabel(this.dict.type.free_yes_no, row.isFree)
|