| | |
| | | <li v-permissions="['business:category:exportExcel']"><el-button type="primary" |
| | | @click="exportExcel">导出</el-button></li> |
| | | </ul> |
| | | <el-table row-key="id" :tree-props="{ children: 'childCategoryList' }" v-loading="isWorking.search" |
| | | <el-table :height="tableHeightNew" row-key="id" :tree-props="{ children: 'childCategoryList' }" v-loading="isWorking.search" |
| | | :data="dataList" stripe @selection-change="handleSelectionChange"> |
| | | <el-table-column prop="name" label="分类名称" min-width="100px"></el-table-column> |
| | | <el-table-column prop="remark" label="备注" min-width="100px"></el-table-column> |
| | |
| | | pagination: { |
| | | pageSize: 10, |
| | | page: 1, |
| | | total: 0, |
| | | total: 0 |
| | | }, |
| | | dataList: [] |
| | | } |
| | |
| | | methods: { |
| | | handleEdit(row) { |
| | | this.isShowEdit = true |
| | | let str = row && row.id ? '编辑车辆分类' : '新建车辆分类' |
| | | const str = row && row.id ? '编辑车辆分类' : '新建车辆分类' |
| | | this.$nextTick(() => { |
| | | this.$refs.operaCategoryWindow.open(str) |
| | | this.$refs.operaCategoryWindow.getList() |
| | |
| | | }) |
| | | }, |
| | | deleteById(row) { |
| | | this.$confirm(`您确认要删除该分类吗`, '温馨提示', { |
| | | this.$confirm('您确认要删除该分类吗', '温馨提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning' |
| | |
| | | this.getList() |
| | | }) |
| | | }) |
| | | |
| | | }, |
| | | getList(page) { |
| | | const { pagination, filters } = this |
| | |
| | | fetchList({ |
| | | model: { ...filters }, |
| | | capacity: pagination.pageSize, |
| | | page: pagination.page, |
| | | page: pagination.page |
| | | }).then(res => { |
| | | this.loading = false |
| | | this.dataList = res.records || [] |