wupengfei
2025-11-08 7738caf497efdfb61f5e262d2a854fc23f86bf88
src/views/EmploymentManage/CheckReceiveTaskDetail.vue
@@ -1,5 +1,5 @@
<template>
  <LoadingLayout :loading="state.loading">
  <LoadingLayout v-loading="state.loading">
    <AppContainer>
      <el-card class="query-filter-bar-wrapper" shadow="never">
        <ProForm :model="taskInfo" is-read>
@@ -16,7 +16,7 @@
            </ProFormColItem>
            <ProFormColItem :span="8">
              <ProFormItemV2 label="服务费金额:">
                {{ `${taskInfo.serviceFee}${EnumBillingMethodUnitText[taskInfo.billingMethod]}` }}
                {{ OrderUtils.getServiceFeeText(taskInfo.serviceFee, taskInfo.billingMethod) }}
              </ProFormItemV2>
            </ProFormColItem>
          </ProFormCol>
@@ -69,8 +69,9 @@
import * as taskCheckReceiveServices from '@/services/api/taskCheckReceive';
import * as taskServices from '@/services/api/task';
import { useQuery } from '@tanstack/vue-query';
import { OrderUtils } from '@/utils';
import { CheckReceiveTaskDetailColumns } from './constants';
import { EnumBillingMethodUnitText } from '@/constants';
import { EnumBillingMethodUnitText, EnumBillingMethod, EnumBillingMethodText } from '@/constants';
import dayjs from 'dayjs';
import CheckManageDialog from './components/CheckManageDialog.vue';
import ManualCheckManageDialog from './components/ManualCheckManageDialog.vue';
@@ -90,7 +91,10 @@
    },
    extraProps: {
      hide: (row: API.GetCheckReceiveTaskQueryResultItem) =>
        row.checkReceiveStatus === EnumTaskCheckReceiveStatus.Completed,
        !(
          row.checkReceiveStatus === EnumTaskCheckReceiveStatus.WaitCheckReceive &&
          row.checkReceiveMethods.includes(EnumTaskCheckReceiveMethod.CheckIn)
        ),
    },
  },
  {
@@ -122,6 +126,7 @@
const BaseState = {
  loading: true,
  checkReceiveMethods: [] as any as EnumTaskCheckReceiveMethod[],
};
const state = reactive({ ...BaseState });
@@ -157,6 +162,7 @@
      let res = await taskCheckReceiveServices.getCheckReceiveTask(params, {
        showLoading: !state.loading,
      });
      state.checkReceiveMethods = res.objectData?.checkReceiveMethods;
      return res;
    } catch (error) {}
  },
@@ -173,15 +179,25 @@
);
function openDialog(row: API.GetCheckReceiveTaskQueryResultItem, isDetail = false) {
  // if (state.checkReceiveMethod === EnumTaskCheckReceiveMethod.CheckIn) {
  //   handleManualEdit({
  //     id: row.id,
  //   });
  // } else {
  handleEdit({
    id: row.id,
    tabType: 'signRecord',
    checkReceiveMethods: state.checkReceiveMethods,
    isDetail,
  });
  // }
}
const { dialogProps, handleEdit } = useFormDialog({
  defaultFormParams: {
    id: '',
    tabType: '',
    checkReceiveMethods: [] as any as EnumTaskCheckReceiveMethod[],
    isDetail: false,
  },
});
@@ -189,7 +205,6 @@
const { dialogProps: dialogManualProps, handleEdit: handleManualEdit } = useFormDialog({
  defaultFormParams: {
    id: '',
    isDetail: false,
  },
});
</script>