宋飞扬 il y a 1 an
Parent
commit
e3097e1ed1
1 fichiers modifiés avec 5 ajouts et 1 suppressions
  1. 5 1
      src/pages/login/index.vue

+ 5 - 1
src/pages/login/index.vue

@@ -81,7 +81,7 @@ export default {
         grant_type: 'wechat',
         token: '',
       },
-      checked: [],
+      checked: ['1'],
       title: '',
       show: false, // 添加show数据属性,并初始化为false
       showUserAgreementDialog: false,
@@ -131,6 +131,10 @@ export default {
 
     //点击微信用户一键登录
     async login() {
+      if (this.checked && this.checked.length == 0) {
+        uni.$u.toast('请阅读并同意《用户协议》和 《隐私政策》');
+        return;
+      }
       this.$Router.pushTab('/pages/client/tabBar/home');
       return;
       if (this.checked.length !== 0) {