From 12cce14bc30a85bbf96b5b30bb1aff1fc354091a Mon Sep 17 00:00:00 2001 From: wupengfei <834520024@qq.com> Date: 星期四, 27 三月 2025 15:07:21 +0800 Subject: [PATCH] feat: 接口对接 --- src/views/Home/BatchChange.vue | 58 ++ src/views/Home/components/BatchChangeRecordView.vue | 29 src/views/Home/components/UploadInsurePersonDialog.vue | 13 src/services/api/InsureBatchBill.ts | 126 ++++ src/services/api/typings.d.ts | 385 ++++++++++++++ src/views/Home/components/InsureOrderInfoView.vue | 221 ++++++-- src/views/Home/InsuranceOrderDetail.vue | 14 src/services/api/index.ts | 2 src/constants/insuranceClaim.ts | 19 src/views/Home/constants/index.ts | 58 +- src/views/Home/components/ChangePersonInfoDialog.vue | 14 src/views/Home/components/UploadStampFileDialog.vue | 2 src/views/Home/Home.vue | 255 ++++++--- src/views/InsuranceClaim/components/InsuranceClaimView.vue | 81 +- src/services/api/InsuranceOrder.ts | 242 +++++++++ 15 files changed, 1,266 insertions(+), 253 deletions(-) diff --git a/src/constants/insuranceClaim.ts b/src/constants/insuranceClaim.ts index 9cdf0d3..e35e4e6 100644 --- a/src/constants/insuranceClaim.ts +++ b/src/constants/insuranceClaim.ts @@ -63,11 +63,26 @@ [InsuranceClaimResultEnum.WithdrawCase]: '鎾ゆ', }; +export enum InsurancePolicyStatusEnum { + /**鏈敓鏁� */ + WaitEffect = 10, + /**宸茬敓鏁� */ + Effecting = 20, + /**宸茶繃鏈� */ + OutTimeEffect = 30, +} + +export const InsurancePolicyStatusEnumText = { + [InsurancePolicyStatusEnum.WaitEffect]: '鏈敓鏁�', + [InsurancePolicyStatusEnum.Effecting]: '宸茬敓鏁�', + [InsurancePolicyStatusEnum.OutTimeEffect]: '宸茶繃鏈�', +}; + export const OnJobFlagEnumText = { 澧炲憳: '澧炲憳', 鍑忓憳: '鍑忓憳', }; export const insuranceTypeText = { - 鏈堜繚: '鏈堜繚', - 骞翠繚: '骞翠繚', + '30D': '鏈堜繚', + '360D': '骞翠繚', }; diff --git a/src/services/api/InsuranceOrder.ts b/src/services/api/InsuranceOrder.ts index 80e6549..8a53ec5 100644 --- a/src/services/api/InsuranceOrder.ts +++ b/src/services/api/InsuranceOrder.ts @@ -32,6 +32,39 @@ }); } +/** 鏌ヨ鎵规鍙风姸鎬� GET /api/InsuranceOrder/CheckInrancesSerialNumStatus */ +export async function checkInrancesSerialNumStatus( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIcheckInrancesSerialNumStatusParams, + options?: API.RequestConfig +) { + return request<API.InsurancePolicyStatusEnum>( + '/api/InsuranceOrder/CheckInrancesSerialNumStatus', + { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + } + ); +} + +/** 淇濆崟璇︽儏-鎯呭喌浜哄憳鏁版嵁 GET /api/InsuranceOrder/ClearInsuranceStaffData */ +export async function clearInsuranceStaffData( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIclearInsuranceStaffDataParams, + options?: API.RequestConfig +) { + return request<number>('/api/InsuranceOrder/ClearInsuranceStaffData', { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + }); +} + /** 鍒犻櫎淇濆崟鏉愭枡 POST /api/InsuranceOrder/DeleteInsuranceOrderMaterial */ export async function deleteInsuranceOrderMaterial(body: string, options?: API.RequestConfig) { return request<number>('/api/InsuranceOrder/DeleteInsuranceOrderMaterial', { @@ -80,6 +113,21 @@ options?: API.RequestConfig ) { return request<any>('/api/InsuranceOrder/ExportInsuranceOrderList', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 鏍规嵁韬唤璇佸彿鍜屾姤妗堟棩鏈熸煡璇㈠湪淇濅俊鎭� POST /api/InsuranceOrder/GetEffectingStaffList */ +export async function getEffectingStaffList( + body: API.GetEffectingStaffListInput, + options?: API.RequestConfig +) { + return request<API.InsuranceOrderListOutput[]>('/api/InsuranceOrder/GetEffectingStaffList', { method: 'POST', headers: { 'Content-Type': 'application/json', @@ -158,6 +206,155 @@ ); } +/** 鑾峰彇鎶曚繚鎵规鍙� GET /api/InsuranceOrder/GetInsuranceOrderSerialNum */ +export async function getInsuranceOrderSerialNum(options?: API.RequestConfig) { + return request<string>('/api/InsuranceOrder/GetInsuranceOrderSerialNum', { + method: 'GET', + ...(options || {}), + }); +} + +/** 鑾峰彇鎶曚繚璁㈠崟鍒楄〃 POST /api/InsuranceOrder/GetInsurancePage */ +export async function getInsurancePage( + body: API.GetInsurancePageInput, + options?: API.RequestConfig +) { + return request<API.GetInsurancePageOutputPageOutput>('/api/InsuranceOrder/GetInsurancePage', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 瀵煎嚭鎶曚繚璁㈠崟 POST /api/InsuranceOrder/GetInsurancePageExport */ +export async function getInsurancePageExport( + body: API.GetInsurancePageInput, + options?: API.RequestConfig +) { + return request<any>('/api/InsuranceOrder/GetInsurancePageExport', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 鑾峰彇鎶曚繚璇︽儏鍩烘湰淇℃伅 GET /api/InsuranceOrder/GetInsurancePolicyHeadDto */ +export async function getInsurancePolicyHeadDto( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIgetInsurancePolicyHeadDtoParams, + options?: API.RequestConfig +) { + return request<API.GetInsurancePageOutput>('/api/InsuranceOrder/GetInsurancePolicyHeadDto', { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + }); +} + +/** 鑾峰彇鐩栫珷鏂囦欢 GET /api/InsuranceOrder/GetInsurancePolicyStampFiles */ +export async function getInsurancePolicyStampFiles( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIgetInsurancePolicyStampFilesParams, + options?: API.RequestConfig +) { + return request<string[]>('/api/InsuranceOrder/GetInsurancePolicyStampFiles', { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + }); +} + +/** 鏌ヨ淇濆崟璇︽儏涓嬩汉鍛樺垪琛� POST /api/InsuranceOrder/GetInsuranceStaffList */ +export async function getInsuranceStaffList( + body: API.GetInsuranceStaffListInput, + options?: API.RequestConfig +) { + return request<API.GetInsuranceStaffPageTemplatePageOutput>( + '/api/InsuranceOrder/GetInsuranceStaffList', + { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + } + ); +} + +/** 淇濆崟璇︽儏-瀵煎叆浜哄憳娓呭崟 GET /api/InsuranceOrder/GetInsuranceStaffListExport */ +export async function getInsuranceStaffListExport( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIgetInsuranceStaffListExportParams, + options?: API.RequestConfig +) { + return request<any>('/api/InsuranceOrder/GetInsuranceStaffListExport', { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + }); +} + +/** 姝ゅ鍚庣娌℃湁鎻愪緵娉ㄩ噴 POST /api/InsuranceOrder/GetInsuranceStaffPageExport */ +export async function getInsuranceStaffPageExport( + body: API.GetInsurancePageInput, + options?: API.RequestConfig +) { + return request<any>('/api/InsuranceOrder/GetInsuranceStaffPageExport', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 鎶曚繚璇︽儏-瀵煎叆浜哄憳 POST /api/InsuranceOrder/ImportInsDetailStaffToList */ +export async function importInsDetailStaffToList( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIimportInsDetailStaffToListParams, + options?: API.RequestConfig +) { + return request<API.ImportInsStaffAnalysisList[]>( + '/api/InsuranceOrder/ImportInsDetailStaffToList', + { + method: 'POST', + params: { + ...params, + }, + ...(options || {}), + } + ); +} + +/** 鏂板淇濆崟瀵煎叆 POST /api/InsuranceOrder/ImportInsStaffToList */ +export async function importInsStaffToList( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIimportInsStaffToListParams, + options?: API.RequestConfig +) { + return request<API.ImportInsStaffAnalysisList[]>('/api/InsuranceOrder/ImportInsStaffToList', { + method: 'POST', + params: { + ...params, + }, + ...(options || {}), + }); +} + /** 瀵煎叆淇濆崟鏁版嵁 POST /api/InsuranceOrder/ImportInsuranceOrderData */ export async function importInsuranceOrderData(body: string, options?: API.RequestConfig) { return request<any>('/api/InsuranceOrder/ImportInsuranceOrderData', { @@ -169,3 +366,48 @@ ...(options || {}), }); } + +/** 淇敼淇濆崟浜哄憳淇℃伅 POST /api/InsuranceOrder/UpdateInsuranceStaffInfo */ +export async function updateInsuranceStaffInfo( + body: API.UpdateInsuranceStaffInfoInput, + options?: API.RequestConfig +) { + return request<number>('/api/InsuranceOrder/UpdateInsuranceStaffInfo', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 涓婁紶淇濆崟 POST /api/InsuranceOrder/UplaodInsuranceBillFile */ +export async function uplaodInsuranceBillFile( + body: API.UplaodInsuranceBillFileInput, + options?: API.RequestConfig +) { + return request<number>('/api/InsuranceOrder/UplaodInsuranceBillFile', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 涓婁紶鐩栫珷鏂囦欢 POST /api/InsuranceOrder/UploadInsuranceStampFiles */ +export async function uploadInsuranceStampFiles( + body: API.UploadInsuranceStampFilesInput, + options?: API.RequestConfig +) { + return request<number>('/api/InsuranceOrder/UploadInsuranceStampFiles', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} diff --git a/src/services/api/InsureBatchBill.ts b/src/services/api/InsureBatchBill.ts new file mode 100644 index 0000000..3dd1b7a --- /dev/null +++ b/src/services/api/InsureBatchBill.ts @@ -0,0 +1,126 @@ +/* eslint-disable */ +// @ts-ignore +import { request } from '@/utils/request'; + +/** 鐢ㄦ埛绔�-鎻愪氦 鏂板锛屼慨鏀癸紝鍒犻櫎 鎵瑰崟 POST /api/InsureBatchBill/AddOrUpdateInsureBatchBill */ +export async function addOrUpdateInsureBatchBill( + body: API.InsureBatchBillInput, + options?: API.RequestConfig +) { + return request<number>('/api/InsureBatchBill/AddOrUpdateInsureBatchBill', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 杩愯惀绔�-瀵煎嚭鎵瑰崟浜哄憳 GET /api/InsureBatchBill/ExportInsuranceBatchStaff */ +export async function exportInsuranceBatchStaff( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIexportInsuranceBatchStaffParams, + options?: API.RequestConfig +) { + return request<any>('/api/InsureBatchBill/ExportInsuranceBatchStaff', { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + }); +} + +/** 鑾峰彇杩愯惀绔�-瀹℃牳鎵瑰崟-瀹℃牳璇︽儏 GET /api/InsureBatchBill/GetBatchDetailForCheck */ +export async function getBatchDetailForCheck( + // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟swagger榛樿娌℃湁鐢熸垚瀵硅薄) + params: API.APIgetBatchDetailForCheckParams, + options?: API.RequestConfig +) { + return request<API.BatchDetailForCheckDto>('/api/InsureBatchBill/GetBatchDetailForCheck', { + method: 'GET', + params: { + ...params, + }, + ...(options || {}), + }); +} + +/** 鑾峰彇瀹㈡埛绔�-鎵瑰崟鐨勫垪琛� POST /api/InsureBatchBill/GetInsureBatchBillList */ +export async function getInsureBatchBillList( + body: API.GetInsuranceBatchBillInput, + options?: API.RequestConfig +) { + return request<API.InsureBatchBillDtoPageOutput>('/api/InsureBatchBill/GetInsureBatchBillList', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 鑾峰彇杩愯惀绔�-瀹℃牳鎵瑰崟鐨勫垪琛� POST /api/InsureBatchBill/GetInsureBatchBillListForCheck */ +export async function getInsureBatchBillListForCheck( + body: API.GetInsuranceBatchBillForCheckInput, + options?: API.RequestConfig +) { + return request<API.InsureBatchBillDtoPageOutput>( + '/api/InsureBatchBill/GetInsureBatchBillListForCheck', + { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + } + ); +} + +/** 瀹㈡埛绔�-鎵瑰崟澧炲憳鍑忓憳淇濆崟鏁版嵁瀵煎叆 POST /api/InsureBatchBill/ImportBatchAddOrSubOrderData */ +export async function importBatchAddOrSubOrderData( + body: API.ImportBatchAddOrSubOrderInput, + options?: API.RequestConfig +) { + return request<any>('/api/InsureBatchBill/ImportBatchAddOrSubOrderData', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 瀹㈡埛绔�-鎵瑰崟鏇挎崲鏁版嵁瀵煎叆 POST /api/InsureBatchBill/ImportBatchUpdateOrderData */ +export async function importBatchUpdateOrderData( + body: API.ImportBatchAddOrSubOrderInput, + options?: API.RequestConfig +) { + return request<any>('/api/InsureBatchBill/ImportBatchUpdateOrderData', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} + +/** 杩愯惀绔�-璁剧疆鎵归噺鐨勭姸鎬� POST /api/InsureBatchBill/SetInsureBatchBillStatus */ +export async function setInsureBatchBillStatus( + body: API.SetInsureBatchBillStatusInput, + options?: API.RequestConfig +) { + return request<number>('/api/InsureBatchBill/SetInsureBatchBillStatus', { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + data: body, + ...(options || {}), + }); +} diff --git a/src/services/api/index.ts b/src/services/api/index.ts index 637fa08..e762d00 100644 --- a/src/services/api/index.ts +++ b/src/services/api/index.ts @@ -12,6 +12,7 @@ import * as IdentityUserLookup from './IdentityUserLookup'; import * as InsuranceClaim from './InsuranceClaim'; import * as InsuranceOrder from './InsuranceOrder'; +import * as InsureBatchBill from './InsureBatchBill'; import * as Permissions from './Permissions'; import * as PhoneMessage from './PhoneMessage'; import * as Profile from './Profile'; @@ -29,6 +30,7 @@ IdentityUserLookup, InsuranceClaim, InsuranceOrder, + InsureBatchBill, Permissions, PhoneMessage, Profile, diff --git a/src/services/api/typings.d.ts b/src/services/api/typings.d.ts index 1f45a49..0831b64 100644 --- a/src/services/api/typings.d.ts +++ b/src/services/api/typings.d.ts @@ -128,6 +128,14 @@ includeTypes?: boolean; } + interface APIcheckInrancesSerialNumStatusParams { + serialNum?: string; + } + + interface APIclearInsuranceStaffDataParams { + id?: string; + } + interface APIcreateParams { systemEmail: string; systemPassword: string; @@ -174,6 +182,10 @@ id?: string; } + interface APIexportInsuranceBatchStaffParams { + batchBillId?: string; + } + interface APIfindByEmailParams { email?: string; } @@ -202,6 +214,10 @@ interface APIgetAllSubModuleParams { moduleId?: string; + } + + interface APIgetBatchDetailForCheckParams { + batchBillId?: string; } interface APIgetCountParams { @@ -237,6 +253,18 @@ } interface APIgetInsuranceOrderMaterialListParams { + id?: string; + } + + interface APIgetInsurancePolicyHeadDtoParams { + id?: string; + } + + interface APIgetInsurancePolicyStampFilesParams { + id?: string; + } + + interface APIgetInsuranceStaffListExportParams { id?: string; } @@ -306,6 +334,16 @@ interface APIgetVersionSubModuleParams { versionId?: string; + } + + interface APIimportInsDetailStaffToListParams { + url?: string; + id?: string; + } + + interface APIimportInsStaffToListParams { + url?: string; + serialNum?: string; } interface APIsearchParams { @@ -412,6 +450,28 @@ objectId?: string; } + type BatchBillCheckStatus = 1 | 2 | 10 | 15 | 20 | 30 | -40 | -30 | -20 | -11 | -10 | -1; + + type BatchChangeTypeEnum = 10 | 20 | 30 | 40; + + interface BatchDetailForCheckDto { + /** 鎵瑰崟Id */ + insureBatchBillId?: string; + /** 瀹℃牳鐞嗙敱 */ + auditNote?: string; + checkStatus?: BatchBillCheckStatus; + /** 鐢熸晥鏃堕棿 */ + effectTime?: string; + /** 闄勪欢涓婁紶 */ + attachmentUrl?: string; + /** 淇濆崟鍙� */ + insureBillNo?: string; + /** 鎶曚繚浜� */ + enterpriseName?: string; + /** 鎵规敼浜哄憳璇︽儏 */ + staffList?: InsureBatchBillDetailDto[]; + } + interface ChangePasswordInput { currentPassword?: string; newPassword: string; @@ -470,6 +530,12 @@ sendBillExpireMessage?: boolean; /** 鏄惁鐭俊鎻愰啋 */ isSendMessage?: boolean; + /** 鏄惁浜哄憳鍙樻洿鎻愰啋 */ + staffChangeMessage?: boolean; + /** 鏄惁鎵规敼鎻愰啋 */ + batchUpdateMessage?: boolean; + /** 浼佷笟鍚嶇О */ + enterpriseName?: string; } interface CreateOrUpdateRoleInput { @@ -636,8 +702,123 @@ key?: string; } + interface GetEffectingStaffListInput { + claimDateTime?: string; + idNumber?: string; + } + interface GetFeatureListResultDto { groups?: FeatureGroupDto[]; + } + + interface GetInsuranceBatchBillForCheckInput { + pageModel?: Pagination; + /** 鐢宠鏃ユ湡寮�濮� */ + creationTimeBegin?: string; + /** 鐢宠鏃ユ湡缁撴潫 */ + creationTimeEnd?: string; + /** 鎵瑰崟鍙� */ + batchBillNo?: string; + checkStatus?: BatchBillCheckStatus; + } + + interface GetInsuranceBatchBillInput { + pageModel?: Pagination; + /** 淇濆崟Id */ + insurancePolicyId?: string; + } + + interface GetInsurancePageInput { + pageModel?: Pagination; + importStartDateTime?: string; + importEndDateTime?: string; + condition?: string; + insurancePeriod?: string; + status?: InsurancePolicyStatusEnum; + } + + interface GetInsurancePageOutput { + id?: string; + userId?: string; + /** 鎶曚繚浜� */ + insurerName?: string; + /** 琚繚闄╀汉 */ + policyerName?: string; + /** 鎵规鍙� */ + serialNum?: string; + status?: InsurancePolicyStatusEnum; + /** 浜哄憳娓呭崟鐘舵�� */ + listStatus?: string; + batchStatus?: number; + checkStatus?: BatchBillCheckStatus; + /** 淇濋 */ + sumInsured?: number; + /** 淇濊垂 */ + amount?: number; + /** 鎶曚繚浜烘暟 */ + insureCount?: number; + /** 鐞嗚禂鏁伴噺 */ + claimCount?: number; + /** 鎶曚繚鏈烘瀯 */ + insuranceOrg?: string; + /** 鎶曚繚鏂瑰紡 鏈堜繚:30D 骞翠繚: 360D */ + insurancePeriod?: string; + /** 鏂规鍚嶇О */ + insuranceScheme?: string; + /** 淇濆崟鏂囦欢 */ + insureBillUrl?: string; + /** 鏄惁宸蹭笂浼犵洊绔犳枃浠� */ + isUploadEffectFile?: boolean; + /** 鐩栫珷鏂囦欢 */ + effectBillUrl?: string; + /** 淇濋櫓鍗曞彿 */ + insureBillNo?: string; + /** 瀵煎叆鏂囦欢 */ + importFileUrl?: string; + lastImportTime?: string; + /** 淇濆崟鐢熸晥鏃堕棿 */ + effectStartTime?: string; + /** 淇濆崟澶辨晥鏃堕棿 */ + effectEndTime?: string; + emploerNames?: string[]; + creationTime?: string; + companyName?: string; + isClosedOutTime?: boolean; + } + + interface GetInsurancePageOutputPageOutput { + pageModel?: Pagination; + objectData?: any; + data?: GetInsurancePageOutput[]; + } + + interface GetInsuranceStaffListInput { + pageModel?: Pagination; + condition?: string; + insurancePolicyId?: string; + } + + interface GetInsuranceStaffPageTemplate { + id?: string; + policyId?: string; + serialNumber?: number; + name?: string; + gender?: string; + certType?: string; + certNo?: string; + jobName?: string; + userEmploer?: string; + address?: string; + age?: number; + birthDay?: string; + phone?: string; + creationTime?: string; + } + + interface GetInsuranceStaffPageTemplatePageOutput { + pageModel?: Pagination; + objectData?: any; + data?: GetInsuranceStaffPageTemplate[]; } interface GetPermissionListResultDto { @@ -785,6 +966,56 @@ interface IdentityUserUpdateRolesDto { roleNames: string[]; + } + + interface ImportBatchAddOrSubOrderInput { + /** 瀵煎叆鍦板潃 */ + url?: string; + /** 鎶曚繚Id */ + insurePolicyId?: string; + } + + interface ImportBatchStaffListInput { + originIdNumber?: string; + /** 鐢佃瘽鍙风爜 */ + phoneNumber?: string; + id?: number; + name?: string; + age?: number; + gender?: string; + certType?: string; + idNumber?: string; + insuranceScheme?: string; + workType?: string; + birthDay?: string; + remark?: string; + } + + interface ImportInsStaffAnalysisList { + id?: string; + /** 濮撳悕 */ + name?: string; + /** 鎬у埆 */ + sex?: string; + /** 璇佷欢绫诲瀷 */ + certType?: string; + /** 韬唤璇佸彿 */ + certNo?: string; + /** 骞撮緞 */ + age?: number; + /** 鐢熸棩 */ + birthDay?: string; + /** 鐢ㄥ伐浼佷笟 */ + useEmploer?: string; + /** 闆囧憳宸ョ */ + jobName?: string; + /** 鐢ㄥ伐鍦扮偣 */ + address?: string; + phone?: string; + /** 澶囨敞 */ + note?: string; + /** 1姝e父 0寮傚父 */ + isNormal?: boolean; } type InsuranceClaimAttachmentBusinessTypeEnum = 10 | 20 | 30 | 40 | 50; @@ -975,6 +1206,86 @@ url?: string; /** 鏉愭枡鍚嶇О */ materialName?: string; + } + + type InsurancePolicyStatusEnum = 10 | 20 | 30; + + interface InsureBatchBillDetailDto { + /** 鎵瑰崟Id */ + insureBatchBillId?: string; + /** 鎶曚繚Id */ + insurePolicyId?: string; + insurancePolicyDetailId?: string; + /** 淇敼淇℃伅 */ + modifyInfo?: string; + /** 鍚嶇О */ + name?: string; + /** 璇佷欢绫诲埆 */ + certType?: string; + /** 韬唤璇佸彿 */ + idNumber?: string; + /** 鎬у埆 */ + gender?: string; + /** 骞撮緞 */ + age?: number; + /** 鍑虹敓鏃ユ湡 */ + birthDay?: string; + /** 鑱屼笟鍚嶇О */ + workType?: string; + changeType?: BatchChangeTypeEnum; + } + + interface InsureBatchBillDto { + /** 鎵瑰崟Id */ + insureBatchBillId?: string; + /** 鎵瑰崟缂栧彿 */ + batchBillNo?: string; + /** 淇濆崟Id */ + insurancePolicyId?: string; + changeType?: BatchChangeTypeEnum; + checkStatus?: BatchBillCheckStatus; + /** 鍦ㄤ繚浜烘暟 */ + insurePersonNumber?: number; + /** 鍘熸湰鍦ㄤ繚浜烘暟 */ + orginInsurePersonNumber?: number; + /** 鏂板浜烘暟 */ + addPersonNumber?: number; + /** 鐢宠鏃ユ湡 */ + creationTime?: string; + /** 鍑忓皯浜烘暟 */ + subPersonNumber?: number; + /** 瀹℃牳鐞嗙敱 */ + auditNote?: string; + /** 瀹℃牳鏃堕棿 */ + checkDate?: string; + /** 瀹℃牳浜� */ + checkUserId?: string; + /** 鐢熸晥鏃堕棿 */ + effectTime?: string; + /** 闄勪欢涓婁紶 */ + attachmentUrl?: string; + } + + interface InsureBatchBillDtoPageOutput { + pageModel?: Pagination; + objectData?: any; + data?: InsureBatchBillDto[]; + } + + interface InsureBatchBillInput { + /** 鎶曚繚Id */ + insurancePolicyId?: string; + /** 鎵瑰崟Id */ + batchBillId?: string; + /** 鏈熸湜鐢熸晥 */ + effectTime?: string; + changeType?: BatchChangeTypeEnum; + /** 鎵瑰浜哄憳鍒楄〃 */ + addInsStaffList?: ImportBatchStaffListInput[]; + /** 淇敼浜哄憳鍒楄〃 */ + updateInsStaffList?: ImportBatchStaffListInput[]; + /** 鍒犻櫎浜哄憳鍒楄〃 */ + delInsStaffList?: ImportBatchStaffListInput[]; } interface IStringValueType { @@ -1343,6 +1654,24 @@ phoneNumber: string; } + interface SetInsureBatchBillStatusInput { + /** 鎵瑰崟Id */ + insureBatchBillId?: string; + /** 鎵瑰崟鍙� */ + batchBillNo?: string; + /** 瀹℃牳鐞嗙敱 */ + auditNote?: string; + checkStatus?: BatchBillCheckStatus; + /** 瀹℃牳鏃堕棿 */ + checkDate?: string; + /** 瀹℃牳浜� */ + checkUserId?: string; + /** 鐢熸晥鏃堕棿 */ + effectTime?: string; + /** 闄勪欢涓婁紶 */ + attachmentUrl?: string; + } + interface SetMyModule { moduleId?: string; sequence?: number; @@ -1416,6 +1745,12 @@ sendClaimMessage?: boolean; /** 鏄惁淇濆崟鍒版湡鎻愰啋 */ sendBillExpireMessage?: boolean; + /** 鏄惁浜哄憳鍙樻洿鎻愰啋 */ + staffChangeMessage?: boolean; + /** 鏄惁鎵规敼鎻愰啋 */ + batchUpdateMessage?: boolean; + /** 鍏徃鍚� */ + enterpriseName?: string; /** 鏄惁鐭俊鎻愰啋 */ isSendMessage?: boolean; /** 瑙掕壊 */ @@ -1490,6 +1825,14 @@ id?: string; } + interface UpdateInsuranceStaffInfoInput { + insurancePolicyId?: string; + id?: string; + name?: string; + idNumber?: string; + phone?: string; + } + interface UpdatePassWordInput { id?: string; passWord?: string; @@ -1517,6 +1860,36 @@ name?: string; surname?: string; phoneNumber?: string; + } + + interface UplaodInsuranceBillFileInput { + /** 淇濆崟Id */ + insurancePolicyId?: string; + /** 淇濆崟鍙� */ + insureBillNo?: string; + /** 淇濆崟璧锋湡 */ + effectStartTime?: string; + /** 淇濆崟姝㈡湡 */ + effectEndTime?: string; + /** 鍙備繚鏈烘瀯 */ + insuranceOrg?: string; + /** 鎶曚繚鏂瑰紡 鏈堜繚:30D 骞翠繚: 360D */ + insurancePeriod?: string; + /** 鏂规鍚嶇О */ + insuranceScheme?: string; + /** 淇濋 */ + sumInsured?: number; + /** 淇濊垂 */ + amount?: number; + /** 淇濆崟鏂囦欢 */ + insureBillUrl?: string; + } + + interface UploadInsuranceStampFilesInput { + /** 淇濆崟Id */ + insurancePolicyId?: string; + /** 鐩栫珷鏂囦欢 */ + listFiles?: string[]; } interface UserData { @@ -1563,6 +1936,12 @@ isSendMessage?: boolean; /** 瑙掕壊 */ roleNames?: string[]; + /** 鏄惁浜哄憳鍙樻洿鎻愰啋 */ + staffChangeMessage?: boolean; + /** 鏄惁鎵规敼鎻愰啋 */ + batchUpdateMessage?: boolean; + /** 浼佷笟鍚嶇О */ + enterpriseName?: string; } interface UserListOutput { @@ -1587,6 +1966,12 @@ isSendMessage?: boolean; /** 瑙掕壊 */ roleNames?: string[]; + /** 鏄惁浜哄憳鍙樻洿鎻愰啋 */ + staffChangeMessage?: boolean; + /** 鏄惁鎵规敼鎻愰啋 */ + batchUpdateMessage?: boolean; + /** 浼佷笟鍚嶇О */ + enterpriseName?: string; } interface UserListOutputPageOutput { diff --git a/src/views/Home/BatchChange.vue b/src/views/Home/BatchChange.vue index b5f5172..fb48b4d 100644 --- a/src/views/Home/BatchChange.vue +++ b/src/views/Home/BatchChange.vue @@ -34,6 +34,7 @@ :limitFileSize="10" accept="xlsx,xls" :showTip="false" + :on-success="handleUploadAddOrReduce" > <template #default> <el-button type="primary">鍔犲噺浜�</el-button> @@ -54,6 +55,7 @@ :limitFileSize="10" accept="xlsx,xls" :showTip="false" + :on-success="handleUploadReplace" > <template #default> <el-button type="primary">鏇挎崲浜�</el-button> @@ -108,8 +110,11 @@ UploadUserFile, } from '@bole-core/components'; import * as insuranceOrderServices from '@/services/api/InsuranceOrder'; -import { downloadFileByUrl, OrderInputType } from '@bole-core/core'; +import * as insureBatchBillServices from '@/services/api/InsureBatchBill'; +import { downloadFileByUrl, Message, OrderInputType } from '@bole-core/core'; import { InsuranceAddOrReduceTempPath, InsuranceChangeTempPath } from '@/constants'; +import { useRouteView } from '@/hooks'; +import { FormInstance } from 'element-plus'; defineOptions({ name: 'BatchChange', @@ -159,6 +164,7 @@ ]; const route = useRoute(); +const { closeViewPush } = useRouteView(); const id = route.params.id as string; const BaseState = { loading: true, @@ -203,8 +209,50 @@ } ); +async function handleUploadAddOrReduce(response: UploadUserFile) { + try { + let params: API.ImportBatchAddOrSubOrderInput = { + url: response.path, + insurePolicyId: id, + }; + let res = await insureBatchBillServices.importBatchAddOrSubOrderData(params); + } catch (error) {} +} +async function handleUploadReplace(response: UploadUserFile) { + try { + let params: API.ImportBatchAddOrSubOrderInput = { + url: response.path, + insurePolicyId: id, + }; + let res = await insureBatchBillServices.importBatchUpdateOrderData(params); + } catch (error) {} +} + function handleClear() {} -function handleSubmit() {} + +const formRef = ref<FormInstance>(); +function handleSubmit() { + if (!formRef.value) return; + formRef.value.validate((valid) => { + if (valid) { + addOrUpdateInsureBatchBill(); + } else { + return; + } + }); +} + +async function addOrUpdateInsureBatchBill() { + try { + let params = {}; + let res = await insureBatchBillServices.addOrUpdateInsureBatchBill(params); + if (res) { + Message.successMessage('鎻愪氦鎴愬姛'); + handleBack(); + } + } catch (error) {} +} + function DownloadAddOrReducePersonTemplate() { downloadFileByUrl(InsuranceAddOrReduceTempPath, '鍔犲噺浜烘ā鏉�'); } @@ -212,6 +260,12 @@ downloadFileByUrl(InsuranceChangeTempPath, '鏇挎崲浜烘ā鏉�'); } +function handleBack() { + closeViewPush(route, { + name: 'Home', + }); +} + onMounted(async () => { await getBatchRefundInfoDetail(); state.loading = false; diff --git a/src/views/Home/Home.vue b/src/views/Home/Home.vue index c2442aa..fe04a60 100644 --- a/src/views/Home/Home.vue +++ b/src/views/Home/Home.vue @@ -17,16 +17,7 @@ </QueryFilterItem> <QueryFilterItem> <FieldRadio - v-model="extraParamState.onJobFlag" - :value-enum="OnJobFlagEnumText" - buttonStyle - showAllBtn - @change="getList()" - /> - </QueryFilterItem> - <QueryFilterItem> - <FieldRadio - v-model="extraParamState.insuranceType" + v-model="extraParamState.insurancePeriod" :value-enum="insuranceTypeText" buttonStyle showAllBtn @@ -34,8 +25,17 @@ /> </QueryFilterItem> <QueryFilterItem> + <FieldRadio + v-model="extraParamState.status" + :value-enum="InsurancePolicyStatusEnumText" + buttonStyle + showAllBtn + @change="getList()" + /> + </QueryFilterItem> + <QueryFilterItem> <SearchInput - v-model="extraParamState.keyword" + v-model="extraParamState.condition" style="width: 260px" placeholder="鍗曚綅/淇濆崟鍙�/鍙備繚鏈烘瀯" @on-click-search="getList" @@ -52,8 +52,10 @@ >瀵煎叆</el-button > - <el-button @click="downloadInsureOrder()" type="primary" link>瀵煎嚭淇濆崟鍒楄〃</el-button> - <el-button @click="downloadInsurePerson()" type="primary" link>瀵煎嚭鍦ㄤ繚浜哄憳</el-button> + <el-button @click="getInsurancePageExport()" type="primary" link>瀵煎嚭淇濆崟鍒楄〃</el-button> + <el-button @click="getInsuranceStaffPageExport()" type="primary" link + >瀵煎嚭鍦ㄤ繚浜哄憳</el-button + > </template> </ProTableQueryFilterBar> <ProTableV2 @@ -87,15 +89,21 @@ UploadUserFile, SearchInput, FieldRadio, + XLSXUtils, } from '@bole-core/components'; import * as insuranceOrderServices from '@/services/api/InsuranceOrder'; import { Message, OrderInputType, downloadFileByUrl } from '@bole-core/core'; import { columns } from './constants'; import UploadInsurePersonDialog from './components/UploadInsurePersonDialog.vue'; import UploadStampFileDialog from './components/UploadStampFileDialog.vue'; -import { format, downloadFile, setOSSLink } from '@/utils'; +import { format, downloadFile, setOSSLink, toThousand, convertApi2FormUrl } from '@/utils'; import { ModelValueType } from 'element-plus'; -import { InsuranceOrderTempPath, OnJobFlagEnumText, insuranceTypeText } from '@/constants'; +import { + InsuranceOrderTempPath, + insuranceTypeText, + InsurancePolicyStatusEnumText, + InsurancePolicyStatusEnum, +} from '@/constants'; import dayjs from 'dayjs'; import _ from 'lodash'; @@ -121,9 +129,9 @@ emits: { onClick: (role) => handleBatch(role), }, - // extraProps: { - // hide: (row: API.InsuranceOrderListOutput) => !row.orderBillFile, - // }, + extraProps: { + hide: (row: API.GetInsurancePageOutput) => row.status !== InsurancePolicyStatusEnum.Effecting, + }, }, { data: { @@ -133,9 +141,10 @@ emits: { onClick: (role) => handleUploadStampFile(role), }, - // extraProps: { - // hide: (row: API.InsuranceOrderListOutput) => !row.orderBillFile, - // }, + extraProps: { + hide: (row: API.GetInsurancePageOutput) => + row.status !== InsurancePolicyStatusEnum.WaitEffect, + }, }, { data: { @@ -143,10 +152,11 @@ name: '淇濆崟涓嬭浇', }, emits: { - onClick: (role) => handleDownloadOrderNo(role), + onClick: (role) => handleDownloadInsureFile(role), }, extraProps: { - hide: (row: API.InsuranceOrderListOutput) => !row.orderBillFile, + hide: (row: API.GetInsurancePageOutput) => + row.status === InsurancePolicyStatusEnum.WaitEffect, }, }, ]).filter(Boolean); @@ -172,7 +182,7 @@ async ({ pageIndex, pageSize }, extraParamState) => { try { let params = createParams(pageIndex, pageSize); - let res = await insuranceOrderServices.getInsuranceOrderPage(params, { + let res = await insuranceOrderServices.getInsurancePage(params, { showLoading: !state.loading, }); return res; @@ -180,84 +190,123 @@ }, { defaultExtraParams: { - orderInput: [{ property: 'createTime', order: OrderInputType.Desc }], + orderInput: [{ property: 'id', order: OrderInputType.Desc }], creationDate: [] as unknown as ModelValueType, - keyword: '', - onJobFlag: '', - insuranceType: '', + condition: '', + status: '' as any as InsurancePolicyStatusEnum, + insurancePeriod: '', }, columnsRenderProps: { - createTime: { - type: 'date', - format: 'YYYY/MM/DD', + status: { type: 'enum', valueEnum: InsurancePolicyStatusEnumText }, + insurancePeriod: { type: 'enum', valueEnum: insuranceTypeText }, + creationTime: { type: 'date', format: 'YYYY-MM-DD' }, + effectStartTime: { type: 'date', format: 'YYYY-MM-DD' }, + effectEndTime: { type: 'date', format: 'YYYY-MM-DD' }, + sumInsured: { + type: 'money', + formatter: (row: API.GetInsurancePageOutput) => + row.sumInsured == null ? '' : toThousand(row.sumInsured), }, - insuranceBeginTime: { - type: 'date', - format: 'YYYY/MM/DD', - }, - insuranceEndTime: { - type: 'date', - format: 'YYYY/MM/DD', + amount: { + type: 'money', + formatter: (row: API.GetInsurancePageOutput) => + row.amount == null ? '' : toThousand(row.amount), }, }, } ); function createParams(pageIndex: number, pageSize: number) { - let params: API.QueryInsuranceOrderPageInput = { + let params: API.GetInsurancePageInput = { pageModel: { rows: pageSize, page: pageIndex, orderInput: extraParamState.orderInput, }, - beginCreationTime: format(extraParamState.creationDate?.[0] ?? '', 'YYYY-MM-DD 00:00:00'), - endCreationTime: format(extraParamState.creationDate?.[1] ?? '', 'YYYY-MM-DD 23:59:59'), - condition: extraParamState.keyword, - onJobFlag: extraParamState.onJobFlag, - insuranceType: extraParamState.insuranceType, + importStartDateTime: format(extraParamState.creationDate?.[0] ?? '', 'YYYY-MM-DD 00:00:00'), + importEndDateTime: format(extraParamState.creationDate?.[1] ?? '', 'YYYY-MM-DD 23:59:59'), + condition: extraParamState.condition, + insurancePeriod: extraParamState.insurancePeriod, + status: extraParamState.status, }; return params; } -const { dialogProps, handleAdd, editForm } = useFormDialog({ - onConfirm: uploadInsurePerson, +const { dialogProps, handleAdd, editForm, dialogState } = useFormDialog({ + onConfirm: checkInrancesSerialNumStatus, defaultFormParams: { - orderNo: '', + serialNum: '', url: [] as UploadUserFile[], }, + closeAfterConfirm: false, }); + +async function checkInrancesSerialNumStatus() { + try { + let params: API.APIimportInsStaffToListParams = { + serialNum: editForm.serialNum, + url: editForm.url?.[0]?.path, + }; + let res = await insuranceOrderServices.checkInrancesSerialNumStatus(params); + if (res === InsurancePolicyStatusEnum.Effecting) { + await Message.tipMessage('璇ユ壒娆′繚鍗曞凡鐢熸晥锛岃淇敼鎵规鍙峰悗閲嶆柊瀵煎叆'); + } else if (res === InsurancePolicyStatusEnum.OutTimeEffect) { + await Message.tipMessage('璇ユ壒娆′繚鍗曞凡澶辨晥锛岃淇敼鎵规鍙峰悗閲嶆柊瀵煎叆'); + } else if (res === InsurancePolicyStatusEnum.WaitEffect) { + await Message.tipMessage('瀛樺湪鐩稿悓鐨勬壒娆″彿锛屾槸鍚﹁鐩栵紵'); + importInsStaffToList(); + } else { + importInsStaffToList(); + } + } catch (error) {} +} + +async function importInsStaffToList() { + try { + let params: API.APIimportInsStaffToListParams = { + serialNum: editForm.serialNum, + url: editForm.url?.[0]?.path, + }; + let res = await insuranceOrderServices.importInsStaffToList(params); + if (res.length > 0) { + await Message.tipMessage('瀛樺湪閿欒鏁版嵁锛屾槸鍚﹀鍑猴紵'); + XLSXUtils.exportToXLSX({ + workbookDataList: res, + fileName: '閿欒浜哄憳鍚嶅崟', + workbookHeaderMap: { + name: '闆囧憳濮撳悕', + sex: '鎬у埆', + certType: '璇佷欢绫诲瀷', + certNo: '璇佷欢鍙风爜', + jobName: '闆囧憳宸ョ', + useEmploer: '鐢ㄥ伐鍗曚綅', + address: '鐢ㄥ伐鍦扮偣', + note: '澶囨敞', + }, + }); + } + dialogState.dialogVisible = false; + getList(paginationState.pageIndex); + } catch (error) {} +} function handleUpload() { handleAdd({ - orderNo: '', + serialNum: `${dayjs().format('YYYYMMDD')}${_.random(0, 9999).toString().padStart(4, '0')}`, url: [] as UploadUserFile[], }); } -async function uploadInsurePerson() { - try { - let params = { - orderNo: editForm.orderNo, - url: editForm.url?.[0]?.path, - }; - // let res = await insuranceOrderServices.uploadStampFile(params); - // if (res) { - // Message.successMessage('涓婁紶鎴愬姛'); - // getList(paginationState.pageIndex); - // } - } catch (error) {} -} - const router = useRouter(); -async function handleExport() { +async function getInsurancePageExport() { try { if (paginationState.total === 0) { Message.warnMessage('娌℃湁鏁版嵁鍙互瀵煎嚭鍝'); return; } let params = createParams(paginationState.pageIndex, paginationState.pageSize); - let res = await insuranceOrderServices.exportInsuranceOrderList(params, { + let res = await insuranceOrderServices.getInsurancePageExport(params, { responseType: 'blob', getResponse: true, }); @@ -267,14 +316,31 @@ } catch (error) {} } +async function getInsuranceStaffPageExport() { + try { + if (paginationState.total === 0) { + Message.warnMessage('娌℃湁鏁版嵁鍙互瀵煎嚭鍝'); + return; + } + let params = createParams(paginationState.pageIndex, paginationState.pageSize); + let res = await insuranceOrderServices.getInsuranceStaffPageExport(params, { + responseType: 'blob', + getResponse: true, + }); + if (res) { + downloadFile(res.data, `鍦ㄤ繚浜哄憳瀵煎嚭`, 'xlsx'); + } + } catch (error) {} +} + function handleDownload() { downloadFileByUrl(InsuranceOrderTempPath, '淇濆崟瀵煎叆妯℃澘'); } -function handleRowStyle(data: { row: API.InsuranceOrderListOutput }) { +function handleRowStyle(data: { row: API.GetInsurancePageOutput }) { if ( - dayjs(dayjs(data.row?.insuranceEndTime).format('YYYY-MM-DD')).diff(dayjs(), 'day') >= 0 && - dayjs(dayjs(data.row?.insuranceEndTime).format('YYYY-MM-DD')).diff(dayjs(), 'day') < 6 + dayjs(dayjs(data.row?.effectEndTime).format('YYYY-MM-DD')).diff(dayjs(), 'day') >= 0 && + dayjs(dayjs(data.row?.effectEndTime).format('YYYY-MM-DD')).diff(dayjs(), 'day') < 6 ) { return { color: '#ff0000', @@ -287,39 +353,48 @@ handleEdit: handleStampFileEdit, editForm: stampFileForm, } = useFormDialog({ - onConfirm: uploadStampFile, + onConfirm: uploadInsuranceStampFiles, defaultFormParams: { id: '', url: [] as UploadUserFile[], }, }); -function handleUploadStampFile(row: API.InsuranceOrderListOutput) { - handleStampFileEdit({ - id: row.id, - url: [] as UploadUserFile[], - }); -} - -async function uploadStampFile() { +async function handleUploadStampFile(row: API.GetInsurancePageOutput) { try { - let params = { - id: stampFileForm.id, - url: stampFileForm.url?.[0]?.path, - }; - // let res = await insuranceOrderServices.uploadStampFile(params); - // if (res) { - // Message.successMessage('涓婁紶鎴愬姛'); - // getList(paginationState.pageIndex); - // } + const url = await getInsurancePolicyStampFiles(row.id); + handleStampFileEdit({ + id: row.id, + url: url.map((x) => convertApi2FormUrl(x)) ?? [], + }); } catch (error) {} } -function handleDownloadOrderNo(row: API.InsuranceOrderListOutput) { - downloadFileByUrl(setOSSLink(row.orderBillFile)); +async function uploadInsuranceStampFiles() { + try { + let params: API.UploadInsuranceStampFilesInput = { + insurancePolicyId: stampFileForm.id, + listFiles: stampFileForm.url?.map((x) => x.path) ?? [], + }; + let res = await insuranceOrderServices.uploadInsuranceStampFiles(params); + if (res) { + Message.successMessage('涓婁紶鎴愬姛'); + getList(paginationState.pageIndex); + } + } catch (error) {} } -function handleDetail(row: API.InsuranceOrderListOutput) { +async function getInsurancePolicyStampFiles(id: string) { + try { + return await insuranceOrderServices.getInsurancePolicyStampFiles({ id: id }); + } catch (error) {} +} + +function handleDownloadInsureFile(row: API.GetInsurancePageOutput) { + downloadFileByUrl(setOSSLink(row.insureBillUrl)); +} + +function handleDetail(row: API.GetInsurancePageOutput) { router.push({ name: 'InsuranceOrderDetail', params: { @@ -327,7 +402,7 @@ }, }); } -function handleBatch(row: API.InsuranceOrderListOutput) { +function handleBatch(row: API.GetInsurancePageOutput) { router.push({ name: 'BatchChange', params: { @@ -335,6 +410,4 @@ }, }); } -function downloadInsureOrder() {} -function downloadInsurePerson() {} </script> diff --git a/src/views/Home/InsuranceOrderDetail.vue b/src/views/Home/InsuranceOrderDetail.vue index a2b7a04..b8e2b1a 100644 --- a/src/views/Home/InsuranceOrderDetail.vue +++ b/src/views/Home/InsuranceOrderDetail.vue @@ -5,7 +5,12 @@ <ProTabPane lazy label="淇濆崟淇℃伅" :name="InsureOrderTabType.InsureOrderInfo"> <InsureOrderInfoView /> </ProTabPane> - <ProTabPane lazy label="鎵规敼璁板綍" :name="InsureOrderTabType.BatchOrder"> + <ProTabPane + v-if="detail.status !== InsurancePolicyStatusEnum.WaitEffect" + lazy + label="鎵规敼璁板綍" + :name="InsureOrderTabType.BatchOrder" + > <BatchChangeRecordView /> </ProTabPane> </ProTabs> @@ -19,6 +24,7 @@ import BatchChangeRecordView from './components/BatchChangeRecordView.vue'; import * as insuranceOrderServices from '@/services/api/InsuranceOrder'; import { useQuery } from '@tanstack/vue-query'; +import { InsurancePolicyStatusEnum } from '@/constants'; defineOptions({ name: 'InsuranceOrderDetail', @@ -37,11 +43,11 @@ const id = route.params.id as string; const { data: detail, isLoading } = useQuery({ - queryKey: ['insuranceOrderServices/getInsuranceOrderDetail', id], + queryKey: ['insuranceOrderServices/getInsurancePolicyHeadDto', id], queryFn: async () => { - return await insuranceOrderServices.getInsuranceOrderDetail({ id: id }); + return await insuranceOrderServices.getInsurancePolicyHeadDto({ id: id }); }, - placeholderData: () => ({} as API.InsuranceOrderListOutput), + placeholderData: () => ({} as API.GetInsurancePageOutput), enabled: !!id, }); </script> diff --git a/src/views/Home/components/BatchChangeRecordView.vue b/src/views/Home/components/BatchChangeRecordView.vue index 0dcdf53..1b37424 100644 --- a/src/views/Home/components/BatchChangeRecordView.vue +++ b/src/views/Home/components/BatchChangeRecordView.vue @@ -24,7 +24,7 @@ defineOperationBtns, useFormDialog, } from '@bole-core/components'; -import * as insuranceOrderServices from '@/services/api/InsuranceOrder'; +import * as insureBatchBillServices from '@/services/api/InsureBatchBill'; import { OrderInputType } from '@bole-core/core'; import BatchChangeRecordDetailDialog from './BatchChangeRecordDetailDialog.vue'; @@ -90,7 +90,19 @@ onClick: (role) => handleDetail(role), }, // extraProps: { - // hide: (row: API.InsuranceOrderListOutput) => !row.orderBillFile, + // hide: (row: API.InsureBatchBillDto) => !row.orderBillFile, + // }, + }, + { + data: { + enCode: 'downloadBtn', + name: '涓嬭浇鎵瑰崟', + }, + emits: { + onClick: (role) => handleDownload(role), + }, + // extraProps: { + // hide: (row: API.InsureBatchBillDto) => !row.orderBillFile, // }, }, ]); @@ -112,16 +124,15 @@ } = useTable( async ({ pageIndex, pageSize }, extraParamState) => { try { - let params: API.QueryInsuranceOrderPageInput = { + let params: API.GetInsuranceBatchBillInput = { pageModel: { rows: pageSize, page: pageIndex, orderInput: extraParamState.orderInput, }, - condition: extraParamState.keyWord, - // insurePolicyOperateHistoryId: id, + insurancePolicyId: id, }; - let res = await insuranceOrderServices.getInsuranceOrderPage(params, { + let res = await insureBatchBillServices.getInsureBatchBillList(params, { showLoading: !state.loading, }); return res; @@ -142,12 +153,14 @@ }, }); -function handleDetail(row: API.InsuranceOrderListOutput) { +function handleDetail(row: API.InsureBatchBillDto) { handleEdit({ - id: row.id, + id: row.insureBatchBillId, }); } +function handleDownload(row: API.InsureBatchBillDto) {} + onMounted(async () => { await getBatchRefundInfoDetail(); state.loading = false; diff --git a/src/views/Home/components/ChangePersonInfoDialog.vue b/src/views/Home/components/ChangePersonInfoDialog.vue index 1eb53f0..1bd0a31 100644 --- a/src/views/Home/components/ChangePersonInfoDialog.vue +++ b/src/views/Home/components/ChangePersonInfoDialog.vue @@ -27,12 +27,12 @@ <ProFormColItem :span="16"> <ProFormItemV2 label="韬唤璇佸彿锛�" - prop="name" - :check-rules="[{ message: '璇疯緭鍏ヨ韩浠借瘉鍙�' }]" + prop="idNumber" + :check-rules="[{ message: '璇疯緭鍏ヨ韩浠借瘉鍙�', type: 'idCard' }]" > <ProFormText placeholder="璇疯緭鍏ヨ韩浠借瘉鍙�" - v-model.trim="innerForm.name" + v-model.trim="innerForm.idNumber" :maxlength="30" ></ProFormText> </ProFormItemV2> @@ -40,11 +40,12 @@ </ProFormCol> <ProFormCol> <ProFormColItem :span="16"> - <ProFormItemV2 label="鎵嬫満鍙凤細" prop="name" :check-rules="[{ message: '璇疯緭鍏ユ墜鏈哄彿' }]"> + <ProFormItemV2 label="鎵嬫満鍙凤細" prop="phone"> <ProFormText placeholder="璇疯緭鍏ユ墜鏈哄彿" - v-model.trim="innerForm.name" + v-model.trim="innerForm.phone" :maxlength="30" + disabled ></ProFormText> </ProFormItemV2> </ProFormColItem> @@ -77,7 +78,10 @@ type Props = { modelValue: boolean; form?: { + id: string; name: string; + idNumber: string; + phone: string; }; }; diff --git a/src/views/Home/components/InsureOrderInfoView.vue b/src/views/Home/components/InsureOrderInfoView.vue index a8cf6e4..18afc27 100644 --- a/src/views/Home/components/InsureOrderInfoView.vue +++ b/src/views/Home/components/InsureOrderInfoView.vue @@ -5,40 +5,37 @@ <ProForm :model="detail" ref="formRef" label-width="120px" :is-read="true"> <ProFormCol> <ProFormColItem :span="8"> - <ProFormItemV2 label="淇濆崟鍙�:" prop="orderNo"> - <ProFormText v-model.trim="detail.orderNo" /> + <ProFormItemV2 label="淇濆崟鍙�:" prop="insureBillNo"> + <ProFormText v-model.trim="detail.insureBillNo" /> </ProFormItemV2> </ProFormColItem> <ProFormColItem :span="8"> - <ProFormItemV2 label="鐢熸晥鐘舵��:" prop="insuranceTypeCode"> - <ProFormRadio v-model="detail.insuranceType" :value-enum="insuranceTypeText" /> + <ProFormItemV2 label="鐢熸晥鐘舵��:" prop="status"> + <ProFormRadio v-model="detail.status" :value-enum="InsurancePolicyStatusEnumText" /> </ProFormItemV2> </ProFormColItem> </ProFormCol> <ProFormCol> <ProFormColItem :span="8"> - <ProFormItemV2 label="淇濋櫓璧锋湡:" prop="applyTime"> - <ProFormDatePicker v-model.trim="detail.createTime" format="YYYY-MM-DD HH:mm" /> + <ProFormItemV2 label="淇濋櫓璧锋湡:" prop="effectStartTime"> + <ProFormDatePicker v-model.trim="detail.effectStartTime" format="YYYY-MM-DD" /> </ProFormItemV2> </ProFormColItem> <ProFormColItem :span="8"> - <ProFormItemV2 label="淇濋櫓姝㈡湡:" prop="insuranceTypeCode"> - <ProFormDatePicker v-model.trim="detail.createTime" format="YYYY-MM-DD HH:mm" /> + <ProFormItemV2 label="淇濋櫓姝㈡湡:" prop="effectEndTime"> + <ProFormDatePicker v-model.trim="detail.effectEndTime" format="YYYY-MM-DD" /> </ProFormItemV2> </ProFormColItem> <ProFormColItem :span="8"> - <ProFormItemV2 label="鎶曚繚鏂瑰紡:" prop="insureWay"> - <ProFormRadio v-model="detail.insuranceType" :value-enum="insuranceTypeText" /> + <ProFormItemV2 label="鎶曚繚鏂瑰紡:" prop="insurancePeriod"> + <ProFormRadio v-model="detail.insurancePeriod" :value-enum="insuranceTypeText" /> </ProFormItemV2> </ProFormColItem> </ProFormCol> <ProFormCol> <ProFormColItem :span="8"> - <ProFormItemV2 label="鍙備繚鏈烘瀯:" prop="insuredInstitution"> - <ProFormRadio - v-model="detail.insuredInstitution" - :value-enum="InsuredInstitutionEnum" - /> + <ProFormItemV2 label="鍙備繚鏈烘瀯:" prop="insuranceOrg"> + <ProFormRadio v-model="detail.insuranceOrg" :value-enum="InsuredInstitutionEnum" /> </ProFormItemV2> </ProFormColItem> <ProFormColItem :span="8"> @@ -47,27 +44,27 @@ </ProFormItemV2> </ProFormColItem> <ProFormColItem :span="8"> - <ProFormItemV2 label="鎶曚繚浜烘暟:" prop="numberOfFailed"> - <ProFormInputNumber v-model.trim="detail.incDecAmount" unit="浜�" /> + <ProFormItemV2 label="鎶曚繚浜烘暟:" prop="insureCount"> + <ProFormInputNumber v-model.trim="detail.insureCount" unit="浜�" /> </ProFormItemV2> </ProFormColItem> </ProFormCol> <ProFormCol> <ProFormColItem :span="8"> - <ProFormItemV2 label="鎶曚繚浜�:" prop="companyName"> - <ProFormText v-model.trim="detail.orderNo" /> + <ProFormItemV2 label="鎶曚繚浜�:" prop="insurerName"> + <ProFormText v-model.trim="detail.insurerName" /> </ProFormItemV2> </ProFormColItem> <ProFormColItem :span="8"> - <ProFormItemV2 label="琚繚浜�:" prop="insuranceTypeCode"> - <ProFormText v-model.trim="detail.orderNo" /> + <ProFormItemV2 label="琚繚浜�:" prop="policyerName"> + <ProFormText v-model.trim="detail.policyerName" /> </ProFormItemV2> </ProFormColItem> </ProFormCol> </ProForm> </ChunkCell> <ChunkCell title="浜哄憳淇℃伅"> - <template #titleRight> + <template #titleRight v-if="detail.status !== InsurancePolicyStatusEnum.WaitEffect"> <el-button type="primary" @click="handleBatchChange">鎵规敼鐢宠</el-button> </template> <ProTableQueryFilterBar @on-reset="reset"> @@ -77,17 +74,32 @@ v-model="extraParamState.keyWord" style="width: 300px" placeholder="濮撳悕/韬唤璇佸彿/鎵嬫満鍙�" - @on-click-search="getBatchRefundInfoDetail" + @on-click-search="getInsuranceStaffList" > </SearchInput> </QueryFilterItem> </template> <template #btn> - <el-button @click="handleTemplateDownload()" link type="primary">妯℃澘涓嬭浇</el-button> - <el-button @click="handleImport()" type="primary">瀵煎叆</el-button> - <el-button @click="handleClear()" type="primary">娓呯┖鏁版嵁</el-button> - <el-button @click="handleDownloadPerson()" type="primary">浜哄憳娓呭崟涓嬭浇</el-button> - <el-button @click="handleDownloadOrder()" type="primary">淇濆崟涓嬭浇</el-button> + <template v-if="detail.status === InsurancePolicyStatusEnum.WaitEffect"> + <el-button @click="handleTemplateDownload()" link type="primary">妯℃澘涓嬭浇</el-button> + <BlFileUpload + :limitFileSize="10" + accept="xls,xlsx" + :showTip="false" + :show-file-list="false" + :on-success="handleUploadSuccess" + style="margin-right: 10px; margin-left: 10px" + > + <template #default> + <el-button icon="Plus" type="primary">瀵煎叆</el-button> + </template> + </BlFileUpload> + <el-button @click="handleClear()" type="primary">娓呯┖鏁版嵁</el-button> + </template> + <template v-else> + <el-button @click="handleDownloadPerson()" type="primary">涓嬭浇浜哄憳娓呭崟</el-button> + <el-button @click="handleDownloadOrder()" type="primary">涓嬭浇淇濆崟</el-button> + </template> </template> </ProTableQueryFilterBar> <ProTableV2 @@ -127,17 +139,22 @@ ProFormRadio, defineOperationBtns, useFormDialog, + BlFileUpload, + UploadUserFile, } from '@bole-core/components'; import { InsuranceOrderTempPath, insuranceTypeText, InsuredInstitutionEnum, InsuranceSchemeEnum, + InsurancePolicyStatusEnum, + InsurancePolicyStatusEnumText, } from '@/constants'; import ChangePersonInfoDialog from './ChangePersonInfoDialog.vue'; import * as insuranceOrderServices from '@/services/api/InsuranceOrder'; import { useQuery, useQueryClient } from '@tanstack/vue-query'; -import { downloadFileByUrl, OrderInputType } from '@bole-core/core'; +import { downloadFile, downloadFileByUrl, Message, OrderInputType } from '@bole-core/core'; +import { setOSSLink } from '@/utils'; defineOptions({ name: 'InsureOrderInfoView', @@ -151,53 +168,60 @@ }, { id: '2', - enCode: 'name', + enCode: 'gender', name: '鎬у埆', + width: 80, }, { id: '3', - enCode: 'name', + enCode: 'certType', name: '璇佷欢绫诲瀷', + width: 100, }, { id: '4', - enCode: 'idNumber', + enCode: 'certNo', name: '璇佷欢鍙风爜', + width: 180, }, { id: '5', - enCode: 'idNumber', + enCode: 'jobName', name: '闆囧憳宸ョ', }, { id: '6', - enCode: 'idNumber', + enCode: 'userEmploer', name: '鐢ㄥ伐鍗曚綅', }, { id: '7', - enCode: 'idNumber', + enCode: 'address', name: '鐢ㄥ伐鍦扮偣', }, { id: '8', - enCode: 'idNumber', + enCode: 'age', name: '骞撮緞', + width: 80, }, { id: '9', - enCode: 'idNumber', + enCode: 'birthDay', name: '鍑虹敓鏃ユ湡', + width: 120, }, { id: '10', - enCode: 'idNumber', + enCode: 'phone', name: '鎵嬫満鍙风爜', + width: 140, }, { id: '11', - enCode: 'idNumber', + enCode: 'serialNumber', name: '鐞嗚禂', + width: 100, }, ]; @@ -210,9 +234,10 @@ emits: { onClick: (role) => handleChangeInfo(role), }, - // extraProps: { - // hide: (row: API.InsuranceOrderListOutput) => !row.orderBillFile, - // }, + extraProps: { + hide: (row: API.GetInsuranceStaffPageTemplate) => + detail.value?.status !== InsurancePolicyStatusEnum.WaitEffect, + }, }, { data: { @@ -222,9 +247,10 @@ emits: { onClick: (role) => handleInsureClaimDetail(role), }, - // extraProps: { - // hide: (row: API.InsuranceOrderListOutput) => !row.orderBillFile, - // }, + extraProps: { + hide: (row: API.GetInsuranceStaffPageTemplate) => + !(row.serialNumber && detail.value?.status !== InsurancePolicyStatusEnum.WaitEffect), + }, }, ]); @@ -238,16 +264,16 @@ const state = reactive({ ...BaseState }); const { data: detail, isLoading } = useQuery({ - queryKey: ['insuranceOrderServices/getInsuranceOrderDetail', id], + queryKey: ['insuranceOrderServices/getInsurancePolicyHeadDto', id], queryFn: async () => { - return await insuranceOrderServices.getInsuranceOrderDetail( + return await insuranceOrderServices.getInsurancePolicyHeadDto( { id: id }, { showLoading: !state.loading, } ); }, - placeholderData: () => ({} as API.InsuranceOrderListOutput), + placeholderData: () => ({} as API.GetInsurancePageOutput), enabled: !!id, }); @@ -255,14 +281,14 @@ onMounted(async () => { await queryClient.ensureQueryData({ - queryKey: ['insuranceOrderServices/getInsuranceOrderDetail', id], + queryKey: ['insuranceOrderServices/getInsurancePolicyHeadDto', id], }); - await getBatchRefundInfoDetail(); + await getInsuranceStaffList(); state.loading = false; }); const { - getDataSource: getBatchRefundInfoDetail, + getDataSource: getInsuranceStaffList, proTableProps, paginationState, extraParamState, @@ -270,16 +296,16 @@ } = useTable( async ({ pageIndex, pageSize }, extraParamState) => { try { - let params: API.QueryInsuranceOrderPageInput = { + let params: API.GetInsuranceStaffListInput = { pageModel: { rows: pageSize, page: pageIndex, orderInput: extraParamState.orderInput, }, condition: extraParamState.keyWord, - // insurePolicyOperateHistoryId: id, + insurancePolicyId: id, }; - let res = await insuranceOrderServices.getInsuranceOrderPage(params, { + let res = await insuranceOrderServices.getInsuranceStaffList(params, { showLoading: !state.loading, }); return res; @@ -297,11 +323,57 @@ function handleTemplateDownload() { downloadFileByUrl(InsuranceOrderTempPath, '浜哄憳淇℃伅妯℃澘'); } -function handleClear() {} -function handleImport() {} +async function handleClear() { + try { + await Message.tipMessage('鏄惁娓呯┖浜哄憳淇℃伅'); + let res = await insuranceOrderServices.clearInsuranceStaffData({ + id: id, + }); + if (res) { + Message.successMessage('鎿嶄綔鎴愬姛'); + getInsuranceStaffList(paginationState.pageIndex); + } + } catch (error) {} +} +async function handleUploadSuccess(response: UploadUserFile) { + try { + // let res = await insuranceOrderServices.importInsuranceOrderData(response.url, { + // getResponse: true, + // responseType: 'blob', + // }); + // if (res?.data?.size) { + // await Message.tipMessage('瀛樺湪閿欒鏁版嵁锛屾槸鍚﹀鍑猴紵'); + // downloadFile(res.data, `閿欒浜哄憳鍚嶅崟`, 'xlsx'); + // } + // queryClient.invalidateQueries({ + // queryKey: ['insuranceOrderServices/getInsuranceStaffList'], + // }); + // getInsuranceStaffList(); + } catch (error) {} +} -function handleDownloadPerson() {} -function handleDownloadOrder() {} +async function handleDownloadPerson() { + try { + if (paginationState.total === 0) { + Message.warnMessage('娌℃湁鏁版嵁鍙互瀵煎嚭鍝'); + return; + } + let res = await insuranceOrderServices.getInsuranceStaffListExport( + { id: id }, + { + responseType: 'blob', + getResponse: true, + } + ); + if (res) { + downloadFile(res.data, `浜哄憳娓呭崟`, 'xlsx'); + } + } catch (error) {} +} +function handleDownloadOrder() { + downloadFileByUrl(setOSSLink(detail.value?.insureBillUrl)); +} + function handleBatchChange() { router.push({ name: 'BatchChange', @@ -311,22 +383,45 @@ }); } -const { dialogProps, handleEdit, editForm } = useFormDialog({ - onConfirm: changeInfo, +const { dialogProps, handleEdit, editForm, dialogState } = useFormDialog({ + onConfirm: updateInsuranceStaffInfo, defaultFormParams: { + id: '', name: '', + idNumber: '', + phone: '', }, + closeAfterConfirm: false, }); -function handleChangeInfo(row: API.InsuranceOrderListOutput) { +function handleChangeInfo(row: API.GetInsuranceStaffPageTemplate) { handleEdit({ + id: row.id, name: row.name, + idNumber: row.certNo, + phone: row.phone, }); } -async function changeInfo() {} +async function updateInsuranceStaffInfo() { + try { + let params: API.UpdateInsuranceStaffInfoInput = { + insurancePolicyId: id, + id: editForm.id, + name: editForm.name, + idNumber: editForm.idNumber, + phone: editForm.phone, + }; + let res = await insuranceOrderServices.updateInsuranceStaffInfo(params); + if (res) { + Message.successMessage('淇敼鎴愬姛'); + dialogState.dialogVisible = false; + getInsuranceStaffList(paginationState.pageIndex); + } + } catch (error) {} +} -function handleInsureClaimDetail(row: API.InsuranceOrderListOutput) { +function handleInsureClaimDetail(row: API.GetInsuranceStaffPageTemplate) { router.push({ name: 'InsuranceClaimDetail', params: { diff --git a/src/views/Home/components/UploadInsurePersonDialog.vue b/src/views/Home/components/UploadInsurePersonDialog.vue index b5c4241..0a4d176 100644 --- a/src/views/Home/components/UploadInsurePersonDialog.vue +++ b/src/views/Home/components/UploadInsurePersonDialog.vue @@ -3,20 +3,18 @@ title="涓婁紶鎶曚繚浜哄憳娓呭崟" v-model="innerVisible" destroy-on-close + :close-on-click-modal="false" + :close-on-press-escape="false" draggable bodyNoPaddingBottom @close="onDialogClose" width="600px" > <ProForm :model="innerForm" ref="dialogForm" label-width="100px"> - <ProFormItemV2 - label="鎵规鍙凤細" - prop="materialName" - :check-rules="[{ message: '璇疯緭鍏ユ壒娆″彿' }]" - > + <ProFormItemV2 label="鎵规鍙凤細" prop="serialNum" :check-rules="[{ message: '璇疯緭鍏ユ壒娆″彿' }]"> <ProFormText placeholder="璇疯緭鍏ユ壒娆″彿" - v-model.trim="innerForm.orderNo" + v-model.trim="innerForm.serialNum" :maxlength="30" ></ProFormText> </ProFormItemV2> @@ -57,6 +55,7 @@ ProFormUpload, } from '@bole-core/components'; import { FormInstance } from 'element-plus'; +import _ from 'lodash'; defineOptions({ name: 'UploadInsurePersonDialog', @@ -65,7 +64,7 @@ type Props = { modelValue: boolean; form?: { - orderNo: string; + serialNum: string; url: UploadUserFile[]; }; }; diff --git a/src/views/Home/components/UploadStampFileDialog.vue b/src/views/Home/components/UploadStampFileDialog.vue index eac7812..2ce37f7 100644 --- a/src/views/Home/components/UploadStampFileDialog.vue +++ b/src/views/Home/components/UploadStampFileDialog.vue @@ -14,7 +14,7 @@ prop="url" :check-rules="[{ message: '璇蜂笂浼犳枃浠�', type: 'upload' }]" > - <ProFormUpload v-model:file-url="innerForm.url" accept="pdf,jpg,jpeg,png"> + <ProFormUpload v-model:file-url="innerForm.url" accept="pdf,jpg/jpeg,png"> <template #tip> <div> <el-text type="danger">鏀寔pdf銆乯pg銆乯epg銆乸ng鍥剧墖</el-text> diff --git a/src/views/Home/constants/index.ts b/src/views/Home/constants/index.ts index 51e1480..ad89815 100644 --- a/src/views/Home/constants/index.ts +++ b/src/views/Home/constants/index.ts @@ -2,92 +2,92 @@ export const columns = defineColumns([ { - id: '2', - enCode: 'channel', + id: '1', + enCode: 'serialNum', name: '鎵规鍙�', width: 160, }, { - id: '3', - enCode: 'orderNo', + id: '2', + enCode: 'insureBillNo', name: '淇濆崟鍙�', width: 160, }, { - id: '4', - enCode: 'orderNo', + id: '3', + enCode: 'insurerName', name: '鎶曚繚浜�', width: 160, }, { - id: '5', - enCode: 'orderNo', + id: '4', + enCode: 'policyerName', name: '琚繚浜�', width: 160, }, { - id: '6', - enCode: 'insuranceBeginTime', + id: '5', + enCode: 'effectStartTime', name: '淇濋櫓璧锋湡', width: 160, }, { - id: '7', - enCode: 'insuranceEndTime', + id: '6', + enCode: 'effectEndTime', name: '淇濋櫓姝㈡湡', width: 160, }, { - id: '8', - enCode: 'insuredInstitution', + id: '7', + enCode: 'insuranceOrg', name: '鍙備繚鏈烘瀯', width: 160, }, { - id: '9', + id: '8', enCode: 'insuranceScheme', name: '鎶曚繚鏂规', width: 160, }, { - id: '10', - enCode: 'insuranceType', + id: '9', + enCode: 'insurancePeriod', name: '鎶曚繚鏂瑰紡', width: 160, }, { - id: '11', - enCode: 'insuranceType', + id: '10', + enCode: 'insureCount', name: '鎶曚繚浜烘暟', width: 160, }, { - id: '12', - enCode: 'insuranceType', + id: '11', + enCode: 'sumInsured', name: '鎬讳繚棰�(鍏�)', width: 200, }, { - id: '13', - enCode: 'insuranceType', + id: '12', + enCode: 'amount', name: '鎬讳繚璐�(鍏�)', width: 160, }, { - id: '14', - enCode: 'createTime', + id: '13', + enCode: 'creationTime', name: '鏈�杩戝鍏ユ棩鏈�', width: 160, }, { - id: '15', - enCode: 'insuranceType', + id: '14', + enCode: 'status', name: '鎶曚繚鐘舵��', width: 160, }, { - id: '16', - enCode: 'insuranceType', + id: '15', + enCode: 'claimCount', name: '鐞嗚禂鏁伴噺', width: 160, }, diff --git a/src/views/InsuranceClaim/components/InsuranceClaimView.vue b/src/views/InsuranceClaim/components/InsuranceClaimView.vue index 22591b9..d3ff58f 100644 --- a/src/views/InsuranceClaim/components/InsuranceClaimView.vue +++ b/src/views/InsuranceClaim/components/InsuranceClaimView.vue @@ -289,51 +289,50 @@ </div> <ClaimPicDemoView /> </div> - <div class="chuck-add-or-edit-actions"> + <div class="chuck-add-or-edit-actions" v-if="!isDetail"> <el-button @click="handleBack">鍏抽棴</el-button> - <el-button v-if="!isDetail" type="primary" @click="handleSubmit">鎻愪氦</el-button> + <el-button type="primary" @click="handleSubmit">鎻愪氦</el-button> </div> </ProForm> </ChunkCell> - <!-- <ChunkCell title="鐞嗚禂缁撴灉"> - <ProForm :model="form" ref="claimFormRef" label-width="120px"> - <ProFormCol> - <ProFormColItem :span="6"> - <ProFormItemV2 label="鐞嗚禂缁撴灉:" prop="claimResult"> - <ProFormSelect - placeholder="璇烽�夋嫨鐞嗚禂缁撴灉" - :value-enum="InsuranceClaimResultEnumText" - clearable - v-model="form.claimResult" - ></ProFormSelect> - </ProFormItemV2> - </ProFormColItem> - <ProFormColItem :span="6"> - <ProFormItemV2 label="缁�/鎾ゆ鏃堕棿:" prop="claimResultTime"> - <ProFormDatePicker - v-model="form.claimResultTime" - type="datetime" - format="YYYY-MM-DD" - value-format="YYYY-MM-DD" - placeholder="璇烽�夋嫨缁�/鎾ゆ鏃堕棿" - ></ProFormDatePicker> - </ProFormItemV2> - </ProFormColItem> - </ProFormCol> - <ProFormItemV2 label="涓嬫閲戦:" prop="downPaymentAmount"> - <ProFormInputNumber - v-model="form.downPaymentAmount" - :controls="false" - :min="0" - :precision="2" - ></ProFormInputNumber> - </ProFormItemV2> - <div class="chuck-add-or-edit-actions"> - <el-button @click="handleBack">鍏抽棴</el-button> - <el-button type="primary" @click="handleSubmit">鎻愪氦</el-button> - </div> - </ProForm> - </ChunkCell> --> + <ChunkCell title="鐞嗚禂缁撴灉" v-if="isDetail"> + <ProForm :model="form" ref="claimFormRef" label-width="120px" :is-read="isDetail"> + <ProFormCol> + <ProFormColItem :span="6"> + <ProFormItemV2 label="鐞嗚禂缁撴灉:" prop="claimResult"> + <ProFormSelect + placeholder="璇烽�夋嫨鐞嗚禂缁撴灉" + :value-enum="InsuranceClaimResultEnumText" + clearable + v-model="form.claimResult" + ></ProFormSelect> + </ProFormItemV2> + </ProFormColItem> + <ProFormColItem :span="6"> + <ProFormItemV2 label="缁�/鎾ゆ鏃堕棿:" prop="claimResultTime"> + <ProFormDatePicker + v-model="form.claimResultTime" + type="datetime" + format="YYYY-MM-DD" + value-format="YYYY-MM-DD" + placeholder="璇烽�夋嫨缁�/鎾ゆ鏃堕棿" + ></ProFormDatePicker> + </ProFormItemV2> + </ProFormColItem> + </ProFormCol> + <ProFormItemV2 label="涓嬫閲戦:" prop="downPaymentAmount"> + <ProFormInputNumber + v-model="form.downPaymentAmount" + :controls="false" + :min="0" + :precision="2" + ></ProFormInputNumber> + </ProFormItemV2> + <div class="chuck-add-or-edit-actions"> + <el-button @click="handleBack">鍏抽棴</el-button> + </div> + </ProForm> + </ChunkCell> </AppScrollContainer> <SelectOrderDialog v-bind="dialogProps" /> </LoadingLayout> -- Gitblit v1.9.1