import request from '@/utils/request'
import { PageType, StrAnyObj } from '@/typings'

// 资金账户分页
export function getPageApi(params: StrAnyObj): Promise<PageType<StrAnyObj>> {
  return request.get('/capitalAccount/getPage', params)
}

// 资金账户明细
export function getDetailApi(params: StrAnyObj): Promise<StrAnyObj> {
  return request.get('/capitalAccount/getDetail', params)
}

// 资金账户新增
export function addApi(data: StrAnyObj): Promise<void> {
  return request.post('/capitalAccount/add', data)
}

// 资金账户编辑
export function editApi(data: StrAnyObj): Promise<void> {
  return request.post('/capitalAccount/edit', data)
}

// 资金账户删除
export function deleteApi(data: StrAnyObj): Promise<void> {
  return request.post('/capitalAccount/delete', data)
}
