Merge commit 'b0b6c30'

This commit is contained in:
2026-05-22 11:10:54 +08:00
commit 78bbe7893f
3 changed files with 33 additions and 6 deletions

View File

@ -3,4 +3,9 @@ import { request } from '@/api';
//获取资金明细列表
export const getFundDetailListApi = (params: any) => {
return request.get('/user/FundFlowRecords', {...params})
}
//获取枚举字典选项
export const getEnumDicOptionsApi = () => {
return request.get('/user/getEnumDicOptions', {})
}

View File

@ -28,7 +28,7 @@ import { usePageLoading } from '@/composables/useLoading'
//
import { search, tableColumns } from './options'
//
import { getFundDetailListApi } from '@/api/modules/funding/fundDetail'
import { getFundDetailListApi, getEnumDicOptionsApi } from '@/api/modules/funding/fundDetail'
import { getRecentSevenDays, utcToUtc8 } from '@/utils/handleTime.ts'
//
@ -41,9 +41,24 @@ const searchOptions = ref(search)
const searchForm = ref({
username: '',
subAccountId: '',
type: '',
startTime: initTime.start,
endTime: initTime.end,
})
/**
* @description: 获取操作类型枚举选项
*/
const getEnumDicOptions = async () => {
const res: any = await getEnumDicOptionsApi()
const typeIndex = searchOptions.value.findIndex((item: any) => item.prop === 'type')
if (typeIndex !== -1 && res) {
searchOptions.value[typeIndex].options = res.map((item: any) => ({
label: item.value,
value: item.id
}))
}
}
const { loading, startLoading, stopLoading } = usePageLoading()
/**
* @description: 定义表格数据
@ -77,6 +92,7 @@ const getFundDetailList = async () => {
: '2026-03-15 23:59:59',
user_name: searchForm.value.username,
account_id: searchForm.value.subAccountId,
type: searchForm.value.type,
}
//
const data: any = await getFundDetailListApi(params)
@ -106,7 +122,8 @@ const getFundDetailList = async () => {
/**
* @description: 页面加载完成需要请求的数据
*/
onMounted(() => {
onMounted(async () => {
await getEnumDicOptions()
getFundDetailList()
})
/**
@ -119,6 +136,7 @@ const handleReset = () => {
searchForm.value = {
username: '',
subAccountId: '',
type: '',
startTime: initTime.start,
endTime: initTime.end,
}

View File

@ -21,10 +21,14 @@ export const search = [
width: '220px',
},
//操作类型
// { prop: 'type', label: '操作类型', type: 'select' as const, placeholder: '请选择操作类型', width: '140px', options: [
// {label:"充值",value:"1"},
// {label:"提现",value:"2"},
// ] },
{
prop: 'type',
label: '操作类型',
type: 'select' as const,
placeholder: '请选择操作类型',
width: '140px',
options: []
},
//钱包
// { prop: 'wallet', label: '钱包', type: 'select' as const, placeholder: '请选择钱包', width: '140px', options: [
// {label:"主钱包",value:"1"},