zhaojs
2023-06-25 4ac3c2382e0733685f7612f8e9ca4e85d15c1411
uniapp/App.vue
@@ -91,7 +91,6 @@
         uni.getSystemInfo({
            success: e => {
               // #ifdef APP-PLUS
               console.log(e)
               if (e.platform == 'android') {
                  this.globalData.platform = 'android'
                  this.globalData.systemLevel = e.system
@@ -151,7 +150,6 @@
                     content: '检测到网络权限可能设置为关闭,您可以在“设置”中检查无线数据及蜂窝移动网络'
                  })
               }else{
                  console.log("是否请求过:"+that.globalData.hasinit)
                  if(!that.globalData.hasinit)
                  {
                     that.getAppInfo();
@@ -173,7 +171,6 @@
            var route = routes[routes.length - 1].route
         }
         // #ifdef APP-PLUS
         console.log(this.globalData.canlisten)
         if (this.globalData.canlisten && route != 'pages/mine/tools/turnChain') {
            getClipboard()
         }
@@ -190,7 +187,6 @@
            if (uni.getSystemInfoSync().platform == 'ios')
            {
               const plug = uni.requireNativePlugin('xiguazhu-baichuan');
               console.log(plug)
               plug.init({}, result => {
                  //console.log('1111111111111111111');
                  console.log(result);   // code等于0就是初始化成功
@@ -204,7 +200,6 @@
         getAppInfo: function() {
            var that = this;
            this.$u.api.comminInt({}).then(e => {
               console.log(e)
               if (e.code != 0) return that.$alert(e.msg)
               that.globalData.hasinit=true;
               that.globalData.appinfo = e.data.basic
@@ -225,6 +220,7 @@
                        that.globalData.ifwt = 0
                     }
                  }
                  console.log(that.globalData.ifwt);
               } else {
                  if (plus.runtime.isApplicationExist({pname:'com.tencent.mm',
                        action: 'weixin://'
@@ -237,6 +233,7 @@
                  }
               }
               // #endif
            }).catch(function(err) {})
            
         },