|
@@ -40,6 +40,10 @@
|
|
<el-table-column label="操作" align="center">
|
|
<el-table-column label="操作" align="center">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button type="text" @click="getDialog('查看', scope.row, true)">查看</el-button>
|
|
<el-button type="text" @click="getDialog('查看', scope.row, true)">查看</el-button>
|
|
|
|
+ <el-button v-if="scope.row.level !== 3" type="text" @click="getDialog('新增', scope.row)"
|
|
|
|
+ v-hasPermi="['operation:tag:add']">
|
|
|
|
+ 新增
|
|
|
|
+ </el-button>
|
|
<el-button type="text" v-if="scope.row.status === 0" @click="getChange(scope.row, 1)"
|
|
<el-button type="text" v-if="scope.row.status === 0" @click="getChange(scope.row, 1)"
|
|
v-hasPermi="['operation:tag:down']">禁用</el-button>
|
|
v-hasPermi="['operation:tag:down']">禁用</el-button>
|
|
<span v-else>
|
|
<span v-else>
|
|
@@ -47,10 +51,6 @@
|
|
v-hasPermi="['operation:tag:edit']">
|
|
v-hasPermi="['operation:tag:edit']">
|
|
编辑
|
|
编辑
|
|
</el-button>
|
|
</el-button>
|
|
- <el-button v-if="scope.row.level !== 3" type="text" @click="getDialog('新增', scope.row)"
|
|
|
|
- v-hasPermi="['operation:tag:add']">
|
|
|
|
- 新增
|
|
|
|
- </el-button>
|
|
|
|
<el-button type="text" @click="getChange(scope.row, 0)" v-hasPermi="['operation:tag:up']">
|
|
<el-button type="text" @click="getChange(scope.row, 0)" v-hasPermi="['operation:tag:up']">
|
|
启用
|
|
启用
|
|
</el-button>
|
|
</el-button>
|
|
@@ -66,10 +66,12 @@
|
|
<el-form :model="dialogForm" ref="dialogForm" :rules="rules" label-width="auto"
|
|
<el-form :model="dialogForm" ref="dialogForm" :rules="rules" label-width="auto"
|
|
:disabled="title === '查看' ? true : false">
|
|
:disabled="title === '查看' ? true : false">
|
|
<el-form-item label="标签名称:" prop="name">
|
|
<el-form-item label="标签名称:" prop="name">
|
|
- <el-input v-model="dialogForm.name" placeholder="请输入标签名称" maxlength="100" show-word-limit :disabled="dialogForm.isEmpty === 0" />
|
|
|
|
|
|
+ <el-input v-model="dialogForm.name" placeholder="请输入标签名称" maxlength="100" show-word-limit
|
|
|
|
+ :disabled="dialogForm.isEmpty === 0" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="标签状态:" prop="isEmpty" v-if="createLevelTwo() || editLevelTwo()">
|
|
<el-form-item label="标签状态:" prop="isEmpty" v-if="createLevelTwo() || editLevelTwo()">
|
|
- <el-checkbox v-model="dialogForm.isEmpty" :true-label="0" :false-label="1" @change="handleChange">允许为空</el-checkbox>
|
|
|
|
|
|
+ <el-checkbox v-model="dialogForm.isEmpty" :true-label="0" :false-label="1" @change="handleChange">
|
|
|
|
+ 允许为空</el-checkbox>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="标签排序:" prop="sort">
|
|
<el-form-item label="标签排序:" prop="sort">
|
|
<el-input-number v-model="dialogForm.sort" :min="1" :step="1" step-strictly />
|
|
<el-input-number v-model="dialogForm.sort" :min="1" :step="1" step-strictly />
|
|
@@ -167,8 +169,8 @@ export default {
|
|
},
|
|
},
|
|
|
|
|
|
// 当二级标签选择为空 清空标签名称
|
|
// 当二级标签选择为空 清空标签名称
|
|
- handleChange(e){
|
|
|
|
- if(e === 0) {
|
|
|
|
|
|
+ handleChange(e) {
|
|
|
|
+ if (e === 0) {
|
|
this.dialogForm.name = ''
|
|
this.dialogForm.name = ''
|
|
}
|
|
}
|
|
},
|
|
},
|