更新
This commit is contained in:
@@ -6,7 +6,7 @@ export default {
|
|||||||
latitude: 39.5426,
|
latitude: 39.5426,
|
||||||
longitude: 116.23292,
|
longitude: 116.23292,
|
||||||
},
|
},
|
||||||
appId: "wx9995c9f495efa82e",
|
appId: "wxed3e2914d6aa4d52",
|
||||||
hasLocationAuth: true,
|
hasLocationAuth: true,
|
||||||
},
|
},
|
||||||
onLaunch: function () {
|
onLaunch: function () {
|
||||||
|
|||||||
@@ -25,17 +25,17 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 获取短信验证码
|
// 获取短信验证码
|
||||||
verifyCodeLoginCheckAccountPersonal(params) {
|
getVerifyCode(params) {
|
||||||
return request({
|
return request({
|
||||||
url: "/guest-identity/unionAuth/verifyCodeLoginCheckAccountPersonal",
|
url: "/guest-identity/unionAuth/getVerifyCode",
|
||||||
method: "post",
|
method: "post",
|
||||||
data: params,
|
data: params,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 验证码登录
|
// 验证码登录
|
||||||
verifyCodeLoginPersonal(params) {
|
verifyCodeRegister(params) {
|
||||||
return request({
|
return request({
|
||||||
url: "/guest-identity/unionAuth/verifyCodeLoginPersonal",
|
url: "/guest-identity/unionAuth/verifyCodeRegister",
|
||||||
method: "post",
|
method: "post",
|
||||||
data: params,
|
data: params,
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -57,7 +57,7 @@
|
|||||||
/* 快应用特有相关 */
|
/* 快应用特有相关 */
|
||||||
},
|
},
|
||||||
"mp-weixin": {
|
"mp-weixin": {
|
||||||
/* 微信小程序特有相关 */ "appid": "wx9995c9f495efa82e",
|
/* 微信小程序特有相关 */ "appid": "wxed3e2914d6aa4d52",
|
||||||
"setting": {
|
"setting": {
|
||||||
"urlCheck": false
|
"urlCheck": false
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -125,6 +125,13 @@ export default {
|
|||||||
obtainCode() {
|
obtainCode() {
|
||||||
if (this.countdown.num != 60) return;
|
if (this.countdown.num != 60) return;
|
||||||
if (!this.checkParams(["username"])) return;
|
if (!this.checkParams(["username"])) return;
|
||||||
|
serve.getVerifyCode({ username: this.params.username }).then((res) => {
|
||||||
|
if (res.code == 20000) {
|
||||||
|
uni.showToast({
|
||||||
|
title: res.msg,
|
||||||
|
icon: "none",
|
||||||
|
});
|
||||||
|
this.params.verifyCodeToken = res.data.verifyCodeToken;
|
||||||
|
|
||||||
let instance = setInterval(() => {
|
let instance = setInterval(() => {
|
||||||
if (!this.countdown.num) {
|
if (!this.countdown.num) {
|
||||||
@@ -134,15 +141,6 @@ export default {
|
|||||||
}
|
}
|
||||||
this.countdown.num -= 1;
|
this.countdown.num -= 1;
|
||||||
}, 1000);
|
}, 1000);
|
||||||
|
|
||||||
serve
|
|
||||||
.verifyCodeLoginCheckAccountPersonal({ username: this.params.username })
|
|
||||||
.then((res) => {
|
|
||||||
if (res.code == 20000) {
|
|
||||||
uni.showToast({
|
|
||||||
title: res.msg,
|
|
||||||
});
|
|
||||||
this.params.verifyCodeToken = res.data.verifyCodeToken;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@@ -183,7 +181,12 @@ export default {
|
|||||||
realLogin() {
|
realLogin() {
|
||||||
if (!this.checkParams(["username", "verifyCode"])) return;
|
if (!this.checkParams(["username", "verifyCode"])) return;
|
||||||
|
|
||||||
serve.verifyCodeLoginPersonal(this.params).then((res) => {
|
serve
|
||||||
|
.verifyCodeRegister({
|
||||||
|
unionId: uni.getStorageSync("unionid"),
|
||||||
|
...this.params,
|
||||||
|
})
|
||||||
|
.then((res) => {
|
||||||
if (res.code === 20000) {
|
if (res.code === 20000) {
|
||||||
this.callbackLogin(res);
|
this.callbackLogin(res);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,8 +3,8 @@ import axiosMiniprogramAdapter from "axios-miniprogram-adapter";
|
|||||||
import utils from "@/utils/encode";
|
import utils from "@/utils/encode";
|
||||||
let env;
|
let env;
|
||||||
env = "test";
|
env = "test";
|
||||||
env = "production";
|
// env = "production";
|
||||||
let testUrl = "http://192.168.110.77:38080";
|
let testUrl = "http://192.168.110.230:38080";
|
||||||
|
|
||||||
let productUrl = "http://uat.xingoil.com/guest-api";
|
let productUrl = "http://uat.xingoil.com/guest-api";
|
||||||
// let productUrl = "https://www.xingoil.com/adminapi";
|
// let productUrl = "https://www.xingoil.com/adminapi";
|
||||||
|
|||||||
Reference in New Issue
Block a user