|  |  |  | 
|---|
|  |  |  | import { CheckManageColumns } from './constants'; | 
|---|
|  |  |  | import * as taskCheckReceiveServices from '@/services/api/taskCheckReceive'; | 
|---|
|  |  |  | import { ModelValueType } from 'element-plus'; | 
|---|
|  |  |  | import { format } from '@/utils'; | 
|---|
|  |  |  | import { downloadFileByUrl, format, setOSSLink } from '@/utils'; | 
|---|
|  |  |  | import { EnumTaskCheckReceiveStatusText } from '@/constants'; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | defineOptions({ | 
|---|
|  |  |  | 
|---|
|  |  |  | columnsRenderProps: { | 
|---|
|  |  |  | checkReceiveStatus: { type: 'enum', valueEnum: EnumTaskCheckReceiveStatusText }, | 
|---|
|  |  |  | billingMethod: { type: 'enum', valueEnum: EnumBillingMethodText }, | 
|---|
|  |  |  | checkReceiveMethod: { type: 'enum', valueEnum: EnumTaskCheckReceiveMethodText }, | 
|---|
|  |  |  | serviceFee: { | 
|---|
|  |  |  | type: 'money', | 
|---|
|  |  |  | formatter: (row) => { | 
|---|
|  |  |  | return `${row.serviceFee}${EnumBillingMethodUnitText[row.billingMethod]}`; | 
|---|
|  |  |  | return row.billingMethod === EnumBillingMethod.Face | 
|---|
|  |  |  | ? '' | 
|---|
|  |  |  | : `${row.serviceFee}${EnumBillingMethodUnitText[row.billingMethod]}`; | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | settlementCycle: { type: 'enum', valueEnum: EnumSettlementCycleText }, | 
|---|
|  |  |  | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | function handleExport(row: API.GetCheckReceiveTasksQueryResultItem) {} | 
|---|
|  |  |  | async function handleExport(row: API.GetCheckReceiveTasksQueryResultItem) { | 
|---|
|  |  |  | try { | 
|---|
|  |  |  | let params: API.ExportTaskCheckReceiveTaskUsersCommand = { | 
|---|
|  |  |  | id: row.id, | 
|---|
|  |  |  | }; | 
|---|
|  |  |  | let res = await taskCheckReceiveServices.exportTaskCheckReceiveTaskUsers(params); | 
|---|
|  |  |  | if (res) { | 
|---|
|  |  |  | downloadFileByUrl(setOSSLink(res)); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } catch (error) {} | 
|---|
|  |  |  | } | 
|---|
|  |  |  | </script> | 
|---|