| | |
| | | :ajaxFun="ajaxFun" |
| | | ref="partFamilyTable" |
| | | > |
| | | <template #toolbar></template> |
| | | <template #toolbar> |
| | | <el-button @click="addOrUpdateHandle" type="primary" |
| | | v-if="permissions.basic_post_add">新增</el-button> |
| | | </template> |
| | | </ttable> |
| | | </el-col> |
| | | <el-col :span="12" style="padding-left: 10px"> |
| | |
| | | searchInfoType: 'text' |
| | | } |
| | | ], |
| | | toolbar: [ |
| | | { |
| | | text: '新增', |
| | | type: 'primary', |
| | | fun: this.addOrUpdateHandle |
| | | } |
| | | ], |
| | | operator: [ |
| | | { |
| | | text: '删除', |
| | | icon: 'el-icon-delete', |
| | | type: 'text', |
| | | size: 'small', |
| | | fun: this.deleteHandle |
| | | } |
| | | ], |
| | | toolbar: [], |
| | | operator: null, |
| | | operatorConfig: { |
| | | fixed: 'right', |
| | | label: '操作', |
| | | width: 60, |
| | | minWidth: 60 |
| | | width: 70, |
| | | minWidth: 70 |
| | | } |
| | | }, |
| | | |
| | |
| | | TableForm, |
| | | ttable |
| | | }, |
| | | created(){ |
| | | if(this.permissions.basic_staff_del){ |
| | | this.table.operator = [ |
| | | { |
| | | text: '删除', |
| | | icon: 'el-icon-delete', |
| | | type: 'text', |
| | | size: 'small', |
| | | fun: this.deleteHandle |
| | | } |
| | | ] |
| | | } |
| | | }, |
| | | computed: { |
| | | ...mapGetters(['permissions']) |
| | | }, |
| | |
| | | }, |
| | | // 新增 / 修改 |
| | | addOrUpdateHandle(row) { |
| | | if(!this.permissions.basic_post_edit && row.id!=null){ |
| | | return |
| | | } |
| | | this.addOrUpdateVisible = true |
| | | this.$nextTick(() => { |
| | | this.$refs.addOrUpdate.init(row == null ? null : row.id) |