<template>
|
<LoadingLayout>
|
<AppContainer>
|
<PageFormLayout title="申报详情">
|
<DetailView :form="form">
|
<DeclareEnterpriseTableView ref="tableRef"></DeclareEnterpriseTableView>
|
</DetailView>
|
<template #footer>
|
<el-button @click="handleBack">关闭</el-button>
|
</template>
|
</PageFormLayout>
|
</AppContainer>
|
</LoadingLayout>
|
</template>
|
|
<script setup lang="ts">
|
import { AppContainer, LoadingLayout, UploadUserFile, PageFormLayout } from '@bole-core/components';
|
import DetailView from '@/components/commonView/DetailView.vue';
|
import DeclareEnterpriseTableView from '@/components/commonView/DeclareEnterpriseTableView.vue';
|
import { useQuery } from '@tanstack/vue-query';
|
import * as parkBountyApplyServices from '@/services/api/ParkBountyApply';
|
import { convertApi2FormUrlOnlyOne } from '@/utils';
|
import { useRouteView } from '@/hooks';
|
|
defineOptions({
|
name: 'RewardDeclareDetail',
|
});
|
|
const route = useRoute();
|
const { closeViewPush } = useRouteView();
|
const id = route.params?.id as string;
|
const form = reactive({
|
searchKeyWord: '',
|
batchNo: '',
|
parkName: '',
|
parkTypeName: '',
|
applyMonth: '',
|
applySumAmount: 0,
|
enterpriseTaxSubFileUrl: [] as UploadUserFile[],
|
enterpriseOperateFileUrl: [] as UploadUserFile[],
|
bountyAssignFileUlr: [] as UploadUserFile[],
|
bountyCollectFileUrl: [] as UploadUserFile[],
|
});
|
|
const tableRef = ref<InstanceType<typeof DeclareEnterpriseTableView>>();
|
|
const { data: detail, isLoading } = useQuery({
|
queryKey: ['parkBountyApplyServices/getParkBountyApplyDetail', id],
|
queryFn: async () => {
|
return await parkBountyApplyServices.getParkBountyApplyDetail(
|
{ parkBountyApplyId: id, searchKeyWord: form.searchKeyWord },
|
{
|
showLoading: false,
|
}
|
);
|
},
|
placeholderData: () => ({} as API.GetParkBountyApplyInfoOutput),
|
onSuccess(data) {
|
form.batchNo = data.parkBountyApplyBaseInfo.batchNo;
|
form.parkName = data.parkBountyApplyBaseInfo.parkName;
|
form.parkTypeName = data.parkBountyApplyBaseInfo.parkTypeName;
|
form.applyMonth = data.parkBountyApplyBaseInfo.applyMonth;
|
form.applySumAmount = data.parkBountyApplyBaseInfo.applySumAmount;
|
form.enterpriseTaxSubFileUrl = convertApi2FormUrlOnlyOne(
|
data.parkBountyApplyBaseInfo?.enterpriseTaxSubFileUrl
|
);
|
form.enterpriseOperateFileUrl = convertApi2FormUrlOnlyOne(
|
data.parkBountyApplyBaseInfo?.enterpriseOperateFileUrl
|
);
|
form.bountyAssignFileUlr = convertApi2FormUrlOnlyOne(
|
data.parkBountyApplyBaseInfo?.bountyAssignFileUlr
|
);
|
form.bountyCollectFileUrl = convertApi2FormUrlOnlyOne(
|
data.parkBountyApplyBaseInfo?.bountyCollectFileUrl
|
);
|
|
tableRef.value?.getList();
|
},
|
});
|
|
function handleBack() {
|
closeViewPush(route, {
|
name: 'RewardGrant',
|
});
|
}
|
</script>
|
|
<style lang="scss" scoped>
|
@use '@/style/common.scss' as *;
|
</style>
|