| | |
| | | useTable, |
| | | defineOperationBtns, |
| | | } from '@bole-core/components'; |
| | | // import * as flexEnterpriseServices from '@/services/api/FlexEnterprise'; |
| | | import { DistributionDetailColumns } from '../constants'; |
| | | import { FlexEnterpriseSettingStatus } from '@/constants'; |
| | | import * as taskServices from '@/services/api/task'; |
| | | import { usePersonalUserTransactions } from '../hooks/financeHooks'; |
| | | |
| | | defineOptions({ |
| | | name: 'DistributionDetailView', |
| | |
| | | |
| | | const state = reactive({ ...BaseState }); |
| | | |
| | | const { getList, proTableProps } = usePersonalUserTransactions({ |
| | | type: EnumUserWalletTransactionType.Withdraw, |
| | | }); |
| | | |
| | | onMounted(async () => { |
| | | await getList(); |
| | | state.loading = false; |
| | | }); |
| | | |
| | | const { |
| | | getDataSource: getList, |
| | | proTableProps, |
| | | paginationState, |
| | | extraParamState, |
| | | reset, |
| | | } = useTable( |
| | | async ({ pageIndex, pageSize }, extraParamState) => { |
| | | try { |
| | | let params: API.GetFlexEnterpriseInput = { |
| | | pageModel: { |
| | | rows: pageSize, |
| | | page: pageIndex, |
| | | orderInput: extraParamState.orderInput, |
| | | }, |
| | | flexEnterpriseSettingStatus: extraParamState.flexEnterpriseSettingStatus, |
| | | searchWord: extraParamState.searchWord, |
| | | }; |
| | | |
| | | let res = await flexEnterpriseServices.getFlexEnterpriseList(params, { |
| | | showLoading: !state.loading, |
| | | }); |
| | | return res; |
| | | } catch (error) { |
| | | console.log('error: ', error); |
| | | } |
| | | }, |
| | | { |
| | | defaultExtraParams: { |
| | | searchWord: '', |
| | | orderInput: [{ property: 'id', order: EnumPagedListOrder.Desc }], |
| | | flexEnterpriseSettingStatus: '' as any as FlexEnterpriseSettingStatus, |
| | | }, |
| | | queryKey: ['flexEnterpriseServices/getFlexEnterpriseList'], |
| | | columnsRenderProps: {}, |
| | | } |
| | | ); |
| | | </script> |