作者 xiaoqiu

优化了刷新按钮,表单内增加了保险需求字段

@@ -8,6 +8,6 @@ VITE_APP_ENV = 'development' @@ -8,6 +8,6 @@ VITE_APP_ENV = 'development'
8 VITE_APP_BASE_API = '/dev-api' 8 VITE_APP_BASE_API = '/dev-api'
9 9
10 # 开打新的tab的url前缀 10 # 开打新的tab的url前缀
11 -VITE_APP_TAB_URL_PREFIX = 'http://192.168.2.190:6512' 11 +VITE_APP_TAB_URL_PREFIX = 'http://192.168.2.11:6512'
12 12
13 # VITE_APP_TAB_URL_PREFIX = 'http://bxhd.crgx.net' 13 # VITE_APP_TAB_URL_PREFIX = 'http://bxhd.crgx.net'
不能预览此文件类型
  1 +import { reactive, ref } from "vue";
  2 +import { queryCarNature } from "@/api/configurationCenter/carNature.js";
  3 +import { queryNeed } from "@/api/configurationCenter/need.js";
  4 +export default function() {
  5 + // 获取数据的请求参数
  6 + const getParams = reactive({
  7 + pageNum: 1,
  8 + pageSize: 100,
  9 + });
  10 + // 车辆使用性质
  11 + const carNatureOption = ref([]);
  12 + const getcarNatureOption = async () => {
  13 + const { data } = await queryCarNature(getParams);
  14 + carNatureOption.value = data.records;
  15 + };
  16 + getcarNatureOption();
  17 + // 保险需求
  18 + const needOption = ref([]);
  19 + const getNeedOption = async () => {
  20 + const { data } = await queryNeed(getParams);
  21 + needOption.value = data.records;
  22 + };
  23 + getNeedOption();
  24 + // 新能源
  25 + const NewEnergyOption = ref([
  26 + {
  27 + id: "0",
  28 + name: "否",
  29 + },
  30 + {
  31 + id: "1",
  32 + name: "是",
  33 + },
  34 + ]);
  35 + // 通过返回值暴露响应式变量、方法
  36 + return {
  37 + carNatureOption,
  38 + needOption,
  39 + NewEnergyOption
  40 + };
  41 +}
  1 +import { disposeUser } from "@/api/policy/index";
  2 +import { listDept } from "@/api/system/dept";
  3 +export default function useSharingCompany(){
  4 + // 分配承保公司弹窗显示
  5 + const companyShow = ref(false);
  6 + // 分配承保公司查询参数
  7 + const companyQueryParams = reactive({
  8 + deptName: undefined,
  9 + status: undefined,
  10 + });
  11 + // 分配承保公司列表数据
  12 + const deptOptions = ref([
  13 + {
  14 + deptId: "0",
  15 + deptName: "无",
  16 + },
  17 + ]);
  18 + // 确认选择的承保公司数据表单
  19 + const companyForm = ref({});
  20 + const sharingShow = ref(false); // 分配备注显示变量
  21 + const sharingMsg = ref(""); // 分配备注
  22 + // 分配承保公司
  23 + const handleAuthCompany = (associationapprove, taskId) => {
  24 + companyForm.value = {
  25 + associationapprove,
  26 + taskId: taskId,
  27 + };
  28 + companyShow.value = true;
  29 + };
  30 + /** 提交通过分配承保公司 */
  31 + function submitForm() {
  32 + return new Promise((resolve, reject) => {
  33 + const data = {
  34 + associationapprove: companyForm.value.associationapprove,
  35 + associationapprovetype: "1",
  36 + deptid: companyForm.value.deptId.toString(),
  37 + comment: sharingMsg.value,
  38 + };
  39 + const taskId = companyForm.value.taskId;
  40 + disposeUser(data, taskId).then(() => {
  41 + companyShow.value = false;
  42 + sharingShow.value = false;
  43 + resolve();
  44 + })
  45 +
  46 + });
  47 + }
  48 + /** 查询承保公司列表 */
  49 + const getDeptList = () => {
  50 + listDept(companyQueryParams).then((response) => {
  51 + let newArr = [];
  52 + newArr = response.data.filter((item) => item.parentId === 100);
  53 + let arrNew = newArr.map((child) => {
  54 + return {
  55 + deptId: child.deptId.toString(),
  56 + deptName: child.deptName,
  57 + };
  58 + });
  59 + deptOptions.value.push(...arrNew);
  60 + });
  61 + };
  62 + return {
  63 + companyShow,
  64 + deptOptions,
  65 + companyForm,
  66 + sharingShow,
  67 + sharingMsg,
  68 + handleAuthCompany,
  69 + submitForm,
  70 + getDeptList,
  71 + }
  72 +}
@@ -84,6 +84,12 @@ @@ -84,6 +84,12 @@
84 align="center" 84 align="center"
85 /> 85 />
86 <el-table-column 86 <el-table-column
  87 + label="保险需求"
  88 + prop="requirements"
  89 + align="center"
  90 + width="150"
  91 + />
  92 + <el-table-column
87 label="作废时间" 93 label="作废时间"
88 align="center" 94 align="center"
89 prop="distributionTime" 95 prop="distributionTime"
@@ -96,6 +96,12 @@ @@ -96,6 +96,12 @@
96 align="center" 96 align="center"
97 /> 97 />
98 <el-table-column 98 <el-table-column
  99 + label="保险需求"
  100 + prop="requirements"
  101 + align="center"
  102 + width="150"
  103 + />
  104 + <el-table-column
99 label="分配机制" 105 label="分配机制"
100 width="120" 106 width="120"
101 prop="distributionMechanism" 107 prop="distributionMechanism"
@@ -128,6 +128,12 @@ @@ -128,6 +128,12 @@
128 align="center" 128 align="center"
129 /> 129 />
130 <el-table-column 130 <el-table-column
  131 + label="保险需求"
  132 + prop="requirements"
  133 + align="center"
  134 + width="150"
  135 + />
  136 + <el-table-column
131 label="分配机制" 137 label="分配机制"
132 width="120" 138 width="120"
133 prop="distributionMechanism" 139 prop="distributionMechanism"
@@ -94,6 +94,12 @@ @@ -94,6 +94,12 @@
94 align="center" 94 align="center"
95 /> 95 />
96 <el-table-column 96 <el-table-column
  97 + label="保险需求"
  98 + prop="requirements"
  99 + align="center"
  100 + width="150"
  101 + />
  102 + <el-table-column
97 label="统一信用代码" 103 label="统一信用代码"
98 prop="uniformCreditCode" 104 prop="uniformCreditCode"
99 width="180" 105 width="180"
@@ -619,123 +625,26 @@ import { @@ -619,123 +625,26 @@ import {
619 queryDefeatContent, 625 queryDefeatContent,
620 } from "@/api/policy/index"; 626 } from "@/api/policy/index";
621 import { checkRole } from "@/utils/permission"; // 权限判断函数 627 import { checkRole } from "@/utils/permission"; // 权限判断函数
622 -import { queryCarType } from "@/api/configurationCenter/carType.js";  
623 -import { queryCarNature } from "@/api/configurationCenter/carNature.js";  
624 -import { queryNeed } from "@/api/configurationCenter/need.js"; 628 +import useSelectData from "@/hooks/useSelectData.js";
625 import { listDept } from "@/api/system/dept"; 629 import { listDept } from "@/api/system/dept";
626 import { ref } from "vue"; 630 import { ref } from "vue";
627 const { proxy } = getCurrentInstance(); 631 const { proxy } = getCurrentInstance();
628 const loading = ref(false); 632 const loading = ref(false);
629 const activeTitle = ref(""); 633 const activeTitle = ref("");
630 -const loadingBtn = ref(false);  
631 -const showIssue = ref(false);  
632 -const total = ref(0);  
633 -const typeId = ref(0); // 判断类型 0 问题件 1 退回 2 作废  
634 -const transferTip = ref(""); //流转下一家名称  
635 -const transferDeptId = ref(""); // 流转的部门公司ID  
636 -const open = ref(false);  
637 -const form = ref({});  
638 -const timeFrame = ref(null);  
639 -const showFeedback = ref(false);  
640 -const transferShow = ref(false);  
641 -const transferForm = ref({});  
642 const taskId = ref(""); 634 const taskId = ref("");
643 -const issueReturenCompany = ref(""); // 问题件退回公司  
644 -const issueCompanyPerson = ref(""); // 问题件退回操作人员  
645 -const issueCompanyPersonPhone = ref(""); // 问题件退回操作人员联系电话  
646 -  
647 -const successShow = ref(false); // 通过备注显示变量  
648 -const successMsg = ref(""); // 通过备注  
649 -  
650 -const sharingShow = ref(false); // 分配备注显示变量  
651 -const sharingMsg = ref(""); // 分配备注  
652 -  
653 -const lookSuccessShow = ref(false); // 查看通过备注显示变量  
654 -const lookSuccessMsg = ref(""); // 查看通过备注  
655 -  
656 -const IssueForm = ref({  
657 - deprecatedReason: "",  
658 -});  
659 -const FeedbackForm = ref({  
660 - stronginsurancepolicynumber: "",  
661 - commercialinsurancepolicynumber: "",  
662 - message: "",  
663 -});  
664 -const getParams = reactive({  
665 - pageNum: 1,  
666 - pageSize: 100,  
667 -});  
668 -const companyShow = ref(false);  
669 -const deptOptions = ref([  
670 - {  
671 - deptId: "0",  
672 - deptName: "无",  
673 - },  
674 -]);  
675 -const transferOptions = ref([]);  
676 -const deprecatedShow = ref(false);  
677 -const deprecatedForm = ref({  
678 - deprecatedReason: "",  
679 - associationapprove: "",  
680 -});  
681 -const companyForm = ref({});  
682 -// 查询参数  
683 -const queryParams = reactive({  
684 - pageNum: 1,  
685 - pageSize: 10,  
686 - name: "",  
687 - licensePlate: "",  
688 - type: 1,  
689 - frameNumber: "",  
690 - startTime: "",  
691 - endTime: "",  
692 -});  
693 -const companyQueryParams = reactive({  
694 - deptName: undefined,  
695 - status: undefined,  
696 -});  
697 -const policyList = ref([]);  
698 635
699 // 判断是否有权限 636 // 判断是否有权限
700 const hasRole = computed(() => { 637 const hasRole = computed(() => {
701 return proxy.$auth.hasRole("associationemployee"); 638 return proxy.$auth.hasRole("associationemployee");
702 }); 639 });
703 640
704 -// 新能源  
705 -const NewEnergyOption = ref([  
706 - {  
707 - id: "0",  
708 - name: "否",  
709 - },  
710 - {  
711 - id: "1",  
712 - name: "是",  
713 - },  
714 -]);  
715 -  
716 -// 车辆类型  
717 -const carTypeOption = ref([]);  
718 -const getCarTypeOption = async () => {  
719 - const { data } = await queryCarType(getParams);  
720 - carTypeOption.value = data.records;  
721 -};  
722 -getCarTypeOption();  
723 -// 车辆使用性质  
724 -const carNatureOption = ref([]);  
725 -const getcarNatureOption = async () => {  
726 - const { data } = await queryCarNature(getParams);  
727 - carNatureOption.value = data.records;  
728 -};  
729 -getcarNatureOption();  
730 -  
731 -// 保险需求  
732 -const needOption = ref([]);  
733 -const getNeedOption = async () => {  
734 - const { data } = await queryNeed(getParams);  
735 - needOption.value = data.records;  
736 -};  
737 -getNeedOption(); 641 +// 获取选择数据列表
  642 +const { carNatureOption, needOption, NewEnergyOption } = useSelectData();
738 643
  644 +// table列表数据
  645 +const policyList = ref([]);
  646 +const total = ref(0);
  647 +// 获取待办数据
739 const getList = async () => { 648 const getList = async () => {
740 loading.value = true; 649 loading.value = true;
741 const { data } = await queryMyList(queryParams); 650 const { data } = await queryMyList(queryParams);
@@ -743,6 +652,32 @@ const getList = async () => { @@ -743,6 +652,32 @@ const getList = async () => {
743 total.value = data.total; 652 total.value = data.total;
744 loading.value = false; 653 loading.value = false;
745 }; 654 };
  655 +
  656 +const open = ref(false);
  657 +const form = ref({});
  658 +/** 修改按钮操作 */
  659 +const handleUpdate = async (row) => {
  660 + reset();
  661 + const { data } = await getCarDetail(row.businessKey);
  662 + getTransferTip();
  663 + form.value = data;
  664 + open.value = true;
  665 + taskId.value = row.taskId;
  666 +};
  667 +// 提交修改
  668 +const submitUpdate = () => {
  669 + updateCarInfo(form.value).then((response) => {
  670 + proxy.$modal.msgSuccess("修改成功");
  671 + getList();
  672 + });
  673 +};
  674 +/** 重置操作表单 */
  675 +function reset() {
  676 + proxy.resetForm("policyRef");
  677 +}
  678 +
  679 +// 回馈弹窗显示变量
  680 +const showFeedback = ref(false);
746 // 承接 681 // 承接
747 const handleContinue = (row) => { 682 const handleContinue = (row) => {
748 if (row.orderProgress === "待承接") { 683 if (row.orderProgress === "待承接") {
@@ -764,14 +699,33 @@ const handleContinue = (row) => { @@ -764,14 +699,33 @@ const handleContinue = (row) => {
764 showFeedback.value = true; 699 showFeedback.value = true;
765 } 700 }
766 }; 701 };
767 -// 问题件  
768 -const handleTroubleshooting = (taskId) => {  
769 - deprecatedForm.value.taskId = taskId;  
770 - activeTitle.value = "问题件退回至协会";  
771 - typeId.value = 0;  
772 - deprecatedShow.value = true; 702 +// 承接回馈内容表单
  703 +const FeedbackForm = ref({
  704 + stronginsurancepolicynumber: "", // 交强险
  705 + commercialinsurancepolicynumber: "", // 商业险
  706 + message: "", // 备注
  707 +});
  708 +// 提交承接回馈
  709 +const submit = () => {
  710 + const data = {
  711 + policystatus: "2",
  712 + message: FeedbackForm.value.message,
  713 + commercialinsurancepolicynumber:
  714 + FeedbackForm.value.commercialinsurancepolicynumber,
  715 + stronginsurancepolicynumber: FeedbackForm.value.stronginsurancepolicynumber,
  716 + };
  717 + disposeUser(data, FeedbackForm.value.taskId).then((res) => {
  718 + getList();
  719 + proxy.$modal.msgSuccess("回馈成功");
  720 + showFeedback.value = false;
  721 + });
773 }; 722 };
774 -// 通过保单 723 +
  724 +const successShow = ref(false); // 通过备注显示变量
  725 +const successMsg = ref(""); // 通过备注
  726 +const lookSuccessShow = ref(false); // 查看通过备注显示变量
  727 +const lookSuccessMsg = ref(""); // 查看通过备注
  728 +// 提交通过保单
775 const handleSuccess = async () => { 729 const handleSuccess = async () => {
776 await disposeUser( 730 await disposeUser(
777 { 731 {
@@ -787,6 +741,24 @@ const handleSuccess = async () => { @@ -787,6 +741,24 @@ const handleSuccess = async () => {
787 successShow.value = false; 741 successShow.value = false;
788 getList(); 742 getList();
789 }; 743 };
  744 +// 查阅通过备注
  745 +const lookRemark = async (row) => {
  746 + const { data } = await queryDefeatContent({
  747 + processInstanceId: row.processInstanceId,
  748 + type: 3,
  749 + });
  750 + lookSuccessMsg.value = data.message;
  751 + lookSuccessShow.value = true;
  752 +};
  753 +
  754 +const typeId = ref(0); // 判断类型 0 问题件 1 退回 2 作废
  755 +// 表单作废,退回。问题件对话框显示
  756 +const deprecatedShow = ref(false);
  757 +// 表单作废,退回。问题件对话框内容表单
  758 +const deprecatedForm = ref({
  759 + deprecatedReason: "",
  760 + associationapprove: "",
  761 +});
790 // 退回保单 762 // 退回保单
791 const handleFallback = (associationapprove) => { 763 const handleFallback = (associationapprove) => {
792 deprecatedForm.value = { 764 deprecatedForm.value = {
@@ -810,8 +782,21 @@ const handleVoid = (associationapprove, taskId) => { @@ -810,8 +782,21 @@ const handleVoid = (associationapprove, taskId) => {
810 "温馨提示:该保单作废后车牌号、车架号在本自然年度无法重新提交"; 782 "温馨提示:该保单作废后车牌号、车架号在本自然年度无法重新提交";
811 deprecatedShow.value = true; 783 deprecatedShow.value = true;
812 }; 784 };
813 -// 提交方法  
814 - 785 +const showIssue = ref(false); // 问题件原因显示变量
  786 +const issueReturenCompany = ref(""); // 问题件退回公司
  787 +const issueCompanyPerson = ref(""); // 问题件退回操作人员
  788 +const issueCompanyPersonPhone = ref(""); // 问题件退回操作人员手机号
  789 +// 问题件退回原因
  790 +const IssueForm = ref({
  791 + deprecatedReason: "",
  792 +});
  793 +// 问题件
  794 +const handleTroubleshooting = (taskId) => {
  795 + deprecatedForm.value.taskId = taskId;
  796 + activeTitle.value = "问题件退回至协会";
  797 + typeId.value = 0;
  798 + deprecatedShow.value = true;
  799 +};
815 // 查询问题件原因 800 // 查询问题件原因
816 const lookReason = async (row) => { 801 const lookReason = async (row) => {
817 const { data } = await queryDefeatContent({ 802 const { data } = await queryDefeatContent({
@@ -824,16 +809,6 @@ const lookReason = async (row) => { @@ -824,16 +809,6 @@ const lookReason = async (row) => {
824 issueCompanyPerson.value = row.companyEmployeeUserName; 809 issueCompanyPerson.value = row.companyEmployeeUserName;
825 issueCompanyPersonPhone.value = row.companyEmployeePhone; 810 issueCompanyPersonPhone.value = row.companyEmployeePhone;
826 }; 811 };
827 -  
828 -// 查阅通过备注  
829 -const lookRemark = async (row) => {  
830 - const { data } = await queryDefeatContent({  
831 - processInstanceId: row.processInstanceId,  
832 - type: 3,  
833 - });  
834 - lookSuccessMsg.value = data.message;  
835 - lookSuccessShow.value = true;  
836 -};  
837 // 提交作废,退回,问题件表单 812 // 提交作废,退回,问题件表单
838 const sunmitDeprecated = () => { 813 const sunmitDeprecated = () => {
839 let data = {}; 814 let data = {};
@@ -849,6 +824,7 @@ const sunmitDeprecated = () => { @@ -849,6 +824,7 @@ const sunmitDeprecated = () => {
849 }; 824 };
850 } 825 }
851 const taskId = deprecatedForm.value.taskId; 826 const taskId = deprecatedForm.value.taskId;
  827 + // 办理一个业务
852 disposeUser(data, taskId).then((res) => { 828 disposeUser(data, taskId).then((res) => {
853 getList(); 829 getList();
854 open.value = false; 830 open.value = false;
@@ -856,15 +832,11 @@ const sunmitDeprecated = () => { @@ -856,15 +832,11 @@ const sunmitDeprecated = () => {
856 proxy.$modal.msgSuccess("操作成功"); 832 proxy.$modal.msgSuccess("操作成功");
857 }); 833 });
858 }; 834 };
859 -// 分配承保公司  
860 -const handleAuthCompany = (associationapprove, taskId) => {  
861 - companyForm.value = {  
862 - associationapprove,  
863 - taskId: taskId,  
864 - };  
865 - companyShow.value = true;  
866 -};  
867 835
  836 +const transferShow = ref(false); // 转办弹窗显示变量
  837 +const transferForm = ref({}); // 转办分配表单数据
  838 +// 转办,分配人员列表数据
  839 +const transferOptions = ref([]);
868 // 获取人员列表 840 // 获取人员列表
869 const getUser = async () => { 841 const getUser = async () => {
870 const { data } = await getUserList(); 842 const { data } = await getUserList();
@@ -876,33 +848,44 @@ const handleSharing = (id) => { @@ -876,33 +848,44 @@ const handleSharing = (id) => {
876 getUser(); 848 getUser();
877 transferShow.value = true; 849 transferShow.value = true;
878 }; 850 };
879 -/** 查询部门列表 */  
880 -const getDeptList = () => {  
881 - listDept(companyQueryParams).then((response) => {  
882 - let newArr = [];  
883 - newArr = response.data.filter((item) => item.parentId === 100);  
884 - let arrNew = newArr.map((child) => {  
885 - return {  
886 - deptId: child.deptId.toString(),  
887 - deptName: child.deptName,  
888 - };  
889 - });  
890 - deptOptions.value.push(...arrNew); 851 +/** 提交通过分配转办人员 */
  852 +function submitTransfer() {
  853 + const data = {
  854 + username: transferForm.value.username,
  855 + };
  856 + const taskId = transferForm.value.taskId;
  857 + transfer(data, taskId).then((res) => {
  858 + transferShow.value = false;
  859 + getList();
  860 + proxy.$modal.msgSuccess("保单已分配成功");
891 }); 861 });
892 -};  
893 -/** 重置操作表单 */  
894 -function reset() {  
895 - proxy.resetForm("policyRef");  
896 } 862 }
897 863
898 -/** 修改按钮操作 */  
899 -const handleUpdate = async (row) => {  
900 - reset();  
901 - const { data } = await getCarDetail(row.businessKey);  
902 - getTransferTip();  
903 - form.value = data;  
904 - open.value = true;  
905 - taskId.value = row.taskId; 864 +// 分配承保公司弹窗显示
  865 +const companyShow = ref(false);
  866 +// 分配承保公司查询参数
  867 +const companyQueryParams = reactive({
  868 + deptName: undefined,
  869 + status: undefined,
  870 +});
  871 +// 分配承保公司列表数据
  872 +const deptOptions = ref([
  873 + {
  874 + deptId: "0",
  875 + deptName: "无",
  876 + },
  877 +]);
  878 +// 确认选择的承保公司数据表单
  879 +const companyForm = ref({});
  880 +const sharingShow = ref(false); // 分配备注显示变量
  881 +const sharingMsg = ref(""); // 分配备注
  882 +// 分配承保公司
  883 +const handleAuthCompany = (associationapprove, taskId) => {
  884 + companyForm.value = {
  885 + associationapprove,
  886 + taskId: taskId,
  887 + };
  888 + companyShow.value = true;
906 }; 889 };
907 /** 提交通过分配承保公司 */ 890 /** 提交通过分配承保公司 */
908 function submitForm() { 891 function submitForm() {
@@ -920,53 +903,40 @@ function submitForm() { @@ -920,53 +903,40 @@ function submitForm() {
920 proxy.$modal.msgSuccess("保单已分配成功"); 903 proxy.$modal.msgSuccess("保单已分配成功");
921 }); 904 });
922 } 905 }
923 -  
924 -/** 提交通过分配转办人员 */  
925 -function submitTransfer() {  
926 - const data = {  
927 - username: transferForm.value.username,  
928 - };  
929 - const taskId = transferForm.value.taskId;  
930 - transfer(data, taskId).then((res) => {  
931 - transferShow.value = false;  
932 - getList();  
933 - proxy.$modal.msgSuccess("保单已分配成功");  
934 - });  
935 -}  
936 -  
937 -// 提交承接回馈  
938 -const submit = () => {  
939 - const data = {  
940 - policystatus: "2",  
941 - message: FeedbackForm.value.message,  
942 - commercialinsurancepolicynumber:  
943 - FeedbackForm.value.commercialinsurancepolicynumber,  
944 - stronginsurancepolicynumber: FeedbackForm.value.stronginsurancepolicynumber,  
945 - };  
946 - disposeUser(data, FeedbackForm.value.taskId).then((res) => {  
947 - getList();  
948 - proxy.$modal.msgSuccess("回馈成功");  
949 - showFeedback.value = false; 906 +/** 查询承保公司列表 */
  907 +const getDeptList = () => {
  908 + listDept(companyQueryParams).then((response) => {
  909 + let newArr = [];
  910 + newArr = response.data.filter((item) => item.parentId === 100);
  911 + let arrNew = newArr.map((child) => {
  912 + return {
  913 + deptId: child.deptId.toString(),
  914 + deptName: child.deptName,
  915 + };
  916 + });
  917 + deptOptions.value.push(...arrNew);
950 }); 918 });
951 }; 919 };
952 920
  921 +const loadingBtn = ref(false); // 刷新流转公司加载按钮
  922 +const transferTip = ref(""); //流转下一家名称
  923 +const transferDeptId = ref(""); // 流转的部门公司ID
953 // 获取流转下一家分配公司 924 // 获取流转下一家分配公司
954 -const getTransferTip = async () => {  
955 - loadingBtn.value = true;  
956 - const { data } = await getCompanyTip();  
957 - transferTip.value = data.deptName;  
958 - transferDeptId.value = data.deptId.toString();  
959 - loadingBtn.value = false;  
960 -};  
961 -  
962 -// 提交修改  
963 -const submitUpdate = () => {  
964 - updateCarInfo(form.value).then((response) => {  
965 - proxy.$modal.msgSuccess("修改成功");  
966 - getList();  
967 - }); 925 +const getTransferTip = async (timers) => {
  926 + if (!loadingBtn.value) {
  927 + loadingBtn.value = true;
  928 + const { data } = await getCompanyTip();
  929 + let timer = setTimeout(() => {
  930 + transferTip.value = data.deptName;
  931 + transferDeptId.value = data.deptId.toString();
  932 + loadingBtn.value = false;
  933 + clearTimeout(timer);
  934 + }, timers);
  935 + }
968 }; 936 };
969 937
  938 +// 筛选时间范围
  939 +const timeFrame = ref(null);
970 // 选择时间范围 940 // 选择时间范围
971 const handleTime = (valu) => { 941 const handleTime = (valu) => {
972 if (valu !== null) { 942 if (valu !== null) {
@@ -977,7 +947,17 @@ const handleTime = (valu) => { @@ -977,7 +947,17 @@ const handleTime = (valu) => {
977 queryParams.endTime = ""; 947 queryParams.endTime = "";
978 } 948 }
979 }; 949 };
980 - 950 +// 查询参数
  951 +const queryParams = reactive({
  952 + pageNum: 1,
  953 + pageSize: 10,
  954 + name: "",
  955 + licensePlate: "",
  956 + type: 1,
  957 + frameNumber: "",
  958 + startTime: "",
  959 + endTime: "",
  960 +});
981 /** 搜索按钮操作 */ 961 /** 搜索按钮操作 */
982 function handleQuery() { 962 function handleQuery() {
983 queryParams.pageNum = 1; 963 queryParams.pageNum = 1;
@@ -138,6 +138,12 @@ @@ -138,6 +138,12 @@
138 align="center" 138 align="center"
139 /> 139 />
140 <el-table-column 140 <el-table-column
  141 + label="保险需求"
  142 + prop="requirements"
  143 + align="center"
  144 + width="150"
  145 + />
  146 + <el-table-column
141 label="联系电话" 147 label="联系电话"
142 prop="businessPhone" 148 prop="businessPhone"
143 width="150" 149 width="150"
@@ -78,6 +78,12 @@ @@ -78,6 +78,12 @@
78 align="center" 78 align="center"
79 /> 79 />
80 <el-table-column 80 <el-table-column
  81 + label="保险需求"
  82 + prop="requirements"
  83 + align="center"
  84 + width="150"
  85 + />
  86 + <el-table-column
81 label="作废时间" 87 label="作废时间"
82 align="center" 88 align="center"
83 prop="distributionTime" 89 prop="distributionTime"
@@ -65,31 +65,73 @@ @@ -65,31 +65,73 @@
65 <span>{{ row.initialRegistration || row.createTime }}</span> 65 <span>{{ row.initialRegistration || row.createTime }}</span>
66 </template> 66 </template>
67 </el-table-column> 67 </el-table-column>
68 - <el-table-column label="车牌号" prop="licensePlateNumber" width="150" />  
69 - <el-table-column label="车架号" prop="frameNumber" width="240" />  
70 - <el-table-column label="车主姓名" prop="name" width="100" />  
71 - <el-table-column label="联系电话" prop="phone" width="180" /> 68 + <el-table-column
  69 + label="车牌号"
  70 + align="center"
  71 + prop="licensePlateNumber"
  72 + width="150"
  73 + />
  74 + <el-table-column
  75 + label="车架号"
  76 + align="center"
  77 + prop="frameNumber"
  78 + width="240"
  79 + />
  80 + <el-table-column
  81 + label="车主姓名"
  82 + align="center"
  83 + prop="name"
  84 + width="100"
  85 + />
  86 + <el-table-column
  87 + label="联系电话"
  88 + align="center"
  89 + prop="phone"
  90 + width="180"
  91 + />
  92 + <el-table-column
  93 + label="保险需求"
  94 + prop="requirements"
  95 + align="center"
  96 + width="150"
  97 + />
72 <el-table-column 98 <el-table-column
73 label="分配机制" 99 label="分配机制"
74 width="120" 100 width="120"
  101 + align="center"
75 prop="distributionMechanism" 102 prop="distributionMechanism"
76 /> 103 />
77 - <el-table-column label="承保公司" prop="companyName" width="150" />  
78 - <el-table-column label="操作人员" width="150"> 104 + <el-table-column
  105 + label="承保公司"
  106 + align="center"
  107 + prop="companyName"
  108 + width="150"
  109 + />
  110 + <el-table-column label="操作人员" align="center" width="150">
79 <template #default="{ row }"> 111 <template #default="{ row }">
80 <span>{{ 112 <span>{{
81 row.associationEmployeeUserName || row.companyEmployeeUserName 113 row.associationEmployeeUserName || row.companyEmployeeUserName
82 }}</span> 114 }}</span>
83 </template> 115 </template>
84 </el-table-column> 116 </el-table-column>
85 - <el-table-column label="办结时间" prop="policyTime" width="160" /> 117 + <el-table-column
  118 + label="办结时间"
  119 + align="center"
  120 + prop="policyTime"
  121 + width="160"
  122 + />
86 <el-table-column 123 <el-table-column
87 label="办理人" 124 label="办理人"
88 prop="companyEmployeeUserName" 125 prop="companyEmployeeUserName"
89 width="150" 126 width="150"
90 align="center" 127 align="center"
91 /> 128 />
92 - <el-table-column label="保单状态" width="100" prop="statue"> 129 + <el-table-column
  130 + label="保单状态"
  131 + align="center"
  132 + width="100"
  133 + prop="statue"
  134 + >
93 <template #default="{ row }"> 135 <template #default="{ row }">
94 <span 136 <span
95 :style="{ color: row.status === '进行中' ? '#409EFF' : '#67C23A' }" 137 :style="{ color: row.status === '进行中' ? '#409EFF' : '#67C23A' }"
@@ -99,6 +141,7 @@ @@ -99,6 +141,7 @@
99 </el-table-column> 141 </el-table-column>
100 <el-table-column 142 <el-table-column
101 label="保单回馈" 143 label="保单回馈"
  144 + align="center"
102 fixed="right" 145 fixed="right"
103 width="100" 146 width="100"
104 show-overflow-tooltip 147 show-overflow-tooltip
@@ -112,6 +112,12 @@ @@ -112,6 +112,12 @@
112 prop="distributionMechanism" 112 prop="distributionMechanism"
113 /> 113 />
114 <el-table-column 114 <el-table-column
  115 + label="保险需求"
  116 + prop="requirements"
  117 + align="center"
  118 + width="150"
  119 + />
  120 + <el-table-column
115 label="承保公司" 121 label="承保公司"
116 prop="companyName" 122 prop="companyName"
117 width="180" 123 width="180"
@@ -94,6 +94,12 @@ @@ -94,6 +94,12 @@
94 align="center" 94 align="center"
95 /> 95 />
96 <el-table-column 96 <el-table-column
  97 + label="保险需求"
  98 + prop="requirements"
  99 + align="center"
  100 + width="150"
  101 + />
  102 + <el-table-column
97 label="联系电话" 103 label="联系电话"
98 prop="phone" 104 prop="phone"
99 width="150" 105 width="150"
@@ -534,7 +540,7 @@ @@ -534,7 +540,7 @@
534 <!-- 流转提示 --> 540 <!-- 流转提示 -->
535 <div class="transferTip"> 541 <div class="transferTip">
536 <span>自动订单流转:{{ transferTip }}</span> 542 <span>自动订单流转:{{ transferTip }}</span>
537 - <el-button :loading="loadingBtn" @click="getTransferTip" 543 + <el-button :loading="loadingBtn" @click="getTransferTip(1000)"
538 >刷新</el-button 544 >刷新</el-button
539 > 545 >
540 </div> 546 </div>
@@ -598,132 +604,50 @@ import { @@ -598,132 +604,50 @@ import {
598 queryDefeatContent, 604 queryDefeatContent,
599 } from "@/api/policy/index"; 605 } from "@/api/policy/index";
600 import { checkRole } from "@/utils/permission"; // 权限判断函数 606 import { checkRole } from "@/utils/permission"; // 权限判断函数
601 -import { queryCarType } from "@/api/configurationCenter/carType.js";  
602 -import { queryCarNature } from "@/api/configurationCenter/carNature.js";  
603 -import { queryNeed } from "@/api/configurationCenter/need.js"; 607 +import useSelectData from "@/hooks/useSelectData.js";
604 import { listDept } from "@/api/system/dept"; 608 import { listDept } from "@/api/system/dept";
605 import { ref } from "vue"; 609 import { ref } from "vue";
606 const { proxy } = getCurrentInstance(); 610 const { proxy } = getCurrentInstance();
607 -const loading = ref(false);  
608 -const activeTitle = ref("");  
609 -const loadingBtn = ref(false);  
610 -const showIssue = ref(false); // 问题件显示变量  
611 -const total = ref(0);  
612 -const timeFrame = ref(null);  
613 -const typeId = ref(0); // 判断类型 0 问题件 1 退回 2 作废  
614 -const transferTip = ref(""); //流转下一家名称  
615 -const transferDeptId = ref(""); // 流转的部门公司ID  
616 -const open = ref(false);  
617 -const form = ref({});  
618 -const showFeedback = ref(false); // 回馈显示变量  
619 -const transferShow = ref(false); // 转办显示变量  
620 -const transferForm = ref({});  
621 -const taskId = ref(""); 611 +const activeTitle = ref(""); // 弹窗标题
  612 +const taskId = ref(""); // 任务ID
622 613
623 -const successShow = ref(false); // 通过备注显示变量  
624 -const successMsg = ref(""); // 通过备注  
625 -  
626 -const sharingShow = ref(false); // 分配备注显示变量  
627 -const sharingMsg = ref(""); // 分配备注  
628 -  
629 -const lookSuccessShow = ref(false); // 查看通过备注显示变量  
630 -const lookSuccessMsg = ref(""); // 查看通过备注  
631 -  
632 -const issueReturenCompany = ref(""); // 问题件退回公司  
633 -const issueCompanyPerson = ref(""); // 问题件退回操作人员  
634 -const issueCompanyPersonPhone = ref(""); 614 +const open = ref(false); // 编辑弹窗显示变量
  615 +const form = ref({}); // 编辑表单数据
  616 +/** 修改按钮操作 */
  617 +const handleUpdate = async (row) => {
  618 + reset();
  619 + const { data } = await getCarDetail(row.businessKey);
  620 + getTransferTip(0);
  621 + form.value = data;
  622 + open.value = true;
  623 + taskId.value = row.taskId;
  624 +};
  625 +// 提交修改
  626 +const submitUpdate = () => {
  627 + updateCarInfo(form.value).then((response) => {
  628 + proxy.$modal.msgSuccess("修改成功");
  629 + getList();
  630 + });
  631 +};
  632 +/** 重置操作表单 */
  633 +function reset() {
  634 + proxy.resetForm("policyRef");
  635 +}
635 636
636 -const IssueForm = ref({  
637 - deprecatedReason: "",  
638 -});  
639 -const FeedbackForm = ref({  
640 - stronginsurancepolicynumber: "",  
641 - commercialinsurancepolicynumber: "",  
642 - message: "",  
643 -});  
644 -const getParams = reactive({  
645 - pageNum: 1,  
646 - pageSize: 100,  
647 -});  
648 -const companyShow = ref(false);  
649 -const deptOptions = ref([  
650 - {  
651 - deptId: "0",  
652 - deptName: "无",  
653 - },  
654 -]);  
655 -const transferOptions = ref([]);  
656 -const deprecatedShow = ref(false);  
657 -const deprecatedForm = ref({  
658 - deprecatedReason: "",  
659 - associationapprove: "",  
660 -});  
661 -const companyForm = ref({});  
662 -// 查询参数  
663 -const queryParams = reactive({  
664 - pageNum: 1,  
665 - pageSize: 10,  
666 - name: "",  
667 - licensePlate: "",  
668 - type: 0,  
669 - frameNumber: "",  
670 - startTime: "",  
671 - endTime: "",  
672 -});  
673 -const companyQueryParams = reactive({  
674 - deptName: undefined,  
675 - status: undefined,  
676 -});  
677 -const policyList = ref([]);  
678 // 判断是否有权限 637 // 判断是否有权限
679 const hasRole = computed(() => { 638 const hasRole = computed(() => {
680 return proxy.$auth.hasRole("associationemployee"); 639 return proxy.$auth.hasRole("associationemployee");
681 }); 640 });
682 641
683 -// 新能源  
684 -const NewEnergyOption = ref([  
685 - {  
686 - id: "0",  
687 - name: "否",  
688 - },  
689 - {  
690 - id: "1",  
691 - name: "是",  
692 - },  
693 -]);  
694 -// 选择时间范围  
695 -const handleTime = (valu) => {  
696 - if (valu !== null) {  
697 - queryParams.startTime = proxy.parseTime(valu[0]);  
698 - queryParams.endTime = proxy.parseTime(valu[1]);  
699 - } else {  
700 - queryParams.startTime = "";  
701 - queryParams.endTime = "";  
702 - }  
703 -};  
704 -// 车辆类型  
705 -const carTypeOption = ref([]);  
706 -const getCarTypeOption = async () => {  
707 - const { data } = await queryCarType(getParams);  
708 - carTypeOption.value = data.records;  
709 -};  
710 -getCarTypeOption();  
711 -// 车辆使用性质  
712 -const carNatureOption = ref([]);  
713 -const getcarNatureOption = async () => {  
714 - const { data } = await queryCarNature(getParams);  
715 - carNatureOption.value = data.records;  
716 -};  
717 -getcarNatureOption();  
718 -  
719 -// 保险需求  
720 -const needOption = ref([]);  
721 -const getNeedOption = async () => {  
722 - const { data } = await queryNeed(getParams);  
723 - needOption.value = data.records;  
724 -};  
725 -getNeedOption(); 642 +// 获取选择数据列表
  643 +const { carNatureOption, needOption, NewEnergyOption } = useSelectData();
726 644
  645 +// table数据列表
  646 +const policyList = ref([]);
  647 +const total = ref(0); // 总条数
  648 +// table加载动画
  649 +const loading = ref(false);
  650 +// 获取待办列表
727 const getList = async () => { 651 const getList = async () => {
728 loading.value = true; 652 loading.value = true;
729 const { data } = await queryMyList(queryParams); 653 const { data } = await queryMyList(queryParams);
@@ -731,6 +655,9 @@ const getList = async () => { @@ -731,6 +655,9 @@ const getList = async () => {
731 total.value = data.total; 655 total.value = data.total;
732 loading.value = false; 656 loading.value = false;
733 }; 657 };
  658 +
  659 +// 回馈弹窗显示变量
  660 +const showFeedback = ref(false);
734 // 承接 661 // 承接
735 const handleContinue = (row) => { 662 const handleContinue = (row) => {
736 if (row.orderProgress === "待承接") { 663 if (row.orderProgress === "待承接") {
@@ -752,13 +679,32 @@ const handleContinue = (row) => { @@ -752,13 +679,32 @@ const handleContinue = (row) => {
752 showFeedback.value = true; 679 showFeedback.value = true;
753 } 680 }
754 }; 681 };
755 -// 问题件  
756 -const handleTroubleshooting = (taskId) => {  
757 - deprecatedForm.value.taskId = taskId;  
758 - activeTitle.value = "问题件退回至协会";  
759 - typeId.value = 0;  
760 - deprecatedShow.value = true; 682 +// 承接回馈内容表单
  683 +const FeedbackForm = ref({
  684 + stronginsurancepolicynumber: "", // 交强险
  685 + commercialinsurancepolicynumber: "", // 商业险
  686 + message: "", // 备注
  687 +});
  688 +// 提交承接回馈
  689 +const submit = () => {
  690 + const data = {
  691 + policystatus: "2",
  692 + message: FeedbackForm.value.message,
  693 + commercialinsurancepolicynumber:
  694 + FeedbackForm.value.commercialinsurancepolicynumber,
  695 + stronginsurancepolicynumber: FeedbackForm.value.stronginsurancepolicynumber,
  696 + };
  697 + disposeUser(data, FeedbackForm.value.taskId).then((res) => {
  698 + getList();
  699 + proxy.$modal.msgSuccess("回馈成功");
  700 + showFeedback.value = false;
  701 + });
761 }; 702 };
  703 +
  704 +const successShow = ref(false); // 通过备注显示变量
  705 +const successMsg = ref(""); // 通过备注
  706 +const lookSuccessShow = ref(false); // 查看通过备注显示变量
  707 +const lookSuccessMsg = ref(""); // 查看通过备注
762 // 提交通过保单 708 // 提交通过保单
763 const handleSuccess = async () => { 709 const handleSuccess = async () => {
764 await disposeUser( 710 await disposeUser(
@@ -775,6 +721,24 @@ const handleSuccess = async () => { @@ -775,6 +721,24 @@ const handleSuccess = async () => {
775 successShow.value = false; 721 successShow.value = false;
776 getList(); 722 getList();
777 }; 723 };
  724 +// 查阅通过备注
  725 +const lookRemark = async (row) => {
  726 + const { data } = await queryDefeatContent({
  727 + processInstanceId: row.processInstanceId,
  728 + type: 3,
  729 + });
  730 + lookSuccessMsg.value = data.message;
  731 + lookSuccessShow.value = true;
  732 +};
  733 +
  734 +const typeId = ref(0); // 判断类型 0 问题件 1 退回 2 作废
  735 +// 表单作废,退回。问题件对话框显示
  736 +const deprecatedShow = ref(false);
  737 +// 表单作废,退回。问题件对话框内容表单
  738 +const deprecatedForm = ref({
  739 + deprecatedReason: "",
  740 + associationapprove: "",
  741 +});
778 // 退回保单 742 // 退回保单
779 const handleFallback = (associationapprove) => { 743 const handleFallback = (associationapprove) => {
780 deprecatedForm.value = { 744 deprecatedForm.value = {
@@ -798,8 +762,21 @@ const handleVoid = (associationapprove, taskId) => { @@ -798,8 +762,21 @@ const handleVoid = (associationapprove, taskId) => {
798 "温馨提示:该保单作废后车牌号、车架号在本自然年度无法重新提交"; 762 "温馨提示:该保单作废后车牌号、车架号在本自然年度无法重新提交";
799 deprecatedShow.value = true; 763 deprecatedShow.value = true;
800 }; 764 };
801 -// 提交方法  
802 - 765 +const showIssue = ref(false); // 问题件原因显示变量
  766 +const issueReturenCompany = ref(""); // 问题件退回公司
  767 +const issueCompanyPerson = ref(""); // 问题件退回操作人员
  768 +const issueCompanyPersonPhone = ref(""); // 问题件退回操作人员手机号
  769 +// 问题件退回原因
  770 +const IssueForm = ref({
  771 + deprecatedReason: "",
  772 +});
  773 +// 问题件
  774 +const handleTroubleshooting = (taskId) => {
  775 + deprecatedForm.value.taskId = taskId;
  776 + activeTitle.value = "问题件退回至协会";
  777 + typeId.value = 0;
  778 + deprecatedShow.value = true;
  779 +};
803 // 查询问题件原因 780 // 查询问题件原因
804 const lookReason = async (row) => { 781 const lookReason = async (row) => {
805 const { data } = await queryDefeatContent({ 782 const { data } = await queryDefeatContent({
@@ -812,17 +789,6 @@ const lookReason = async (row) => { @@ -812,17 +789,6 @@ const lookReason = async (row) => {
812 issueCompanyPerson.value = row.companyEmployeeUserName; 789 issueCompanyPerson.value = row.companyEmployeeUserName;
813 issueCompanyPersonPhone.value = row.companyEmployeePhone; 790 issueCompanyPersonPhone.value = row.companyEmployeePhone;
814 }; 791 };
815 -  
816 -// 查阅通过备注  
817 -const lookRemark = async (row) => {  
818 - const { data } = await queryDefeatContent({  
819 - processInstanceId: row.processInstanceId,  
820 - type: 3,  
821 - });  
822 - lookSuccessMsg.value = data.message;  
823 - lookSuccessShow.value = true;  
824 -};  
825 -  
826 // 提交作废,退回,问题件表单 792 // 提交作废,退回,问题件表单
827 const sunmitDeprecated = () => { 793 const sunmitDeprecated = () => {
828 let data = {}; 794 let data = {};
@@ -838,6 +804,7 @@ const sunmitDeprecated = () => { @@ -838,6 +804,7 @@ const sunmitDeprecated = () => {
838 }; 804 };
839 } 805 }
840 const taskId = deprecatedForm.value.taskId; 806 const taskId = deprecatedForm.value.taskId;
  807 + // 办理一个业务
841 disposeUser(data, taskId).then((res) => { 808 disposeUser(data, taskId).then((res) => {
842 getList(); 809 getList();
843 open.value = false; 810 open.value = false;
@@ -846,15 +813,10 @@ const sunmitDeprecated = () => { @@ -846,15 +813,10 @@ const sunmitDeprecated = () => {
846 }); 813 });
847 }; 814 };
848 815
849 -// 分配承保公司  
850 -const handleAuthCompany = (associationapprove, taskId) => {  
851 - companyForm.value = {  
852 - associationapprove,  
853 - taskId: taskId,  
854 - };  
855 - companyShow.value = true;  
856 -};  
857 - 816 +const transferShow = ref(false); // 转办弹窗显示变量
  817 +const transferForm = ref({}); // 转办分配表单数据
  818 +// 转办,分配人员列表数据
  819 +const transferOptions = ref([]);
858 // 获取人员列表 820 // 获取人员列表
859 const getUser = async () => { 821 const getUser = async () => {
860 const { data } = await getUserList(); 822 const { data } = await getUserList();
@@ -866,33 +828,44 @@ const handleSharing = (id) => { @@ -866,33 +828,44 @@ const handleSharing = (id) => {
866 getUser(); 828 getUser();
867 transferShow.value = true; 829 transferShow.value = true;
868 }; 830 };
869 -/** 查询部门列表 */  
870 -const getDeptList = () => {  
871 - listDept(companyQueryParams).then((response) => {  
872 - let newArr = [];  
873 - newArr = response.data.filter((item) => item.parentId === 100);  
874 - let arrNew = newArr.map((child) => {  
875 - return {  
876 - deptId: child.deptId.toString(),  
877 - deptName: child.deptName,  
878 - };  
879 - });  
880 - deptOptions.value.push(...arrNew); 831 +/** 提交通过分配转办人员 */
  832 +function submitTransfer() {
  833 + const data = {
  834 + username: transferForm.value.username,
  835 + };
  836 + const taskId = transferForm.value.taskId;
  837 + transfer(data, taskId).then((res) => {
  838 + transferShow.value = false;
  839 + getList();
  840 + proxy.$modal.msgSuccess("保单已分配成功");
881 }); 841 });
882 -};  
883 -/** 重置操作表单 */  
884 -function reset() {  
885 - proxy.resetForm("policyRef");  
886 } 842 }
887 843
888 -/** 修改按钮操作 */  
889 -const handleUpdate = async (row) => {  
890 - reset();  
891 - const { data } = await getCarDetail(row.businessKey);  
892 - getTransferTip();  
893 - form.value = data;  
894 - open.value = true;  
895 - taskId.value = row.taskId; 844 +// 分配承保公司弹窗显示
  845 +const companyShow = ref(false);
  846 +// 分配承保公司查询参数
  847 +const companyQueryParams = reactive({
  848 + deptName: undefined,
  849 + status: undefined,
  850 +});
  851 +// 分配承保公司列表数据
  852 +const deptOptions = ref([
  853 + {
  854 + deptId: "0",
  855 + deptName: "无",
  856 + },
  857 +]);
  858 +// 确认选择的承保公司数据表单
  859 +const companyForm = ref({});
  860 +const sharingShow = ref(false); // 分配备注显示变量
  861 +const sharingMsg = ref(""); // 分配备注
  862 +// 分配承保公司
  863 +const handleAuthCompany = (associationapprove, taskId) => {
  864 + companyForm.value = {
  865 + associationapprove,
  866 + taskId: taskId,
  867 + };
  868 + companyShow.value = true;
896 }; 869 };
897 /** 提交通过分配承保公司 */ 870 /** 提交通过分配承保公司 */
898 function submitForm() { 871 function submitForm() {
@@ -910,52 +883,61 @@ function submitForm() { @@ -910,52 +883,61 @@ function submitForm() {
910 proxy.$modal.msgSuccess("保单已分配成功"); 883 proxy.$modal.msgSuccess("保单已分配成功");
911 }); 884 });
912 } 885 }
913 -  
914 -/** 提交通过分配转办人员 */  
915 -function submitTransfer() {  
916 - const data = {  
917 - username: transferForm.value.username,  
918 - };  
919 - const taskId = transferForm.value.taskId;  
920 - transfer(data, taskId).then((res) => {  
921 - transferShow.value = false;  
922 - getList();  
923 - proxy.$modal.msgSuccess("保单已分配成功");  
924 - });  
925 -}  
926 -  
927 -// 提交承接回馈  
928 -const submit = () => {  
929 - const data = {  
930 - policystatus: "2",  
931 - message: FeedbackForm.value.message,  
932 - commercialinsurancepolicynumber:  
933 - FeedbackForm.value.commercialinsurancepolicynumber,  
934 - stronginsurancepolicynumber: FeedbackForm.value.stronginsurancepolicynumber,  
935 - };  
936 - disposeUser(data, FeedbackForm.value.taskId).then((res) => {  
937 - getList();  
938 - proxy.$modal.msgSuccess("回馈成功");  
939 - showFeedback.value = false; 886 +/** 查询承保公司列表 */
  887 +const getDeptList = () => {
  888 + listDept(companyQueryParams).then((response) => {
  889 + let newArr = [];
  890 + newArr = response.data.filter((item) => item.parentId === 100);
  891 + let arrNew = newArr.map((child) => {
  892 + return {
  893 + deptId: child.deptId.toString(),
  894 + deptName: child.deptName,
  895 + };
  896 + });
  897 + deptOptions.value.push(...arrNew);
940 }); 898 });
941 }; 899 };
942 900
  901 +const loadingBtn = ref(false); // 刷新流转公司加载按钮
  902 +const transferTip = ref(""); //流转下一家名称
  903 +const transferDeptId = ref(""); // 流转的部门公司ID
943 // 获取流转下一家分配公司 904 // 获取流转下一家分配公司
944 -const getTransferTip = async () => {  
945 - loadingBtn.value = true;  
946 - const { data } = await getCompanyTip();  
947 - transferTip.value = data.deptName;  
948 - transferDeptId.value = data.deptId.toString();  
949 - loadingBtn.value = false;  
950 -};  
951 -// 提交修改  
952 -const submitUpdate = () => {  
953 - updateCarInfo(form.value).then((response) => {  
954 - proxy.$modal.msgSuccess("修改成功");  
955 - getList();  
956 - }); 905 +const getTransferTip = async (timers) => {
  906 + if (!loadingBtn.value) {
  907 + loadingBtn.value = true;
  908 + const { data } = await getCompanyTip();
  909 + let timer = setTimeout(() => {
  910 + transferTip.value = data.deptName;
  911 + transferDeptId.value = data.deptId.toString();
  912 + loadingBtn.value = false;
  913 + clearTimeout(timer);
  914 + }, timers);
  915 + }
957 }; 916 };
958 917
  918 +// 筛选时间范围
  919 +const timeFrame = ref(null);
  920 +// 选择时间范围
  921 +const handleTime = (valu) => {
  922 + if (valu !== null) {
  923 + queryParams.startTime = proxy.parseTime(valu[0]);
  924 + queryParams.endTime = proxy.parseTime(valu[1]);
  925 + } else {
  926 + queryParams.startTime = "";
  927 + queryParams.endTime = "";
  928 + }
  929 +};
  930 +// 查询参数
  931 +const queryParams = reactive({
  932 + pageNum: 1,
  933 + pageSize: 10,
  934 + name: "",
  935 + licensePlate: "",
  936 + type: 0,
  937 + frameNumber: "",
  938 + startTime: "",
  939 + endTime: "",
  940 +});
959 /** 搜索按钮操作 */ 941 /** 搜索按钮操作 */
960 function handleQuery() { 942 function handleQuery() {
961 queryParams.pageNum = 1; 943 queryParams.pageNum = 1;
@@ -973,6 +955,7 @@ onMounted(() => { @@ -973,6 +955,7 @@ onMounted(() => {
973 getList(); 955 getList();
974 }); 956 });
975 957
  958 +// 判断是否为协会员工,协会员工可分配承保公司
976 if (checkRole(["associationemployee"])) { 959 if (checkRole(["associationemployee"])) {
977 getDeptList(); 960 getDeptList();
978 } 961 }
@@ -107,26 +107,63 @@ @@ -107,26 +107,63 @@
107 <!-- 表格数据 --> 107 <!-- 表格数据 -->
108 <el-table v-loading="loading" :data="policyList" @row-click="handleUpdate"> 108 <el-table v-loading="loading" :data="policyList" @row-click="handleUpdate">
109 <el-table-column label="序号" type="index" width="55" /> 109 <el-table-column label="序号" type="index" width="55" />
110 - <el-table-column label="登记时间" prop="createTime" width="160" />  
111 - <el-table-column label="车牌号" prop="licensePlateNumber" width="150" />  
112 - <el-table-column label="车架号" prop="frameNumber" width="240" />  
113 - <el-table-column label="车主姓名" prop="name" width="100" />  
114 - <el-table-column label="联系电话" prop="phone" width="180" /> 110 + <el-table-column
  111 + label="登记时间"
  112 + prop="createTime"
  113 + align="center"
  114 + width="160"
  115 + />
  116 + <el-table-column
  117 + label="车牌号"
  118 + prop="licensePlateNumber"
  119 + align="center"
  120 + width="150"
  121 + />
  122 + <el-table-column
  123 + label="车架号"
  124 + prop="frameNumber"
  125 + align="center"
  126 + width="240"
  127 + />
  128 + <el-table-column
  129 + label="车主姓名"
  130 + prop="name"
  131 + align="center"
  132 + width="100"
  133 + />
  134 + <el-table-column
  135 + label="联系电话"
  136 + prop="phone"
  137 + align="center"
  138 + width="180"
  139 + />
  140 + <el-table-column
  141 + label="保险需求"
  142 + prop="requirements"
  143 + align="center"
  144 + width="150"
  145 + />
115 <el-table-column 146 <el-table-column
116 label="处理状态" 147 label="处理状态"
  148 + align="center"
117 prop="policyStatus" 149 prop="policyStatus"
118 show-overflow-tooltip 150 show-overflow-tooltip
119 width="150" 151 width="150"
120 /> 152 />
121 - <el-table-column label="上年承保公司" prop="sysDeptName" width="150" />  
122 - <el-table-column label="操作人员" width="150"> 153 + <el-table-column
  154 + label="上年承保公司"
  155 + prop="sysDeptName"
  156 + align="center"
  157 + width="150"
  158 + />
  159 + <el-table-column label="操作人员" align="center" width="150">
123 <template #default="{ row }"> 160 <template #default="{ row }">
124 <span>{{ 161 <span>{{
125 row.associationEmployeeUserName || row.companyEmployeeUserName 162 row.associationEmployeeUserName || row.companyEmployeeUserName
126 }}</span> 163 }}</span>
127 </template> 164 </template>
128 </el-table-column> 165 </el-table-column>
129 - <el-table-column label="操作时间" width="160"> 166 + <el-table-column label="操作时间" align="center" width="160">
130 <template #default="{ row }"> 167 <template #default="{ row }">
131 <span>{{ 168 <span>{{
132 row.companyEmployeeUndertakeTime || row.distributionTime 169 row.companyEmployeeUndertakeTime || row.distributionTime
@@ -135,12 +172,14 @@ @@ -135,12 +172,14 @@
135 </el-table-column> 172 </el-table-column>
136 <el-table-column 173 <el-table-column
137 label="分配机制" 174 label="分配机制"
  175 + align="center"
138 width="120" 176 width="120"
139 prop="distributionMechanism" 177 prop="distributionMechanism"
140 /> 178 />
141 <el-table-column 179 <el-table-column
142 label="承保公司" 180 label="承保公司"
143 prop="companyName" 181 prop="companyName"
  182 + align="center"
144 show-overflow-tooltip 183 show-overflow-tooltip
145 width="150" 184 width="150"
146 > 185 >
@@ -148,7 +187,7 @@ @@ -148,7 +187,7 @@
148 <span>{{ row.companyName || "无" }}</span> 187 <span>{{ row.companyName || "无" }}</span>
149 </template> 188 </template>
150 </el-table-column> 189 </el-table-column>
151 - <el-table-column label="操作" fixed="right" width="150"> 190 + <el-table-column label="操作" fixed="right" align="center" width="150">
152 <template #default="{ row }"> 191 <template #default="{ row }">
153 <el-button 192 <el-button
154 v-show="row.policyStatus === '已退回'" 193 v-show="row.policyStatus === '已退回'"