2025-09-15

This commit is contained in:
2025-09-15 21:03:25 +08:00
parent 7f7ef99c18
commit 178bd0d1e9
26 changed files with 1606 additions and 25 deletions

24
api/payment.js Normal file
View File

@@ -0,0 +1,24 @@
import { http } from "../util/api"
// 支付相关API
export const paymentAPI = {
// 获取支付方式
getMethods: () => http.get('/payment/methods'),
// 创建支付订单
createOrder: (data) => http.post('/payment/create-order', data),
// 查询支付状态
queryStatus: (outTradeNo) => http.get(`/payment/query-status/${outTradeNo}`),
getOrder: () => http.get('/payment/check-status'),
// 获取支付记录
getOrders: (params = {}) => http.get('/payment/orders', {
params
})
}
export default {
paymentAPI
}