Bladeren bron

Merge branch 'dev-5.3.1' of http://192.168.32.253:3000/Software/android-cloud-H5 into dev-5.3.1

heyang 2 jaren geleden
bovenliggende
commit
73647de83c

+ 2 - 4
package-lock.json

@@ -2527,7 +2527,7 @@
       "version": "2.6.12",
       "resolved": "https://registry.npmmirror.com/core-js/-/core-js-2.6.12.tgz",
       "integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==",
-      "deprecated": "core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.",
+      "deprecated": "core-js@<3.4 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Please, upgrade your dependencies to the actual version of core-js.",
       "hasInstallScript": true
     },
     "node_modules/@nuxt/builder": {
@@ -6437,7 +6437,6 @@
       "version": "3.22.7",
       "resolved": "https://registry.npmmirror.com/core-js/-/core-js-3.22.7.tgz",
       "integrity": "sha512-Jt8SReuDKVNZnZEzyEQT5eK6T2RRCXkfTq7Lo09kpm+fHjgGewSbNjV+Wt4yZMhPDdzz2x1ulI5z/w4nxpBseg==",
-      "deprecated": "core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.",
       "hasInstallScript": true
     },
     "node_modules/core-js-compat": {
@@ -16696,8 +16695,7 @@
     "node_modules/stable": {
       "version": "0.1.8",
       "resolved": "https://registry.npmmirror.com/stable/-/stable-0.1.8.tgz",
-      "integrity": "sha512-ji9qxRnOVfcuLDySj9qzhGSEFVobyt1kIOSkj1qZzYLzq7Tos/oUUWvotUPQLlrsidqsK6tBH89Bc9kL5zHA6w==",
-      "deprecated": "Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility"
+      "integrity": "sha512-ji9qxRnOVfcuLDySj9qzhGSEFVobyt1kIOSkj1qZzYLzq7Tos/oUUWvotUPQLlrsidqsK6tBH89Bc9kL5zHA6w=="
     },
     "node_modules/stack-trace": {
       "version": "0.0.10",

+ 13 - 0
pages/test-call-app.vue

@@ -11,6 +11,19 @@
         >唤起支付宝扫一扫</v-btn
       >
     </div>
+    <!-- <div class="mt-2">
+      URL Scheme
+      <a :href="$callSzx.generateScheme({ path: '' })">{{
+        $callSzx.generateScheme({ path: '' })
+      }}</a>
+    </div>
+    <div class="mt-2">URL Scheme <a href="szxapp://">szxapp://</a></div>
+    <div class="mt-2 break-words">
+      Intent
+      <a :href="$callSzx.generateIntent({ path: '' })">{{
+        $callSzx.generateIntent({ path: '' })
+      }}</a>
+    </div> -->
   </v-container>
 </template>
 

+ 8 - 31
plugins/callapp.js

@@ -1,21 +1,12 @@
 import CallApp from 'callapp-lib';
 
-export default function (c, i) {
+export default function ({ $userAgent }, i) {
+  const scheme = $userAgent.isIos ? 'szxiOSApp' : 'opengeminiapp';
   i(
     'callSzx',
     new CallApp({
-      scheme: {
-        protocol: 'SZXIosAPP',
-        host: '',
-        // port: 80,
-      },
-      intent: {
-        package: 'com.gemini.cloud.client',
-        // action: '',
-        // category: '',
-        // component: '',
-        scheme: 'SZXIosAPP',
-      },
+      scheme: { protocol: scheme, host: '' },
+      intent: { package: 'com.gemini.cloud.client', scheme },
       timeout: 2000,
       yingyongbao:
         'https://a.app.qq.com/o/simple.jsp?pkgname=com.gemini.cloud.client',
@@ -26,15 +17,8 @@ export default function (c, i) {
   i(
     'callWechat',
     new CallApp({
-      scheme: {
-        protocol: 'weixin',
-        host: '',
-        // port: 80,
-      },
-      intent: {
-        package: 'com.tencent.mm',
-        scheme: 'weixin',
-      },
+      scheme: { protocol: 'weixin', host: '' },
+      intent: { package: 'com.tencent.mm', scheme: 'weixin' },
       timeout: 2000,
       appstore: 'https://apps.apple.com/cn/app/id414478124',
       fallback: 'https://weixin.qq.com',
@@ -43,15 +27,8 @@ export default function (c, i) {
   i(
     'callAlipay',
     new CallApp({
-      scheme: {
-        protocol: 'alipayqr',
-        host: 'platformapi/startapp',
-        // port: 80,
-      },
-      intent: {
-        package: 'com.eg.android.AlipayGphone',
-        scheme: 'alipayqr',
-      },
+      scheme: { protocol: 'alipayqr', host: 'platformapi/startapp' },
+      intent: { package: 'com.eg.android.AlipayGphone', scheme: 'alipayqr' },
       timeout: 2000,
       appstore: 'https://apps.apple.com/cn/app/id333206289',
       fallback: 'https://www.alipay.com',

+ 16 - 0
static/screenAndroid/WXtrialInterface.html

@@ -1394,8 +1394,24 @@
           success: function (res) {},
         });
       }
+      // 观看广告次数上报1
+      function reportFrequency() {
+        $.ajax({
+          url: baseUrl + '/api/resoures/v1/trial/reportFrequency/' + form.userCardId,
+          headers: {
+            Authorization: form.token
+          },
+          type: 'post',
+          contentType: 'application/json',
+          dataType: 'json',
+          success: function (res) {},
+        });
+      }
       //关闭广告
       $('.time-close-wrap')[0].addEventListener('click', () => {
+        if(videoTime == 0) {
+          reportFrequency()
+        }
         $('.buy-phone-wrap').eq(0).show();
       });
       // 点击取消

+ 16 - 1
static/screenIos/WXtrialInterface.html

@@ -1177,7 +1177,19 @@
           getAD();
         });
       }
-
+      // 观看广告次数上报1
+      function reportFrequency() {
+        $.ajax({
+          url: baseUrl + '/api/resoures/v1/trial/reportFrequency/' + form.userCardId,
+          headers: {
+            Authorization: form.token
+          },
+          type: 'post',
+          contentType: 'application/json',
+          dataType: 'json',
+          success: function (res) {},
+        });
+      }
       //间隔广告上报
       function report(type) {
         $.ajax({
@@ -1197,6 +1209,9 @@
       }
       //关闭广告
       $('.time-close-wrap')[0].addEventListener('click', () => {
+        if(videoTime == 0) {
+          reportFrequency()
+        }
         $('.buy-phone-wrap').eq(0).show();
       });
       // 点击取消