浏览代码

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

heyang 3 年之前
父节点
当前提交
42cdb03d8d

+ 349 - 0
microserviceUserH5/static/css/normalize-8.0.1.css

@@ -0,0 +1,349 @@
+/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */
+
+/* Document
+   ========================================================================== */
+
+/**
+ * 1. Correct the line height in all browsers.
+ * 2. Prevent adjustments of font size after orientation changes in iOS.
+ */
+
+html {
+  line-height: 1.15; /* 1 */
+  -webkit-text-size-adjust: 100%; /* 2 */
+}
+
+/* Sections
+   ========================================================================== */
+
+/**
+ * Remove the margin in all browsers.
+ */
+
+body {
+  margin: 0;
+}
+
+/**
+ * Render the `main` element consistently in IE.
+ */
+
+main {
+  display: block;
+}
+
+/**
+ * Correct the font size and margin on `h1` elements within `section` and
+ * `article` contexts in Chrome, Firefox, and Safari.
+ */
+
+h1 {
+  font-size: 2em;
+  margin: 0.67em 0;
+}
+
+/* Grouping content
+   ========================================================================== */
+
+/**
+ * 1. Add the correct box sizing in Firefox.
+ * 2. Show the overflow in Edge and IE.
+ */
+
+hr {
+  box-sizing: content-box; /* 1 */
+  height: 0; /* 1 */
+  overflow: visible; /* 2 */
+}
+
+/**
+ * 1. Correct the inheritance and scaling of font size in all browsers.
+ * 2. Correct the odd `em` font sizing in all browsers.
+ */
+
+pre {
+  font-family: monospace, monospace; /* 1 */
+  font-size: 1em; /* 2 */
+}
+
+/* Text-level semantics
+   ========================================================================== */
+
+/**
+ * Remove the gray background on active links in IE 10.
+ */
+
+a {
+  background-color: transparent;
+}
+
+/**
+ * 1. Remove the bottom border in Chrome 57-
+ * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
+ */
+
+abbr[title] {
+  border-bottom: none; /* 1 */
+  text-decoration: underline; /* 2 */
+  text-decoration: underline dotted; /* 2 */
+}
+
+/**
+ * Add the correct font weight in Chrome, Edge, and Safari.
+ */
+
+b,
+strong {
+  font-weight: bolder;
+}
+
+/**
+ * 1. Correct the inheritance and scaling of font size in all browsers.
+ * 2. Correct the odd `em` font sizing in all browsers.
+ */
+
+code,
+kbd,
+samp {
+  font-family: monospace, monospace; /* 1 */
+  font-size: 1em; /* 2 */
+}
+
+/**
+ * Add the correct font size in all browsers.
+ */
+
+small {
+  font-size: 80%;
+}
+
+/**
+ * Prevent `sub` and `sup` elements from affecting the line height in
+ * all browsers.
+ */
+
+sub,
+sup {
+  font-size: 75%;
+  line-height: 0;
+  position: relative;
+  vertical-align: baseline;
+}
+
+sub {
+  bottom: -0.25em;
+}
+
+sup {
+  top: -0.5em;
+}
+
+/* Embedded content
+   ========================================================================== */
+
+/**
+ * Remove the border on images inside links in IE 10.
+ */
+
+img {
+  border-style: none;
+}
+
+/* Forms
+   ========================================================================== */
+
+/**
+ * 1. Change the font styles in all browsers.
+ * 2. Remove the margin in Firefox and Safari.
+ */
+
+button,
+input,
+optgroup,
+select,
+textarea {
+  font-family: inherit; /* 1 */
+  font-size: 100%; /* 1 */
+  line-height: 1.15; /* 1 */
+  margin: 0; /* 2 */
+}
+
+/**
+ * Show the overflow in IE.
+ * 1. Show the overflow in Edge.
+ */
+
+button,
+input { /* 1 */
+  overflow: visible;
+}
+
+/**
+ * Remove the inheritance of text transform in Edge, Firefox, and IE.
+ * 1. Remove the inheritance of text transform in Firefox.
+ */
+
+button,
+select { /* 1 */
+  text-transform: none;
+}
+
+/**
+ * Correct the inability to style clickable types in iOS and Safari.
+ */
+
+button,
+[type="button"],
+[type="reset"],
+[type="submit"] {
+  -webkit-appearance: button;
+}
+
+/**
+ * Remove the inner border and padding in Firefox.
+ */
+
+button::-moz-focus-inner,
+[type="button"]::-moz-focus-inner,
+[type="reset"]::-moz-focus-inner,
+[type="submit"]::-moz-focus-inner {
+  border-style: none;
+  padding: 0;
+}
+
+/**
+ * Restore the focus styles unset by the previous rule.
+ */
+
+button:-moz-focusring,
+[type="button"]:-moz-focusring,
+[type="reset"]:-moz-focusring,
+[type="submit"]:-moz-focusring {
+  outline: 1px dotted ButtonText;
+}
+
+/**
+ * Correct the padding in Firefox.
+ */
+
+fieldset {
+  padding: 0.35em 0.75em 0.625em;
+}
+
+/**
+ * 1. Correct the text wrapping in Edge and IE.
+ * 2. Correct the color inheritance from `fieldset` elements in IE.
+ * 3. Remove the padding so developers are not caught out when they zero out
+ *    `fieldset` elements in all browsers.
+ */
+
+legend {
+  box-sizing: border-box; /* 1 */
+  color: inherit; /* 2 */
+  display: table; /* 1 */
+  max-width: 100%; /* 1 */
+  padding: 0; /* 3 */
+  white-space: normal; /* 1 */
+}
+
+/**
+ * Add the correct vertical alignment in Chrome, Firefox, and Opera.
+ */
+
+progress {
+  vertical-align: baseline;
+}
+
+/**
+ * Remove the default vertical scrollbar in IE 10+.
+ */
+
+textarea {
+  overflow: auto;
+}
+
+/**
+ * 1. Add the correct box sizing in IE 10.
+ * 2. Remove the padding in IE 10.
+ */
+
+[type="checkbox"],
+[type="radio"] {
+  box-sizing: border-box; /* 1 */
+  padding: 0; /* 2 */
+}
+
+/**
+ * Correct the cursor style of increment and decrement buttons in Chrome.
+ */
+
+[type="number"]::-webkit-inner-spin-button,
+[type="number"]::-webkit-outer-spin-button {
+  height: auto;
+}
+
+/**
+ * 1. Correct the odd appearance in Chrome and Safari.
+ * 2. Correct the outline style in Safari.
+ */
+
+[type="search"] {
+  -webkit-appearance: textfield; /* 1 */
+  outline-offset: -2px; /* 2 */
+}
+
+/**
+ * Remove the inner padding in Chrome and Safari on macOS.
+ */
+
+[type="search"]::-webkit-search-decoration {
+  -webkit-appearance: none;
+}
+
+/**
+ * 1. Correct the inability to style clickable types in iOS and Safari.
+ * 2. Change font properties to `inherit` in Safari.
+ */
+
+::-webkit-file-upload-button {
+  -webkit-appearance: button; /* 1 */
+  font: inherit; /* 2 */
+}
+
+/* Interactive
+   ========================================================================== */
+
+/*
+ * Add the correct display in Edge, IE 10+, and Firefox.
+ */
+
+details {
+  display: block;
+}
+
+/*
+ * Add the correct display in all browsers.
+ */
+
+summary {
+  display: list-item;
+}
+
+/* Misc
+   ========================================================================== */
+
+/**
+ * Add the correct display in IE 10+.
+ */
+
+template {
+  display: none;
+}
+
+/**
+ * Add the correct display in IE 10.
+ */
+
+[hidden] {
+  display: none;
+}

文件差异内容过多而无法显示
+ 63 - 0
microserviceUserH5/static/js/tailwindcss/v3.0.24/index.js


+ 4 - 5
microserviceUserH5/vcloud/invite2.html

@@ -23,8 +23,7 @@
 </head>
 </head>
 
 
 <body>
 <body>
-    <div class="my-tips">当前功能维护中,暂无法使用</div>
-	<!-- <div class="invite-container pr">
+	<div class="invite-container pr">
 		<div class="rules" onclick="handleShow()">活动规则</div>
 		<div class="rules" onclick="handleShow()">活动规则</div>
 		<div class="h658">
 		<div class="h658">
 			<img src="../static/img/invite/inviteTop.png" class="bottom-img" alt="">
 			<img src="../static/img/invite/inviteTop.png" class="bottom-img" alt="">
@@ -85,12 +84,12 @@
 		</div>
 		</div>
 	</div>
 	</div>
 	<input type="text" style="opacity: 0;z-index: -10;position: fixed;" id="passwordCopy" value="">
 	<input type="text" style="opacity: 0;z-index: -10;position: fixed;" id="passwordCopy" value="">
-	<input type="text" style="opacity: 0;z-index: -10;position: fixed;" id="inviteCopy" value=""> -->
+	<input type="text" style="opacity: 0;z-index: -10;position: fixed;" id="inviteCopy" value="">
 	<script>
 	<script>
 		toastr.options.positionClass = 'toast-center-center';
 		toastr.options.positionClass = 'toast-center-center';
 		toastr.options.timeOut = '1500';
 		toastr.options.timeOut = '1500';
 	</script>
 	</script>
-	<!-- <script type="text/javascript">
+	<script type="text/javascript">
 		let timer, flag = true;
 		let timer, flag = true;
 		var url = window.location.href;
 		var url = window.location.href;
 		url = url.split('/')
 		url = url.split('/')
@@ -344,7 +343,7 @@
 			if (timer) { clearTimeout(timer); }
 			if (timer) { clearTimeout(timer); }
 			timer = setTimeout(() => { flag = true }, 1500);
 			timer = setTimeout(() => { flag = true }, 1500);
 		}
 		}
-	</script> -->
+	</script>
 </body>
 </body>
 
 
 </html>
 </html>

+ 10 - 21
microserviceUserH5/vcloud/register.html

@@ -19,11 +19,12 @@
   <script src="../static/js/vender/base64.js"></script>
   <script src="../static/js/vender/base64.js"></script>
   <script src="../static/js/vender/verify.js"></script>
   <script src="../static/js/vender/verify.js"></script>
   <script src="../static/js/vender/ase.js"></script>
   <script src="../static/js/vender/ase.js"></script>
+  <script src="../static/js/vender/vue/config.js"></script>
   <script>
   <script>
     toastr.options.positionClass = 'toast-center-center';
     toastr.options.positionClass = 'toast-center-center';
   </script>
   </script>
   <style>
   <style>
-    .my-tips{
+    .my-tips {
       position: fixed;
       position: fixed;
       top: 50%;
       top: 50%;
       left: 50%;
       left: 50%;
@@ -34,8 +35,7 @@
 </head>
 </head>
 
 
 <body>
 <body>
-  <div class="my-tips">当前功能维护中,暂无法使用</div>
-  <!-- <div id="mpanel2"></div>
+  <div id="mpanel2"></div>
   <div id="form-btn"></div>
   <div id="form-btn"></div>
   <div class="top free-code-con" style="position:relative;">
   <div class="top free-code-con" style="position:relative;">
     <div>
     <div>
@@ -70,8 +70,8 @@
         </div>
         </div>
       </div>
       </div>
     </div>
     </div>
-  </div> -->
-  <!-- <script type="text/javascript" th:inline="javascript">
+  </div>
+  <script type="text/javascript" th:inline="javascript">
     var parameters = GetRequest();
     var parameters = GetRequest();
     var phone = parameters["phone"];
     var phone = parameters["phone"];
     var timer, flag = true;
     var timer, flag = true;
@@ -187,8 +187,7 @@
     function getHead(fileId) {
     function getHead(fileId) {
       $('.head img').attr('src', '../static/img/invite/header-img.png');
       $('.head img').attr('src', '../static/img/invite/header-img.png');
       if (fileId) {
       if (fileId) {
-        let urls = baseUrl == 'http://prese.phone.androidscloud.com' ? 'http://110.53.221.195:8210' : 'https://wjzx.androidscloud.com:9091';
-        $('.head img').attr('src', `${urls}/document/newFile/download/0/347905r86eb745a1sc38?fileKey=` + fileId);
+        $('.head img').attr('src', `${fileCenterApi}/document/newFile/download/0/347905r86eb745a1sc38?fileKey=${fileId}`);
       }
       }
     }
     }
     function encrypt(word, keyStr) {
     function encrypt(word, keyStr) {
@@ -261,23 +260,13 @@
         url: baseUrl + '/api/user/v5/operateApi/addUserVisit',
         url: baseUrl + '/api/user/v5/operateApi/addUserVisit',
         type: 'post',
         type: 'post',
         data: JSON.stringify({ "accessType": 2, "loginType": 2 }),
         data: JSON.stringify({ "accessType": 2, "loginType": 2 }),
-        contentType:"application/json",
-				dataType: 'json',
-				cache: false,
+        contentType: "application/json",
+        dataType: 'json',
+        cache: false,
         success: function () {
         success: function () {
         }
         }
       })
       })
     }
     }
-    // function visit() {
-		// 	$.ajax({
-		// 		url: baseUrl + '/api/user/v3/invitation/client/addInviteData',
-		// 		type: 'get',
-		// 		cache: false,
-		// 		dataType: 'text',
-		// 		success: function () {
-		// 		}
-		// 	})
-		// }
     //防止提示一秒内重复显示
     //防止提示一秒内重复显示
     function stopManyClick(fn) {
     function stopManyClick(fn) {
       if (flag) {
       if (flag) {
@@ -287,7 +276,7 @@
       if (timer) { clearTimeout(timer); }
       if (timer) { clearTimeout(timer); }
       timer = setTimeout(() => { flag = true }, 1500);
       timer = setTimeout(() => { flag = true }, 1500);
     }
     }
-  </script> -->
+  </script>
 </body>
 </body>
 <style>
 <style>
   #toast-container>.toast-error {
   #toast-container>.toast-error {

+ 83 - 0
microserviceUserH5/vcloud/userManual.html

@@ -0,0 +1,83 @@
+<!DOCTYPE html>
+<html lang="zh-CN">
+  <head>
+    <meta charset="UTF-8" />
+    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
+    <meta
+      name="viewport"
+      content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"
+    />
+    <link rel="icon" href="../static/img/favicon2.ico" type="img/x-ico" />
+    <title>双子星</title>
+    <link rel="stylesheet" href="../static/css/normalize-8.0.1.css" />
+    <script src="../static/js/vender/vue/vue.min.js"></script>
+    <!-- <script src="https://cdn.staticfile.org/vue/2.2.2/vue.js"></script> -->
+    <!-- <script src="https://lf6-cdn-tos.bytecdntp.com/cdn/expire-1-M/vue/2.6.14/vue.js"></script> -->
+    <script src="../static/js/vender/config.js"></script>
+    <script src="../static/js/tailwindcss/v3.0.24/index.js"></script>
+    <script>
+      tailwind.config = {
+        theme: {},
+        corePlugins: {
+          preflight: false,
+        },
+      };
+    </script>
+    <script src="../static/js/vender/jquery-3.4.1.min.js"></script>
+    <link rel="stylesheet" href="../static/js/vender/toastr/toastr.min.css" />
+    <script src="../static/js/vender/toastr/toastr.min.js"></script>
+    <script>
+      toastr.options.positionClass = 'toast-center-center';
+    </script>
+  </head>
+  <body>
+    <div v-cloak id="app">
+      <h1 class="text-center mt-2">{{title}}</h1>
+      <div class="p-2" v-html="content"></div>
+    </div>
+    <script src="../static/js/vender/vue/axios.min.js"></script>
+    <script src="../static/js/vender/vue/config.js"></script>
+    <script src="../static/js/vender/vue/api.js"></script>
+
+    <script type="text/javascript">
+      Vue.config.errorHandler = function (err, vm, info) {
+        toastr.error(err.message);
+        return false;
+      };
+      new Vue({
+        el: '#app',
+        data: {
+          title: '',
+          content: '',
+        },
+        computed: {},
+
+        methods: {
+          async getUserManual() {
+            const response = await service.get(
+              '/api/public/v5/agreementApi/content/getContentByType',
+              {
+                params: {
+                  agreementCoding: 'XYPZYHXY2004',
+                  type: 1,
+                },
+              },
+            );
+            return response.data;
+          },
+        },
+
+        async mounted() {
+          // throw new Error('失敬失敬');
+          const { agreementName: title, content } = await this.getUserManual();
+          this.title = title;
+          this.content = content;
+        },
+        errorCaptured(err, vm, info) {
+          toastr.error(err.message);
+          return false;
+        },
+      });
+    </script>
+  </body>
+</html>

+ 2 - 40
screenAndroid/WXdraw.js

@@ -68,15 +68,7 @@ function doConnect() {
     wsss.close();
     wsss.close();
     throttle(doConnect, 100);
     throttle(doConnect, 100);
     if (errorTime > 1000) {
     if (errorTime > 1000) {
-      if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-        tt.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      } else {
-        wx.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      }
+      quit();
     }
     }
   };
   };
   wsss.onmessage = function (res) {
   wsss.onmessage = function (res) {
@@ -98,21 +90,7 @@ function doConnect() {
           }, function () {
           }, function () {
             isControl = false;
             isControl = false;
             //点击取消后的回调函数
             //点击取消后的回调函数
-            if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-              tt.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else if (window.__wxjs_environment === 'miniprogram') {
-              wx.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else {
-              document.addEventListener('UniAppJSBridgeReady', function () {
-                uni.navigateTo({
-                  url: '/pages/index/index'
-                });
-              })
-            }
+            quit();
           });
           });
         } else {
         } else {
           $.confirm("当前云手机正在授控,是否请求获取云手机控制权?", function () {
           $.confirm("当前云手机正在授控,是否请求获取云手机控制权?", function () {
@@ -174,22 +152,6 @@ $(".PictureQuality").on("click", function () {
   var id = $(this).attr("data-id")
   var id = $(this).attr("data-id")
   var buffer = makeSharpness(Number(id));
   var buffer = makeSharpness(Number(id));
   ws.send(buffer);
   ws.send(buffer);
-  isFeed = false;
-  isAudioPlay = false;
-  $('.weui-mask_transparent').show();
-  $('.weui-toast').show();
-  if (jmuxer) {
-    jmuxer.destroy();
-  }
-  jmuxer = new JMuxer({
-    node: 'playerVideo',
-    flushingTime: 33,
-    fps: 30,
-    mode: 'video',
-    debug: false
-  });
-  myVideo.play();
-  isWaitSps = true;
 })
 })
 //画图形
 //画图形
 var draw_graph = function (graphType, obj) {
 var draw_graph = function (graphType, obj) {

+ 37 - 72
screenAndroid/WXtrialInterface.html

@@ -35,14 +35,16 @@
   <link rel="stylesheet" href="https://cdn.bootcss.com/weui/1.1.3/style/weui.min.css" />
   <link rel="stylesheet" href="https://cdn.bootcss.com/weui/1.1.3/style/weui.min.css" />
   <link rel="stylesheet" href="https://cdn.bootcss.com/jquery-weui/1.2.1/css/jquery-weui.min.css" />
   <link rel="stylesheet" href="https://cdn.bootcss.com/jquery-weui/1.2.1/css/jquery-weui.min.css" />
   <style>
   <style>
-    .try-use-wrap, .buy-phone-wrap, .look-wrap{
-        width: 100%;
-        height: 100%;
-        position: fixed;
-        top: 0;
-        left: 0;
-        z-index: 9999;
-        background: rgba(0, 0, 0, 0.5);
+    .try-use-wrap,
+    .buy-phone-wrap,
+    .look-wrap {
+      width: 100%;
+      height: 100%;
+      position: fixed;
+      top: 0;
+      left: 0;
+      z-index: 9999;
+      background: rgba(0, 0, 0, 0.5);
       display: none;
       display: none;
     }
     }
 
 
@@ -226,7 +228,7 @@
   <script type="text/javascript" src="WXdraw.js"></script>
   <script type="text/javascript" src="WXdraw.js"></script>
   <script type="text/javascript" src="jmuxer.js"></script>
   <script type="text/javascript" src="jmuxer.js"></script>
   <script type="text/javascript" src="spsParser.js"></script>
   <script type="text/javascript" src="spsParser.js"></script>
-  <script type="text/javascript" src="https://unpkg.com/@dcloudio/uni-webview-js@0.0.2/index.js"></script>
+  <script type="text/javascript" src="https://js.cdn.aliyun.dcloud.net.cn/dev/uni-app/uni.webview.1.5.2.js"></script>
   <script>
   <script>
     var url = window.location.href;
     var url = window.location.href;
     url = url.split('/');
     url = url.split('/');
@@ -299,7 +301,6 @@
     var isVisuable = true;
     var isVisuable = true;
     var isFeed = true;
     var isFeed = true;
     var isFinish = false;
     var isFinish = false;
-    var isWaitSps = false;
     var myVideo = document.getElementById("playerVideo");
     var myVideo = document.getElementById("playerVideo");
     Module = {};
     Module = {};
     Module.onRuntimeInitialized = function () {
     Module.onRuntimeInitialized = function () {
@@ -354,15 +355,7 @@
         } else {
         } else {
           clearInterval(intervaler);
           clearInterval(intervaler);
           $.toast("画面异常,请重新进入", "text");
           $.toast("画面异常,请重新进入", "text");
-          if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-            tt.miniProgram.switchTab({
-              url: '/pages/home/home'
-            })
-          } else {
-            wx.miniProgram.switchTab({
-              url: '/pages/home/home'
-            })
-          }
+          quit();
         }
         }
       }, 3000);
       }, 3000);
 
 
@@ -380,15 +373,7 @@
         if (errorTime > 1000) {
         if (errorTime > 1000) {
           $.toast("画面异常,请重新进入", "text");
           $.toast("画面异常,请重新进入", "text");
           wsss.close();
           wsss.close();
-          if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-            tt.miniProgram.switchTab({
-              url: '/pages/home/home'
-            })
-          } else {
-            wx.miniProgram.switchTab({
-              url: '/pages/home/home'
-            })
-          }
+          quit();
         }
         }
       });
       });
       ws.addEventListener('message', function (event) {
       ws.addEventListener('message', function (event) {
@@ -427,19 +412,16 @@
           if (data.frameType == 7 || data.frameType == 8) {
           if (data.frameType == 7 || data.frameType == 8) {
             isFeed = true;
             isFeed = true;
             isAudioPlay = true;
             isAudioPlay = true;
-            isWaitSps = false;
           }
           }
 
 
           if (isFeed) {
           if (isFeed) {
-            if (!isWaitSps) {
-              jmuxer.feed(data);
-            }
+            jmuxer.feed(data);
           }
           }
         }
         }
       });
       });
     }
     }
 
 
-    var hidden, visibilityChange; 
+    var hidden, visibilityChange;
     if (typeof document.hidden !== "undefined") { // Opera 12.10 and Firefox 18 and later support 
     if (typeof document.hidden !== "undefined") { // Opera 12.10 and Firefox 18 and later support 
       hidden = "hidden";
       hidden = "hidden";
       visibilityChange = "visibilitychange";
       visibilityChange = "visibilitychange";
@@ -455,21 +437,9 @@
     document.addEventListener("visibilitychange", function () {
     document.addEventListener("visibilitychange", function () {
       console.log(document[hidden]);
       console.log(document[hidden]);
       if (document[hidden]) {
       if (document[hidden]) {
-        if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-          tt.miniProgram.switchTab({
-            url: '/pages/home/home'
-          })
-        } else if (window.__wxjs_environment === 'miniprogram') {
-          wx.miniProgram.switchTab({
-            url: '/pages/home/home'
-          })
-        } else {
-          document.addEventListener('UniAppJSBridgeReady', function () {
-            uni.navigateTo({
-              url: '/pages/index/index'
-            });
-          })
-        }
+        quit();
+        ws.close();
+        wsss.close();
       }
       }
     }, false);
     }, false);
 
 
@@ -547,17 +517,9 @@
           else {
           else {
             $.toast("画面异常,请重新进入", "text");
             $.toast("画面异常,请重新进入", "text");
             clearInterval(intervaler);
             clearInterval(intervaler);
+            quit();
             ws.close();
             ws.close();
             wsss.close();
             wsss.close();
-            if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-              tt.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else {
-              wx.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            }
           }
           }
         }
         }
         if (input[23] == 0x05) { //横竖屏标识
         if (input[23] == 0x05) { //横竖屏标识
@@ -925,17 +887,9 @@
 
 
     $("#upload").on("click", function () {
     $("#upload").on("click", function () {
       clearInterval(intervaler);
       clearInterval(intervaler);
+      quit();
       ws.close();
       ws.close();
       wsss.close();
       wsss.close();
-      if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-        tt.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      } else {
-        wx.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      }
     })
     })
 
 
     function selectText(x) {
     function selectText(x) {
@@ -1108,9 +1062,7 @@
       $('.buy-phone-wrap').eq(0).hide();
       $('.buy-phone-wrap').eq(0).hide();
       if (disconnectionFlag || getDate) {//设置了断线时间,取消直接退出
       if (disconnectionFlag || getDate) {//设置了断线时间,取消直接退出
         systemBuriedPoint('激活码-断线-取消');
         systemBuriedPoint('激活码-断线-取消');
-        wx.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
+        quit();
         return
         return
       }
       }
       let pointName = '';
       let pointName = '';
@@ -1157,9 +1109,7 @@
       } else {
       } else {
         systemBuriedPoint('激活码-强制关闭-放弃');
         systemBuriedPoint('激活码-强制关闭-放弃');
       }
       }
-      wx.miniProgram.switchTab({
-        url: '/pages/home/home'
-      })
+      quit();
     })
     })
     // 继续观看
     // 继续观看
     $('.looking')[0].addEventListener('click', () => {
     $('.looking')[0].addEventListener('click', () => {
@@ -1186,6 +1136,21 @@
         success: function (res) { }
         success: function (res) { }
       })
       })
     }
     }
+    function quit() {
+      if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
+        tt.miniProgram.switchTab({
+          url: '/pages/home/home'
+        })
+      } else if (window.__wxjs_environment === 'miniprogram') {
+        wx.miniProgram.switchTab({
+          url: '/pages/home/home'
+        })
+      } else {
+        uni.webView.navigateTo({
+          url: '/pages/index/index'
+        });
+      }
+    }
     window.onbeforeunload = function () {
     window.onbeforeunload = function () {
       ws.close();
       ws.close();
       wsss.close();
       wsss.close();

+ 2 - 30
screenIos/WXdraw.js

@@ -77,21 +77,7 @@ function doConnect() {
     wsss.close();
     wsss.close();
     throttle(doConnect, 100);
     throttle(doConnect, 100);
     if (errorTime > 1000) {
     if (errorTime > 1000) {
-      if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-        tt.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      } else if (window.__wxjs_environment === 'miniprogram') {
-        wx.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      } else {
-        document.addEventListener('UniAppJSBridgeReady', function () {
-          uni.navigateTo({
-            url: '/pages/index/index'
-          });
-        })
-      }
+      quit();
     }
     }
   };
   };
   wsss.onmessage = function (res) {
   wsss.onmessage = function (res) {
@@ -113,21 +99,7 @@ function doConnect() {
           }, function () {
           }, function () {
             isControl = false;
             isControl = false;
             //点击取消后的回调函数
             //点击取消后的回调函数
-            if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-              tt.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else if (window.__wxjs_environment === 'miniprogram') {
-              wx.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else {
-              document.addEventListener('UniAppJSBridgeReady', function () {
-                uni.navigateTo({
-                  url: '/pages/index/index'
-                });
-              })
-            }
+            quit();
           });
           });
         } else {
         } else {
           $.confirm("当前云手机正在授控,是否请求获取云手机控制权?", function () {
           $.confirm("当前云手机正在授控,是否请求获取云手机控制权?", function () {

+ 39 - 82
screenIos/WXtrialInterface.html

@@ -36,14 +36,16 @@
   <link rel="stylesheet" href="https://cdn.bootcss.com/weui/1.1.3/style/weui.min.css" />
   <link rel="stylesheet" href="https://cdn.bootcss.com/weui/1.1.3/style/weui.min.css" />
   <link rel="stylesheet" href="https://cdn.bootcss.com/jquery-weui/1.2.1/css/jquery-weui.min.css" />
   <link rel="stylesheet" href="https://cdn.bootcss.com/jquery-weui/1.2.1/css/jquery-weui.min.css" />
   <style>
   <style>
-    .try-use-wrap, .buy-phone-wrap, .look-wrap{
-        width: 100%;
-        height: 100%;
-        position: fixed;
-        top: 0;
-        left: 0;
-        z-index: 9999;
-        background: rgba(0, 0, 0, 0.5);
+    .try-use-wrap,
+    .buy-phone-wrap,
+    .look-wrap {
+      width: 100%;
+      height: 100%;
+      position: fixed;
+      top: 0;
+      left: 0;
+      z-index: 9999;
+      background: rgba(0, 0, 0, 0.5);
       display: none;
       display: none;
     }
     }
 
 
@@ -209,7 +211,6 @@
       </div>
       </div>
     </div>
     </div>
   </div>
   </div>
-  <script type="text/javascript" src="https://js.cdn.aliyun.dcloud.net.cn/dev/uni-app/uni.webview.1.5.2.js"></script>
   <script type="text/javascript" src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js"></script>
   <script type="text/javascript" src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js"></script>
   <script src="https://lf1-cdn-tos.bytegoofy.com/goofy/developer/jssdk/jssdk-1.0.3.js"></script>
   <script src="https://lf1-cdn-tos.bytegoofy.com/goofy/developer/jssdk/jssdk-1.0.3.js"></script>
   <script type="text/javascript" src="jquery-1.11.0.min.js"></script>
   <script type="text/javascript" src="jquery-1.11.0.min.js"></script>
@@ -220,7 +221,7 @@
   <script type="text/javascript" src="webgl.js"></script>
   <script type="text/javascript" src="webgl.js"></script>
   <script type="text/javascript" src="https://cdn.bootcss.com/vConsole/3.2.0/vconsole.min.js"></script>
   <script type="text/javascript" src="https://cdn.bootcss.com/vConsole/3.2.0/vconsole.min.js"></script>
   <script type="text/javascript" src="WXdraw.js"></script>
   <script type="text/javascript" src="WXdraw.js"></script>
-  <script type="text/javascript" src="https://unpkg.com/@dcloudio/uni-webview-js@0.0.2/index.js"></script>
+  <script type="text/javascript" src="https://js.cdn.aliyun.dcloud.net.cn/dev/uni-app/uni.webview.1.5.2.js"></script>
   <script type="text/javascript">
   <script type="text/javascript">
     $(function () {
     $(function () {
       //手指滑动多少距离就认为是滑成功
       //手指滑动多少距离就认为是滑成功
@@ -673,24 +674,7 @@
       decodeWoker.postMessage('close');
       decodeWoker.postMessage('close');
       decodeWoker.terminate();
       decodeWoker.terminate();
       webSocketWorker.terminate();
       webSocketWorker.terminate();
-      if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-        tt.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      } else if (window.__wxjs_environment === 'miniprogram') {
-        wx.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
-      } else {
-        location.href = `${baseUrl}/cloud/phone/web/#/pages/index/index`
-        // 动态设置有问题 https://ask.dcloud.net.cn/question/96060
-        // document.addEventListener('UniAppJSBridgeReady', function() {
-        //   console.log(222)
-        //   uni.navigateTo({
-        //     url: '/pages/index/index'
-        //   });
-        // })
-      }
+      quit();
     })
     })
 
 
     function handleClose() {
     function handleClose() {
@@ -806,22 +790,7 @@
             decodeWoker.postMessage('close');
             decodeWoker.postMessage('close');
             decodeWoker.terminate();
             decodeWoker.terminate();
             webSocketWorker.terminate();
             webSocketWorker.terminate();
-            if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-              tt.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else if (window.__wxjs_environment === 'miniprogram') {
-              wx.miniProgram.switchTab({
-                url: '/pages/home/home'
-              })
-            } else {
-              location.href = `${baseUrl}/cloud/phone/web/#/pages/index/index`
-              // document.addEventListener('UniAppJSBridgeReady', function() {
-              //   uni.navigateTo({
-              //     url: '/pages/index/index'
-              //   });
-              // })
-            }
+            quit();
           }
           }
         }
         }
         if (input[23] == 0x05) { //横竖屏标识
         if (input[23] == 0x05) { //横竖屏标识
@@ -846,22 +815,7 @@
         decodeWoker.postMessage('close');
         decodeWoker.postMessage('close');
         decodeWoker.terminate();
         decodeWoker.terminate();
         webSocketWorker.terminate();
         webSocketWorker.terminate();
-        if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-          tt.miniProgram.switchTab({
-            url: '/pages/home/home'
-          })
-        } else if (window.__wxjs_environment === 'miniprogram') {
-          wx.miniProgram.switchTab({
-            url: '/pages/home/home'
-          })
-        } else {
-          location.href = `${baseUrl}/cloud/phone/web/#/pages/index/index`
-          // document.addEventListener('UniAppJSBridgeReady', function() {
-          //   uni.navigateTo({
-          //     url: '/pages/index/index'
-          //   });
-          // })
-        }
+        quit();
       }
       }
     }
     }
 
 
@@ -1023,9 +977,7 @@
       $('.buy-phone-wrap').eq(0).hide();
       $('.buy-phone-wrap').eq(0).hide();
       if (disconnectionFlag || getDate) {//设置了断线时间,取消直接退出
       if (disconnectionFlag || getDate) {//设置了断线时间,取消直接退出
         systemBuriedPoint('激活码-断线-取消');
         systemBuriedPoint('激活码-断线-取消');
-        wx.miniProgram.switchTab({
-          url: '/pages/home/home'
-        })
+        quit();
         return
         return
       }
       }
       let pointName = '';
       let pointName = '';
@@ -1090,9 +1042,7 @@
       } else {
       } else {
         systemBuriedPoint('激活码-强制关闭-放弃');
         systemBuriedPoint('激活码-强制关闭-放弃');
       }
       }
-      wx.miniProgram.switchTab({
-        url: '/pages/home/home'
-      })
+      quit();
     })
     })
     // 继续观看
     // 继续观看
     $('.looking')[0].addEventListener('click', () => {
     $('.looking')[0].addEventListener('click', () => {
@@ -1152,7 +1102,7 @@
         level = 0;
         level = 0;
       }
       }
     }
     }
-    var hidden, visibilityChange; 
+    var hidden, visibilityChange;
     if (typeof document.hidden !== "undefined") { // Opera 12.10 and Firefox 18 and later support 
     if (typeof document.hidden !== "undefined") { // Opera 12.10 and Firefox 18 and later support 
       hidden = "hidden";
       hidden = "hidden";
       visibilityChange = "visibilitychange";
       visibilityChange = "visibilitychange";
@@ -1167,23 +1117,30 @@
     // 处理页面可见属性的改变
     // 处理页面可见属性的改变
     document.addEventListener("visibilitychange", function () {
     document.addEventListener("visibilitychange", function () {
       if (document[hidden]) {
       if (document[hidden]) {
-        if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
-          tt.miniProgram.switchTab({
-            url: '/pages/home/home'
-          })
-        } else if (window.__wxjs_environment === 'miniprogram') {
-          wx.miniProgram.switchTab({
-            url: '/pages/home/home'
-          })
-        } else {
-          document.addEventListener('UniAppJSBridgeReady', function () {
-            uni.navigateTo({
-              url: '/pages/index/index'
-            });
-          })
-        }
+        quit();
+        wsss.close();
+        decodeWoker.postMessage('close');
+        decodeWoker.terminate();
+        webSocketWorker.terminate();
       }
       }
     }, false);
     }, false);
+
+    function quit() {
+      if (navigator.userAgent.toLowerCase().includes('toutiaomicroapp')) {
+        tt.miniProgram.switchTab({
+          url: '/pages/home/home'
+        })
+      } else if (window.__wxjs_environment === 'miniprogram') {
+        wx.miniProgram.switchTab({
+          url: '/pages/home/home'
+        })
+      } else {
+        uni.webView.navigateTo({
+          url: '/pages/index/index'
+        });
+      }
+    }
+
     window.onbeforeunload = function () {
     window.onbeforeunload = function () {
       wsss.close();
       wsss.close();
       decodeWoker.postMessage('close');
       decodeWoker.postMessage('close');

+ 0 - 8
screenIos/decoder.js

@@ -54,14 +54,6 @@ self.addEventListener('message', function (e) {
 
 
     }
     }
   }
   }
-
-  if (msg.type == "switchSharpness") { // 分辨率切换实现
-    /*isSwitchSharpness = true;
-    closeDecoder();
-    var ret = Module._openDecoder();//再次开启解码器
-    var timeFlag = setInterval(decodeVideo, 1);
-    console.log("切换解码器成功");*/
-  }
 }, false);
 }, false);
 
 
 function PrintfLog(str) {
 function PrintfLog(str) {