第7天
团队今天在对安全风险检查表的前端进行了修改和功能的添加 :文件导入之后就是分页查询 分页查询这里 发现增和改复用函数,导致乐观锁。 <el-dialog
(https://img2024.cnblogs.com/blog/3634350/202504/3634350-20250426233346345-1978141202.jpg)
安全风险报表前端:(部分)
</div>
<div class="other-buttons-wrapper">
<el-button @click="add" type="primary">
添加数据
</el-button>
<el-button @click="openQueryDialog" type="primary">
分组查询
</el-button>
<el-upload
action="http://localhost:9090/safetyrisk/import"
method="post"
:on-success="handleImport"
:before-upload="beforeUpload"
accept=".xlsx,.xls"
>
<el-button type="primary">
批量导入
</el-button>
</el-upload>
<el-button @click="exportData" type="primary">
批量导出
</el-button>
</div>
v-model="dialogVisible"
title="添加/编辑风险记录"
width="50%"
:before-close="handleClose"
:confirmButtonText="'提交'"
:cancelButtonText="'关闭'"<span>
<el-form
:label-position="labelPosition"
label-width="100px"
:model="form"
style="max-width: 800px"
>
<el-form-item label="id">
<el-input v-model="form.id" disabled /> <!-- 禁用 id 输入框 -->
</el-form-item>
<el-form-item label="风险编码">
<el-input v-model="form.risk_code" />
</el-form-item>
<el-form-item label="责任部门/工区">
<el-input v-model="form.department" />
</el-form-item>
<el-form-item label="专业系统">
<el-input v-model="form.professional_system" />
</el-form-item>
<el-form-item label="风险类别">
<el-input v-model="form.risk_category" />
</el-form-item>
<el-form-item label="风险项目">
<el-input v-model="form.risk_item" />
</el-form-item>
<el-form-item label="风险项点">
<el-input v-model="form.risk_point" />
</el-form-item>
<!-- 修改为单选框 -->
<el-form-item label="风险等级">
<el-radio-group v-model="form.risk_level">
<el-radio label="重大">重大</el-radio>
<el-radio label="较大">较大</el-radio>
<el-radio label="一般">一般</el-radio>
<el-radio label="低">低</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="危害程度">
<el-radio-group v-model="form.harm_degree">
<el-radio label="较高">较高</el-radio>
<el-radio label="高">高</el-radio>
<el-radio label="中">中</el-radio>
<el-radio label="低">低</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="管控措施">
<el-input v-model="form.control_measures" />
</el-form-item>
<el-form-item label="管控岗位">
<el-input v-model="form.control_position" />
</el-form-item>
<el-form-item label="管控人员">
<el-input v-model="form.control_personnel" />
</el-form-item>
<el-form-item label="量化要求">
<el-input v-model="form.quantified_requirements" />
</el-form-item>
<el-form-item label="开始录入日期">
<el-date-picker
v-model="form.entry_start_date"
type="date"
placeholder="选择日期"
/>
</el-form-item>
<el-form-item label="结束录入日期">
<el-date-picker
v-model="form.entry_end_date"
type="date"
placeholder="选择日期"
/>
</el-form-item>
<el-form-item label="审核状态">
<el-radio-group v-model="form.review_status">
<el-radio label="待审核">待审核</el-radio>
<el-radio label="已通过">已通过</el-radio>
<el-radio label="已拒绝">已拒绝</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="审核日期">
<el-date-picker
v-model="form.review_date"
type="date"
placeholder="选择日期"
/>
</el-form-item>
</el-form>
</span>
<template #footer>
<span class="dialog-footer">
<el-button @click="dialogVisible = false">取消</el-button>
<el-button type="primary" @click="save">
确认
</el-button>
</span>
</template>

浙公网安备 33010602011771号