This commit is contained in:
唐明明
2023-02-13 11:58:29 +08:00
parent da7b903547
commit 8d8c14ec66
33 changed files with 879 additions and 90 deletions

View File

@@ -11,6 +11,7 @@ import router from '../router'
// 基础配置
const config = {
apiUrl : 'https://douhuo.douhuofalv.com/api/',
// apiUrl : 'https://api.douhuotest.douhuofalv.com/api/', //测试环境
timeout : 60000
}
@@ -50,7 +51,6 @@ const request = (parameter, hideLoding = true) => {
updateToken('token', res.header.Authorization)
}
if(res.statusCode === 200){
uni.hideLoading()
const resolveData = res.data
if(resolveData.status_code === 200) {
resolve(resolveData.data)
@@ -146,6 +146,7 @@ const loginHint = () => {
if( loginHintState ) return
if(!loginHintState) loginHintState = true
updateToken('')
uni.hideLoading()
uni.showModal({
title: '登录提示',
content: '您的登录信息已过期,请重新登录',

View File

@@ -33,21 +33,21 @@ const zf = (data) =>{
})
}
// 自由服务包详情
// 自由服务包详情
const recharge = () =>{
return request({
url: "app/services/recharge"
})
}
// // 自由服务包支付
// 自由服务包支付
const zyPay = (id) =>{
return request({
url: "app/services/recharge/"+id+"/pay",
url: "app/services/recharge/" + id + "/pay",
method:'post'
})
}
// 服务包详情
// 服务包详情
const fwbDetail = (service) =>{
return request({
url: "app/services/" + service

View File

@@ -190,6 +190,16 @@ const orderCancel = id => {
})
}
// 操作记录
const orderLog = (id, page) => {
return request({
url: 'business/' + id + '/do_logs',
data: {
page
}
})
}
// 支付订单
export {
lists,
@@ -214,5 +224,6 @@ export {
getConfirmScheme,
getConfirmSchemeInfo,
sbuConfirmScheme,
orderCancel
orderCancel,
orderLog
}

View File

@@ -22,7 +22,52 @@ const diffCoinPay = orderId => {
})
}
// ❤️银联支付
const umsPay = (orderId, data) => {
return request({
url : 'pay/order/' + orderId + '/ums',
data
})
}
// 银联支付补差价
const diffUmsPay = (orderId, data) => {
return request({
url: 'pay/diff/' + orderId + '/ums',
data
})
}
// ️银联支付查询支付结果
const umsState = (trade_id) => {
return request({
url : 'payments/query/' + trade_id,
})
}
// 自由服务包订单信息
const umsFreeInfo = (service) => {
return request({
url : 'app/services/recharge/' + service + '/order',
method: 'POST'
})
}
// 自由服务包支付
const umsFree = (orderNo, type) => {
return request({
url : 'app/services/recharge/' + orderNo + '/ums',
data : { type },
method: 'POST'
})
}
export {
coinPay,
diffCoinPay
diffCoinPay,
umsPay,
diffUmsPay,
umsState,
umsFree,
umsFreeInfo
}

View File

@@ -110,6 +110,29 @@ const getRegion = id => {
})
}
// 确认绑定关系
const relationsVerify = (invite, type) => {
return request({
url: 'user/relations/verify',
data: {
type,
invite
}
})
}
// 绑定分享关系
const relationsBind = (invite, type) => {
return request({
url: 'user/relations/bind',
data: {
type,
invite
},
method: 'POST'
})
}
export {
relations,
code,
@@ -123,5 +146,7 @@ export {
userInfoBase,
userInfoBanks,
userInfoBank,
getRegion
getRegion,
relationsVerify,
relationsBind
}