Commit 9d844c31 authored by 李俊赕's avatar 李俊赕

接口联调-未完成版

parent efc10d7a
...@@ -3,7 +3,7 @@ const codeApiUrl = globalUrl.codeUrl.apiUrl ...@@ -3,7 +3,7 @@ const codeApiUrl = globalUrl.codeUrl.apiUrl
let settledApiFun = function(vm){ let settledApiFun = function(vm){
/* 查询用户基本信息 */ /* 查询用户基本信息 */
let getSettleBaseInfo = async (params = {}) => await vm.$u.get('/v1/h5/settled/get-settled-info', params); let getSettleBaseInfo = async (params = {}) => await vm.$u.get(codeApiUrl+'/v1/settled/get-settled-info', params);
/* 获取认证区域信息 */ /* 获取认证区域信息 */
let getSettleArea = async (params = {}) => await vm.$u.get('/v1/h5/settled/area', params); let getSettleArea = async (params = {}) => await vm.$u.get('/v1/h5/settled/area', params);
/* 提交用户基本信息 */ /* 提交用户基本信息 */
...@@ -13,7 +13,9 @@ let settledApiFun = function(vm){ ...@@ -13,7 +13,9 @@ let settledApiFun = function(vm){
/* 校验身份证反面 */ /* 校验身份证反面 */
let checkSettleIDCardBack = async (params = {}) => await vm.$u.post(codeApiUrl+'/v1/h5/settled/card-back', params); let checkSettleIDCardBack = async (params = {}) => await vm.$u.post(codeApiUrl+'/v1/h5/settled/card-back', params);
/* 缴纳保证金 */ /* 缴纳保证金 */
let paySettleDeposit = async (params = {}) => await vm.$u.post(codeApiUrl+'/v1/settled/pay-deposit', params,{'content-type': 'application/x-www-form-urlencoded'}); const token = 'RTOKENe56f873b5823477fa2e15572f8fa7eb3a5fb6f7b'
const url = codeApiUrl+'/v1/settled/pay-deposit?access-token='+token
let paySettleDeposit = async (params = {}) => await vm.$u.post(url, params,{'content-type': 'application/x-www-form-urlencoded'});
let getSettleDepositResult = async (params = {}) => await vm.$u.post(codeApiUrl+'/v1/settled/pay-deposit', params,{'content-type': 'application/x-www-form-urlencoded'}); let getSettleDepositResult = async (params = {}) => await vm.$u.post(codeApiUrl+'/v1/settled/pay-deposit', params,{'content-type': 'application/x-www-form-urlencoded'});
/* 校验银行卡 */ /* 校验银行卡 */
let checkSettleBank = async (params = {}) => await vm.$u.get('/wxh-site-rest/rest/register/verifyBankCard', params); let checkSettleBank = async (params = {}) => await vm.$u.get('/wxh-site-rest/rest/register/verifyBankCard', params);
......
...@@ -84,7 +84,8 @@ const install = (Vue, vm) => { ...@@ -84,7 +84,8 @@ const install = (Vue, vm) => {
// // vm.$u.route('/pages/login/wxlogin'); // // vm.$u.route('/pages/login/wxlogin');
// return false; // return false;
// } // }
config.header.token = vm.vuex_token || ''; config.header.token = vm.vuex_token || 'RTOKENe56f873b5823477fa2e15572f8fa7eb3a5fb6f7b';
config.header.Authorization = vm.vuex_token || 'RTOKENe56f873b5823477fa2e15572f8fa7eb3a5fb6f7b';
// 临时测试 token -- 开发环境 // 临时测试 token -- 开发环境
// if (apiUrl == 'http://fa.yunya.com') { // if (apiUrl == 'http://fa.yunya.com') {
// config.header.token = '0edjXh5micAR3Lf1tkNtObcUtLMdiVGCVOxlkca_PyTi0CFdyo5kF3TMdSEO8wBDHJh8CwDOTCfzvpLeavzLNg'; // config.header.token = '0edjXh5micAR3Lf1tkNtObcUtLMdiVGCVOxlkca_PyTi0CFdyo5kF3TMdSEO8wBDHJh8CwDOTCfzvpLeavzLNg';
......
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
<script> <script>
import pingpp from '@/include/libs/pingpp.js' import pingpp from '@/include/libs/pingpp.js'
import globalUrl from '@/common/base_url.js'
export default { export default {
data() { data() {
return { return {
...@@ -68,6 +69,7 @@ ...@@ -68,6 +69,7 @@
},1000) },1000)
}, },
async paySubmit() { async paySubmit() {
codeApiUrl
this.saving = true this.saving = true
uni.showLoading({ uni.showLoading({
title:'支付中……' title:'支付中……'
...@@ -75,9 +77,10 @@ ...@@ -75,9 +77,10 @@
// 提交支付订单 // 提交支付订单
const params = { const params = {
oid: 2, oid: 2,
type: 'wx_pub' type: 'wx_pub',
} }
const res = await this.$u.api.paySettleDeposit(params); const codeApiUrl = globalUrl.codeUrl.apiUrl
const res = await this.$u.api.paySettleDeposit(params)
if (!res.status) { if (!res.status) {
uni.showToast({ uni.showToast({
title: '支付调用失败,请稍后重试', title: '支付调用失败,请稍后重试',
......
...@@ -72,6 +72,9 @@ ...@@ -72,6 +72,9 @@
name:'支付宝', name:'支付宝',
value:'alipay' value:'alipay'
}], }],
baseInfo:{
},
saving: false, saving: false,
} }
}, },
...@@ -80,6 +83,7 @@ ...@@ -80,6 +83,7 @@
}, },
onShow(){ onShow(){
console.log('onshow') console.log('onshow')
this.getBaseInfo()
// this.goSign() // this.goSign()
}, },
computed: { computed: {
...@@ -196,6 +200,21 @@ ...@@ -196,6 +200,21 @@
// } // }
// return true // return true
// }, // },
async getBaseInfo(){
const params = {
}
const res = this.$u.api.getSettleBaseInfo(params)
if (res.status != 200) {
uni.showToast({
title: res.message,
icon: 'none'
});
return;
}
console.log(res,'res')
return true
},
async submitInfo(){ async submitInfo(){
// checkSettleSignInfo // checkSettleSignInfo
const baseInfo = this.baseInfo; const baseInfo = this.baseInfo;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment