|
...
|
...
|
@@ -5,6 +5,7 @@ |
|
|
|
v-loading="loading"
|
|
|
|
:data="policyList"
|
|
|
|
@selection-change="handleSelectionChange"
|
|
|
|
@row-click="handleUpdate"
|
|
|
|
>
|
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
|
<el-table-column
|
|
...
|
...
|
@@ -45,33 +46,46 @@ |
|
|
|
align="center"
|
|
|
|
/>
|
|
|
|
<el-table-column label="操作" align="center" width="360" fixed="right">
|
|
|
|
<template #default="scope">
|
|
|
|
<template #default="{ row }">
|
|
|
|
<el-popconfirm
|
|
|
|
width="2000"
|
|
|
|
title="是否通过该保单?"
|
|
|
|
width="200"
|
|
|
|
hide-icon
|
|
|
|
:title="
|
|
|
|
row.company === '无'
|
|
|
|
? '该登记信息未选择上年承保公司,系统将执行自动分配规则'
|
|
|
|
: '该登记信息存在上年承保公司,系统自动流转保单至上年承保公司处理'
|
|
|
|
"
|
|
|
|
confirm-button-text="确定"
|
|
|
|
cancel-button-text="取消"
|
|
|
|
@confirm="handleSuccess(scope.row)"
|
|
|
|
@confirm="handleSuccess(row)"
|
|
|
|
>
|
|
|
|
<template #reference>
|
|
|
|
<el-button type="success">通过</el-button>
|
|
|
|
<el-button type="success" @click.stop="">通过</el-button>
|
|
|
|
</template>
|
|
|
|
</el-popconfirm>
|
|
|
|
|
|
|
|
<el-button
|
|
|
|
@click="handleFallback(scope.row)"
|
|
|
|
v-hasPermi="['system:role:remove']"
|
|
|
|
>退回</el-button
|
|
|
|
<el-popconfirm
|
|
|
|
width="200"
|
|
|
|
hide-icon
|
|
|
|
title="保单将退回至用户界面,用户修改后重新提交"
|
|
|
|
confirm-button-text="确定"
|
|
|
|
cancel-button-text="取消"
|
|
|
|
@confirm="handleFallback(row)"
|
|
|
|
>
|
|
|
|
<template #reference>
|
|
|
|
<el-button @click.stop="">退回</el-button>
|
|
|
|
</template>
|
|
|
|
</el-popconfirm>
|
|
|
|
|
|
|
|
<el-button
|
|
|
|
type="danger"
|
|
|
|
@click="handleVoid(scope.row)"
|
|
|
|
@click.stop="handleVoid(row)"
|
|
|
|
v-hasPermi="['system:role:edit']"
|
|
|
|
>作废</el-button
|
|
|
|
>
|
|
|
|
<el-button
|
|
|
|
type="primary"
|
|
|
|
@click="handleAuthCompany(scope.row)"
|
|
|
|
@click.stop="handleAuthCompany(row)"
|
|
|
|
v-hasPermi="['system:role:edit']"
|
|
|
|
>分配承保公司</el-button
|
|
|
|
>
|
|
...
|
...
|
@@ -86,12 +100,171 @@ |
|
|
|
v-model:limit="queryParams.pageSize"
|
|
|
|
@pagination="getList"
|
|
|
|
/>
|
|
|
|
|
|
|
|
<!-- 表单作废对话框 -->
|
|
|
|
<el-dialog
|
|
|
|
v-model="deprecatedShow"
|
|
|
|
title="温馨提示:该保单作废后车牌号、车架号在本自然年度无法重新提交"
|
|
|
|
width="500"
|
|
|
|
append-to-body
|
|
|
|
>
|
|
|
|
<el-input
|
|
|
|
:rows="6"
|
|
|
|
type="textarea"
|
|
|
|
placeholder="请输入作废原因"
|
|
|
|
v-model="deprecatedReason"
|
|
|
|
resize="none"
|
|
|
|
/>
|
|
|
|
<template #footer>
|
|
|
|
<div class="dialog-footer">
|
|
|
|
<el-button @click="deprecatedShow = false">取消</el-button>
|
|
|
|
<el-button type="primary" @click="deprecatedShow = false"
|
|
|
|
>确定</el-button
|
|
|
|
>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
<!-- 分配承保公司对话框 -->
|
|
|
|
<el-dialog
|
|
|
|
v-model="companyShow"
|
|
|
|
title="分配承保公司:"
|
|
|
|
width="500"
|
|
|
|
append-to-body
|
|
|
|
>
|
|
|
|
<div class="company_box">
|
|
|
|
<div class="header_top">
|
|
|
|
<el-input
|
|
|
|
v-model="companyValue"
|
|
|
|
style="width: 380px"
|
|
|
|
placeholder="请输入承保公司名称(支持模糊查询)"
|
|
|
|
prefix-icon="Search"
|
|
|
|
/>
|
|
|
|
<el-button type="primary">查询</el-button>
|
|
|
|
</div>
|
|
|
|
<el-radio-group v-model="company">
|
|
|
|
<el-radio
|
|
|
|
v-for="item in companyList"
|
|
|
|
:key="item.id"
|
|
|
|
:label="item.value"
|
|
|
|
>{{ item.label }}</el-radio
|
|
|
|
>
|
|
|
|
</el-radio-group>
|
|
|
|
</div>
|
|
|
|
<template #footer>
|
|
|
|
<div class="dialog-footer">
|
|
|
|
<el-button @click="companyShow = false">取消</el-button>
|
|
|
|
<el-button type="primary" @click="companyShow = false"
|
|
|
|
>确定</el-button
|
|
|
|
>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
<!-- 编辑对话框 -->
|
|
|
|
<el-dialog v-model="open" :title="title" width="700" append-to-body>
|
|
|
|
<el-form :model="form" :rules="rules" ref="policyRef" label-width="100px">
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="12">
|
|
|
|
<el-form-item label="车牌号" prop="carNum">
|
|
|
|
<el-input
|
|
|
|
v-model="form.carNum"
|
|
|
|
placeholder="请输入车牌号"
|
|
|
|
maxlength="30"
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="12">
|
|
|
|
<el-form-item label="车架号" prop="frameNum">
|
|
|
|
<el-input
|
|
|
|
v-model="form.frameNum"
|
|
|
|
placeholder="请输入车架号"
|
|
|
|
maxlength="30"
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="12">
|
|
|
|
<el-form-item label="车主姓名" prop="name">
|
|
|
|
<el-input
|
|
|
|
v-model="form.name"
|
|
|
|
placeholder="请输入车主姓名"
|
|
|
|
maxlength="11"
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="12">
|
|
|
|
<el-form-item label="联系电话" prop="phone">
|
|
|
|
<el-input
|
|
|
|
v-model="form.phone"
|
|
|
|
placeholder="请输入联系电话"
|
|
|
|
maxlength="50"
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="12">
|
|
|
|
<el-form-item label="登记时间" prop="createTime">
|
|
|
|
<el-input
|
|
|
|
v-model="form.createTime"
|
|
|
|
placeholder="请输入登记时间"
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="12">
|
|
|
|
<el-form-item label="上年承保公司" prop="company">
|
|
|
|
<el-input
|
|
|
|
v-model="form.company"
|
|
|
|
placeholder="请输入上年承保公司"
|
|
|
|
maxlength="50"
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-row>
|
|
|
|
</el-form>
|
|
|
|
<template #footer>
|
|
|
|
<div class="dialog-footer">
|
|
|
|
<el-button @click="open = false">取消</el-button>
|
|
|
|
<el-button type="primary" @click="open = false">确定</el-button>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</el-dialog>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script setup>
|
|
|
|
const { proxy } = getCurrentInstance();
|
|
|
|
const loading = ref(false);
|
|
|
|
const total = ref(5);
|
|
|
|
const title = ref("保单信息");
|
|
|
|
const open = ref(false);
|
|
|
|
const form = ref({});
|
|
|
|
const rules = ref({
|
|
|
|
carNum: [{ required: true, message: "车牌号不能为空", trigger: "blur" }],
|
|
|
|
frameNum: [{ required: true, message: "车架号不能为空", trigger: "blur" }],
|
|
|
|
name: [{ required: true, message: "车主姓名不能为空", trigger: "blur" }],
|
|
|
|
createTime: [{ required: true, message: "日期不能为空", trigger: "blur" }],
|
|
|
|
phone: [
|
|
|
|
{
|
|
|
|
pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
|
|
|
|
message: "请输入正确的手机号码",
|
|
|
|
trigger: "blur",
|
|
|
|
},
|
|
|
|
],
|
|
|
|
});
|
|
|
|
const companyShow = ref(false);
|
|
|
|
const companyList = ref([
|
|
|
|
{ id: 1, value: 0, label: "中国太平洋保险集团" },
|
|
|
|
{ id: 2, value: 1, label: "中国平安财产保险股份有限公司" },
|
|
|
|
{ id: 3, value: 2, label: "北部湾财产保险股份有限公司" },
|
|
|
|
{ id: 4, value: 3, label: "华安财产保险股份有限公司" },
|
|
|
|
]);
|
|
|
|
const company = ref(2);
|
|
|
|
const companyValue = ref("");
|
|
|
|
const deprecatedShow = ref(false);
|
|
|
|
const deprecatedReason = ref("");
|
|
|
|
const queryParams = reactive({
|
|
|
|
pageNum: 1,
|
|
|
|
pageSize: 10,
|
|
...
|
...
|
@@ -163,10 +336,50 @@ const handleFallback = () => { |
|
|
|
};
|
|
|
|
const handleVoid = () => {
|
|
|
|
console.log("作废");
|
|
|
|
deprecatedShow.value = true;
|
|
|
|
};
|
|
|
|
const handleAuthCompany = () => {
|
|
|
|
console.log("分配承保公司");
|
|
|
|
companyShow.value = true;
|
|
|
|
};
|
|
|
|
/** 重置操作表单 */
|
|
|
|
function reset() {
|
|
|
|
form.value = {
|
|
|
|
policyId: undefined,
|
|
|
|
createTime: undefined,
|
|
|
|
carNum: undefined,
|
|
|
|
frameNum: undefined,
|
|
|
|
name: undefined,
|
|
|
|
phone: undefined,
|
|
|
|
company: undefined,
|
|
|
|
};
|
|
|
|
proxy.resetForm("policyRef");
|
|
|
|
}
|
|
|
|
|
|
|
|
/** 修改按钮操作 */
|
|
|
|
function handleUpdate(row) {
|
|
|
|
reset();
|
|
|
|
form.value = row;
|
|
|
|
open.value = true;
|
|
|
|
}
|
|
|
|
/** 提交按钮 */
|
|
|
|
function submitForm() {
|
|
|
|
proxy.$refs["policyRef"].validate((valid) => {
|
|
|
|
if (valid) {
|
|
|
|
proxy.$modal.msgSuccess("修改成功");
|
|
|
|
}
|
|
|
|
});
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style></style> |
|
|
|
<style lang="scss" scoped>
|
|
|
|
::v-deep(.el-radio-group) {
|
|
|
|
align-items: start;
|
|
|
|
flex-direction: column;
|
|
|
|
}
|
|
|
|
.header_top {
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
gap: 30px;
|
|
|
|
margin-bottom: 20px;
|
|
|
|
}
|
|
|
|
</style> |
...
|
...
|
|