文件名从 src/views/doublePrevent/riskLevel/check/index.vue 修改 |
| | |
| | | </div> |
| | | <div class="basic-line"> |
| | | <span>部门:</span> |
| | | <el-cascader |
| | | :options="departmentList" |
| | | :props="{ emitPath: false, checkStrictly: true, value: 'depId', label: 'depName' }" |
| | | placeholder="请选择部门" |
| | | clearable |
| | | filterable |
| | | class="input-box" |
| | | v-model="checkUnitData.params.depId" |
| | | > |
| | | </el-cascader> |
| | | <el-cascader :options="departmentList" :props="{ emitPath: false, checkStrictly: true, value: 'depId', label: 'depName' }" placeholder="请选择部门" clearable filterable class="input-box" v-model="checkUnitData.params.depId"> </el-cascader> |
| | | </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="onDelcheckUnit(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="onDelcheckUnit(scope.row)">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <br /> |
| | | <el-pagination |
| | | @size-change="onHandleSizeChange" |
| | | @current-change="onHandleCurrentChange" |
| | | :pager-count="5" |
| | | :page-sizes="[10, 20, 30]" |
| | | v-model:current-page="checkUnitData.params.pageIndex" |
| | | background |
| | | v-model:page-size="checkUnitData.params.pageSize" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | :total="checkUnitData.total" |
| | | class="page-position" |
| | | > |
| | | </el-pagination> |
| | | <el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" :pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="checkUnitData.params.pageIndex" background v-model:page-size="checkUnitData.params.pageSize" layout="total, sizes, prev, pager, next, jumper" :total="checkUnitData.total" class="page-position"> </el-pagination> |
| | | <br /> |
| | | <br /> |
| | | </el-card> |
| | |
| | | import { ElMessageBox, ElMessage } from 'element-plus'; |
| | | import checkUnitDialog from './components/checkUnitDialog.vue'; |
| | | import { checkUnitApi } from '/@/api/doublePreventSystem/checkUnit/index.ts'; |
| | | import { Edit, Delete, View } from '@element-plus/icons-vue'; |
| | | |
| | | // 定义接口来定义对象的类型 |
| | | interface TableData { |
| | |
| | | } |
| | | |
| | | export default defineComponent({ |
| | | name: 'checkUnit', |
| | | components: { checkUnitDialog }, |
| | | name: 'index', |
| | | components: { checkUnitDialog, Edit, Delete, View }, |
| | | setup() { |
| | | const checkUnitDialogRef = ref(); |
| | | const state = reactive<TableDataState>({ |
| | |
| | | }); |
| | | |
| | | return { |
| | | Edit, |
| | | Delete, |
| | | View, |
| | | handleSearch, |
| | | onOpenDialogRef, |
| | | onHandleSizeChange, |