...
|
...
|
@@ -8,12 +8,14 @@ |
|
|
|
|
|
const api = global.yoho.API;
|
|
|
|
|
|
//获取支付宝等平台支付方式列表
|
|
|
const getPayProvider = () => {
|
|
|
return api.get('', {
|
|
|
method: 'web.SpaceOrders.getPaymentList'
|
|
|
});
|
|
|
};
|
|
|
|
|
|
//获取单个支付方式相关详细信息
|
|
|
const getPaymentInfo = (id) => {
|
|
|
return api.get('', {
|
|
|
method: 'web.SpaceOrders.getPaymentById',
|
...
|
...
|
@@ -21,6 +23,7 @@ const getPaymentInfo = (id) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
/*获取上次使用的支付方式*/
|
|
|
const getBankByOrder = (code) => {
|
|
|
return api.get('', {
|
|
|
method: 'web.SpaceOrders.getOrderPayBank',
|
...
|
...
|
@@ -28,6 +31,7 @@ const getBankByOrder = (code) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
/*记录支付方式*/
|
|
|
const setOrderPayBank = (code, payment, bankCode) => {
|
|
|
return api.get('', {
|
|
|
method: 'web.SpaceOrders.addOrderPayBank',
|
...
|
...
|
@@ -37,6 +41,7 @@ const setOrderPayBank = (code, payment, bankCode) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
/*更改支付方式*/
|
|
|
const updateOrderPayBank = (code, payment, bankCode) => {
|
|
|
return api.get('', {
|
|
|
method: 'web.SpaceOrders.modifyOrderPayBank',
|
...
|
...
|
@@ -46,6 +51,7 @@ const updateOrderPayBank = (code, payment, bankCode) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
/*发送支付确认*/
|
|
|
const sendPayConfirm = (code, payment, uid) => {
|
|
|
return api.get('', {
|
|
|
method: 'app.SpaceOrders.payConfirm',
|
...
|
...
|
@@ -55,6 +61,7 @@ const sendPayConfirm = (code, payment, uid) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
/*选择支付,校验时间间隔,插入数据,为用户取消订单做准备<用户支付取消订单,10分钟间隔>。*/
|
|
|
const savePrePayInfo = (code, payment, uid) => {
|
|
|
return api.get('', {
|
|
|
method: 'app.order.savePrePayInfo',
|
...
|
...
|
|