From bd20a385dd86cf32735578c4c140a0aebf758e45 Mon Sep 17 00:00:00 2001
From: wupengfei <834520024@qq.com>
Date: 星期四, 15 五月 2025 17:15:07 +0800
Subject: [PATCH] fix: bug

---
 src/views/EnterpriseInfo/components/WithdrawalRecordView.vue |  119 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 119 insertions(+), 0 deletions(-)

diff --git a/src/views/EnterpriseInfo/components/WithdrawalRecordView.vue b/src/views/EnterpriseInfo/components/WithdrawalRecordView.vue
new file mode 100644
index 0000000..69a6cf5
--- /dev/null
+++ b/src/views/EnterpriseInfo/components/WithdrawalRecordView.vue
@@ -0,0 +1,119 @@
+<template>
+  <LoadingLayout :loading="state.loading">
+    <AppContainer>
+      <ProTableV2 v-bind="proTableProps" :columns="column" :operationBtns="operationBtns">
+        <template #operationBtn-checkBtn="{ data, row }">
+          <PreviewBtnV2
+            class="pro-table-operation-btn"
+            :url="convertApi2FormUrlBySeparator(row.checkFileUrl ?? '')"
+            preview-btn-text="鏌ョ湅鍑瘉"
+          />
+        </template>
+      </ProTableV2>
+    </AppContainer>
+  </LoadingLayout>
+</template>
+
+<script setup lang="ts">
+import {
+  AppContainer,
+  useTable,
+  ProTableV2,
+  defineOperationBtns,
+  PreviewBtnV2,
+} from '@bole-core/components';
+import { convertApi2FormUrlBySeparator } from '@/utils';
+import { OrderInputType } from '@bole-core/core';
+import * as parkBountyApplyServices from '@/services/api/ParkBountyApply';
+import { EnterpriseRechargeStatusEnum } from '@/constants';
+
+defineOptions({
+  name: 'WithdrawalRecordView',
+});
+
+const column: API.CustomModuleColumnDto[] = [
+  {
+    id: '1',
+    enCode: 'creationTime',
+    name: '鐢宠鎻愮幇鏃ユ湡',
+  },
+  {
+    id: '2',
+    enCode: 'checkTime',
+    name: '瀹℃牳閫氳繃鏃ユ湡',
+  },
+  {
+    id: '3',
+    enCode: 'amount',
+    name: '鎻愮幇閲戦',
+  },
+  {
+    id: '4',
+    enCode: 'remainAmount',
+    name: '璧勯噾浣欓',
+  },
+];
+
+const operationBtns = defineOperationBtns([
+  {
+    data: {
+      enCode: 'checkBtn',
+      name: '鏌ョ湅鍑瘉',
+    },
+  },
+]);
+
+const route = useRoute();
+const router = useRouter();
+const id = route.params.id as string;
+const BaseState = {
+  loading: true,
+};
+
+const state = reactive({ ...BaseState });
+
+const {
+  getDataSource: getList,
+  proTableProps,
+  paginationState,
+  extraParamState,
+} = useTable(
+  async ({ pageIndex, pageSize }, extraParamState) => {
+    try {
+      let params: API.GetEnterpriseDrawWithListInput = {
+        pageModel: {
+          rows: pageSize,
+          page: pageIndex,
+          orderInput: extraParamState.orderInput,
+        },
+        checkStatus: EnterpriseRechargeStatusEnum.CheckPassed,
+        enterpriseId: id,
+      };
+      let res = await parkBountyApplyServices.getEnterpriseDrawWithList(params, {
+        showLoading: !state.loading,
+      });
+      return res;
+    } catch (error) {}
+  },
+  {
+    defaultExtraParams: {
+      orderInput: [{ property: 'creationTime', order: OrderInputType.Desc }],
+    },
+    columnsRenderProps: {
+      creationTime: { type: 'date', format: 'YYYY-MM-DD' },
+      checkTime: { type: 'date', format: 'YYYY-MM-DD' },
+      amount: { type: 'money' },
+      remainAmount: { type: 'money' },
+    },
+  }
+);
+
+onMounted(async () => {
+  await getList();
+  state.loading = false;
+});
+</script>
+
+<style lang="scss" scoped>
+@use '@/style/common.scss' as *;
+</style>

--
Gitblit v1.9.1