| | |
| | | <div class="system-user-search mb15"> |
| | | <div class="basic-line"> |
| | | <span>责任部门:</span> |
| | | <el-cascader |
| | | @change="achieveUserList" |
| | | :options="departmentList" |
| | | :props="{ emitPath: false, checkStrictly: true, value: 'depId', label: 'depName' }" |
| | | placeholder="责任部门" |
| | | clearable |
| | | filterable |
| | | class="input-box" |
| | | v-model="safetyRiskAnalyseUnitData.params.liableDepId" |
| | | > |
| | | </el-cascader> |
| | | <el-cascader @change="achieveUserList" :options="departmentList" :props="{ emitPath: false, checkStrictly: true, value: 'depId', label: 'depName' }" placeholder="责任部门" clearable filterable class="input-box" v-model="safetyRiskAnalyseUnitData.params.liableDepId"> </el-cascader> |
| | | </div> |
| | | <div class="basic-line"> |
| | | <span>责任人:</span> |
| | |
| | | </div> |
| | | <div class="basic-line"> |
| | | <span>单元名称:</span> |
| | | <el-input v-model="safetyRiskAnalyseUnitData.params.riskUnitName" clearable filterable class="input-box" placeholder="单元名称"> |
| | | </el-input> |
| | | <el-input v-model="safetyRiskAnalyseUnitData.params.riskUnitName" clearable filterable class="input-box" placeholder="单元名称"> </el-input> |
| | | </div> |
| | | <el-button size="default" type="primary" class="ml10" v-throttle @click="handleSearch"> |
| | | <el-icon> |
| | |
| | | <el-table-column prop="gmtCreate" label="创建时间" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="lastEditUserName" label="最后修改人" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="gmtModitify" label="最后修改时间" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="操作" width="150"> |
| | | <el-table-column label="操作" width="200" align="center"> |
| | | <template #default="scope"> |
| | | <el-button size="small" text type="primary" @click="onOpenDialogRef('修改', scope.row)">修改</el-button> |
| | | <el-button size="small" text type="danger" @click="onDelProductionDevice(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="Edit" @click="onOpenDialogRef('修改', scope.row)">修改</el-button> |
| | | <el-button size="small" text type="danger" :icon="Delete" @click="onDelRiskUnit(scope.row)">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <br /> |
| | | <el-pagination |
| | | @size-change="onHandleSizeChange" |
| | | @current-change="onHandleCurrentChange" |
| | | class="page-position" |
| | | :pager-count="5" |
| | | :page-sizes="[10, 20, 30]" |
| | | v-model:current-page="safetyRiskAnalyseUnitData.params.pageIndex" |
| | | background |
| | | v-model:page-size="safetyRiskAnalyseUnitData.params.pageSize" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | :total="safetyRiskAnalyseUnitData.total" |
| | | > |
| | | </el-pagination> |
| | | <el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="page-position" :pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="safetyRiskAnalyseUnitData.params.pageIndex" background v-model:page-size="safetyRiskAnalyseUnitData.params.pageSize" layout="total, sizes, prev, pager, next, jumper" :total="safetyRiskAnalyseUnitData.total"> </el-pagination> |
| | | <br /> |
| | | <br /> |
| | | </el-card> |
| | |
| | | import { departmentApi } from '/@/api/department'; |
| | | import { userApi } from '/@/api/user'; |
| | | import { productionDeviceApi } from '/@/api/doublePreventSystem/productionDevice'; |
| | | import { Edit, Delete, View } from '@element-plus/icons-vue'; |
| | | |
| | | // 定义接口来定义对象的类型 |
| | | interface TableData { |
| | |
| | | |
| | | export default { |
| | | name: 'productionDevice', |
| | | components: { safetyRiskAnalyseUnitDialog }, |
| | | components: { safetyRiskAnalyseUnitDialog, Edit, Delete, View }, |
| | | setup() { |
| | | const safetyRiskAnalyseUnitDialogRef = ref(); |
| | | const state = reactive<TableDataState>({ |
| | |
| | | }; |
| | | |
| | | // 删除角色 |
| | | const onDelProductionDevice = (row: any) => { |
| | | const onDelRiskUnit = (row: any) => { |
| | | ElMessageBox.confirm(`此操作将永久删除该条安全风险分析单元:“${row.riskUnitName}”,是否继续?`, '提示', { |
| | | confirmButtonText: '确认', |
| | | cancelButtonText: '取消', |
| | |
| | | }); |
| | | |
| | | return { |
| | | Edit, |
| | | Delete, |
| | | View, |
| | | handleSearch, |
| | | achieveUserList, |
| | | onOpenDialogRef, |
| | | onHandleSizeChange, |
| | | onDelProductionDevice, |
| | | onDelRiskUnit, |
| | | onHandleCurrentChange, |
| | | safetyRiskAnalyseUnitDialog, |
| | | safetyRiskAnalyseUnitDialogRef, |