diff --git a/fund-admin/src/api/receivable.js b/fund-admin/src/api/receivable.js new file mode 100644 index 0000000..aa66c2b --- /dev/null +++ b/fund-admin/src/api/receivable.js @@ -0,0 +1,76 @@ +import request from '../utils/request' + +/** + * 获取应收款列表(分页) + */ +export const getReceivableList = (params) => { + return request({ + url: '/proj/api/v1/receivable/list', + method: 'get', + params + }) +} + +/** + * 获取应收款详情 + */ +export const getReceivableById = (receivableId) => { + return request({ + url: `/proj/api/v1/receivable/${receivableId}`, + method: 'get' + }) +} + +/** + * 创建应收款 + */ +export const createReceivable = (data) => { + return request({ + url: '/proj/api/v1/receivable', + method: 'post', + data + }) +} + +/** + * 更新应收款 + */ +export const updateReceivable = (receivableId, data) => { + return request({ + url: `/proj/api/v1/receivable/${receivableId}`, + method: 'put', + data + }) +} + +/** + * 删除应收款 + */ +export const deleteReceivable = (receivableId) => { + return request({ + url: `/proj/api/v1/receivable/${receivableId}`, + method: 'delete' + }) +} + +/** + * 记录收款 + */ +export const recordPayment = (receivableId, amount) => { + return request({ + url: `/proj/api/v1/receivable/${receivableId}/payment`, + method: 'post', + params: { amount } + }) +} + +/** + * 更新应收款状态 + */ +export const updateReceivableStatus = (receivableId, status) => { + return request({ + url: `/proj/api/v1/receivable/${receivableId}/status`, + method: 'put', + params: { status } + }) +} diff --git a/fundplatform b/fundplatform index 743d703..91ba187 160000 --- a/fundplatform +++ b/fundplatform @@ -1 +1 @@ -Subproject commit 743d7038c11151d9e405f8a99f750ba48b143a17 +Subproject commit 91ba1879f285919f8c9d01f74e2a5c6a1842511e