文件名从 src/views/doublePrevent/hiddenManage/hiddenRectify/index.vue 修改 |
| | |
| | | </el-table-column> |
| | | <el-table-column prop="liablePerson" label="整改责任人" show-overflow-tooltip min-width="150px"></el-table-column> |
| | | <el-table-column prop="cost" label="整改资金" show-overflow-tooltip min-width="150px"></el-table-column> |
| | | <el-table-column prop="dangerStatus" label="隐患整改状态" show-overflow-tooltip min-width="150px"> |
| | | <el-table-column prop="dangerStatus" label="隐患整改状态" show-overflow-tooltip min-width="150px" align="center"> |
| | | <template #default="scope"> |
| | | <el-tag :type="scope.row.dangerStatus === 0 ? 'info' : scope.row.dangerStatus === 1 ? 'primary' : scope.row.dangerStatus === 2 ? 'warning' : scope.row.dangerStatus === 4 ? 'danger' : 'success'"> |
| | | {{ parseNumber(scope.row.dangerStatus, '隐患整改状态') }} |
| | |
| | | <el-table-column prop="gmtModitify" label="最后修改时间" show-overflow-tooltip min-width="200px"></el-table-column> |
| | | <el-table-column label="操作" width="250" fixed="right" align="center"> |
| | | <template #default="scope"> |
| | | <el-button size="small" text type="primary" :icon="Check" v-show="scope.row.dangerStatus === 0" @click="onOpenDialogRef('整改', scope.row)">整改</el-button> |
| | | <el-button size="small" text type="primary" :icon="Edit" @click="onOpenDialogRef('延期', scope.row)">延期</el-button> |
| | | <el-button size="small" text type="primary" :icon="View" @click="onOpenDialogRef('查看', scope.row)">查看</el-button> |
| | | <el-button size="small" text type="primary" :icon="Check" v-show="scope.row.dangerStatus === 0 || scope.row.dangerStatus === 2" @click="onOpenDialogRef('整改', scope.row)">整改</el-button> |
| | | <el-button size="small" text type="primary" :icon="Edit" v-show="scope.row.dangerStatus === 0 || scope.row.dangerStatus === 2" @click="onOpenDialogRef('延期', scope.row)">延期</el-button> |
| | | <el-button size="small" text type="danger" :icon="Delete" @click="onDelHiddenRectify(scope.row)">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | import { toRefs, reactive, onMounted, ref, defineComponent } from 'vue'; |
| | | import { ElMessageBox, ElMessage } from 'element-plus'; |
| | | import rectifyDialog from './components/rectifyDialog.vue'; |
| | | import { Edit, Delete, Check } from '@element-plus/icons-vue'; |
| | | import { Edit, Delete, Check, View } from '@element-plus/icons-vue'; |
| | | import { hiddenRectifyApi } from '/@/api/doublePreventSystem/rectify'; |
| | | import { departmentApi } from '/@/api/department'; |
| | | import { productionDeviceApi } from '/@/api/doublePreventSystem/productionDevice'; |
| | |
| | | |
| | | export default defineComponent({ |
| | | name: 'rectify', |
| | | components: { rectifyDialog, Edit, Delete }, |
| | | components: { rectifyDialog, Edit, Delete, View }, |
| | | setup() { |
| | | const rectifyDialogRef = ref(); |
| | | const state = reactive<TableDataState>({ |
| | |
| | | |
| | | // 打开弹窗 |
| | | const onOpenDialogRef = (type: string, value: any) => { |
| | | rectifyDialogRef.value.openRectifyDialog(type, value); |
| | | rectifyDialogRef.value.openRectifyDialog(type, value, state.departmentList); |
| | | }; |
| | | // 删除 |
| | | const onDelHiddenRectify = (row: any) => { |
| | |
| | | |
| | | return { |
| | | Edit, |
| | | View, |
| | | Check, |
| | | Delete, |
| | | parseNumber, |