zhaoxiaohai 2 years ago
parent
commit
3e8ddd2520
2 changed files with 15 additions and 7 deletions
  1. 15 0
      pages/login/modules/login.js
  2. 0 7
      pages/login/selectSite.js

+ 15 - 0
pages/login/modules/login.js

@@ -20,6 +20,7 @@ function query_userauth(i = 0) {
         title: '权限查询失败,请稍后再试',
         icon: "none"
     })
+    if (i == 0) querySite_Parameter();
     _Http.basic({
         "classname": "sysmanage.develop.userauth.userauth",
         "method": "query_userauth",
@@ -29,6 +30,20 @@ function query_userauth(i = 0) {
         wx.setStorageSync('userauth', res.data);
     })
 }
+
+function querySite_Parameter(i = 0) {
+    if (i == 5) return;
+    _Http.basic({
+        "classname": "webmanage.site.site",
+        "method": "querySite_Parameter",
+        "content": {}
+    }).then(res => {
+        if (res.msg != '成功') return query_userauth(i + 1);
+        wx.setStorageSync('siteP', res.data);
+    })
+}
+
+/* 站点数据查询 */
 module.exports = {
     loginMsg,
     query_userauth

+ 0 - 7
pages/login/selectSite.js

@@ -7,13 +7,6 @@ Page({
     data: {
         account_list: ""
     },
-
-    /* 
-    wx.switchTab({
-                url: '/pages/tabbar/home/index'
-            })
-    */
-
     /**
      * 生命周期函数--监听页面加载
      */