|
|
@@ -10,6 +10,11 @@
|
|
|
<button class="wechat-auth-btn" open-type="getPhoneNumber" @getphonenumber="onWechatAuth">
|
|
|
微信一键登录
|
|
|
</button>
|
|
|
+
|
|
|
+ <button @click="handleChangeFangshi">
|
|
|
+ 切换微信一键登录
|
|
|
+ </button>
|
|
|
+
|
|
|
</view>
|
|
|
<!-- <view @click="ceshi" class="auth-tips">欢迎使用小程序12312312312312</view> -->
|
|
|
</view>
|
|
|
@@ -163,6 +168,29 @@
|
|
|
cacheManager.set('projectImg', res.data)
|
|
|
});
|
|
|
}
|
|
|
+
|
|
|
+ function handleChangeFangshi() {
|
|
|
+ let str = ``;
|
|
|
+ if (id.value) {
|
|
|
+ str = str+`id=${id.value}`
|
|
|
+ }
|
|
|
+ if ( id.value && fromPage.value ) {
|
|
|
+ str = str +`&from=${fromPage.value}`
|
|
|
+ } else if (!id.value && fromPage.value) {
|
|
|
+ str = str + `from=${fromPage.value}`
|
|
|
+ }
|
|
|
+
|
|
|
+ if (str) {
|
|
|
+ uni.redirectTo({
|
|
|
+ url: `/pages/Login/test?${str}`
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ uni.redirectTo({
|
|
|
+ url: `/pages/Login/test`
|
|
|
+ })
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
</script>
|
|
|
|
|
|
<style scoped>
|