Ver código fonte

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

曾志翔 2 anos atrás
pai
commit
e25d8d6361

+ 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",

+ 97 - 0
static/microserviceUserH5/static/css/trialActivities.css

@@ -0,0 +1,97 @@
+@media screen and (max-width: 750px) {
+    html {
+      font-size: calc(100vw / 7.5);
+    }
+  }
+  
+@media screen and (min-width: 750px)  {
+  html {
+    font-size: calc(450px / 7.5);
+  }
+}
+
+html, body, div, ul, li, p {
+    padding: 0;
+    margin: 0;
+}
+
+
+ul, li {
+    list-style: none;
+}
+
+.containers{
+    width: 7.5rem;
+    margin: auto;
+    background-image: url('../img/yunActivity/bgc0.png'); 
+    background-size: 100% 100%; 
+}
+
+.banner-wrap{
+    width: 7.5rem;
+    height: 25.67rem;
+    position: relative;
+}
+
+.banner-img {
+    position: fixed;
+    width: 7.5rem;
+    height: 1.28rem;
+    top: 0;
+    z-index: 1;
+}
+
+.downlond-img {
+    position: fixed;
+    top: 0.3rem;
+    right: 0.3rem;
+    width: 2.2rem;
+    height: 0.7rem;
+    z-index: 1;
+}
+
+.downlond-midimg {
+    position: absolute;
+    top: 10.8rem;
+    left: 50%;
+    margin-left: -2.15rem;
+    width: 4.3rem;
+    height: 1.12rem;
+}
+
+
+#toast-container>.toast-error {
+    background-image: none !important;
+    border-radius: 0.2rem;
+  }
+  
+  .toast-error {
+    background-color: rgba(0, 0, 0, 0.8);
+    border-radius: 0.2rem;
+  }
+  
+  #toast-container>div {
+    font-size: 14px;
+    min-width: 80px !important;
+    padding: 12px !important;
+    box-shadow: none;
+    border-radius: 0.2rem;
+  }
+  
+  .toast-center-center {
+    position: fixed;
+    min-width: 220px;
+    top: 50%;
+    left: 50%;
+    text-align: center;
+    transform: translateX(-50%);
+    color: #FFFFFF;
+    border-radius: 0.2rem;
+  }
+  
+  @media (max-width: 480px) and (min-width: 241px) {
+    #toast-container>div {
+      min-width: 80px !important;
+      width: auto;
+    }
+  }

BIN
static/microserviceUserH5/static/img/yunActivity/bgc0.png


BIN
static/microserviceUserH5/static/img/yunActivity/btn-1.png


BIN
static/microserviceUserH5/static/img/yunActivity/btn-2.png


BIN
static/microserviceUserH5/static/img/yunActivity/header.png


+ 130 - 0
static/microserviceUserH5/vcloud/trialActivities.html

@@ -0,0 +1,130 @@
+<!DOCTYPE html>
+<html lang="zh-CN">
+<head>
+	<meta charset="UTF-8">
+	<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
+	<title>双子星云手机</title>
+	<link rel="icon" href="../static/img/favicon2.ico" type="img/x-ico">
+	<link rel="stylesheet" href="../static/js/vender/bootstrap/css/bootstrap.min.css">
+	<link rel="stylesheet" href="../static/js/vender/toastr/toastr.min.css">
+	<link rel="stylesheet" href="../static/css/trialActivities.css">
+	<script src="../static/js/vender/jquery-3.4.1.min.js"></script>
+	<script src="../static/js/vender/toastr/toastr.min.js"></script>
+	<script src="../static/js/vender/config.js"></script>
+	<script src="../static/js/vender/crypto-js.js"></script>
+	<script src="../static/js/vender/ase.js"></script>
+</head>
+
+<body>
+	<div class="containers">
+			<div class="banner-wrap">
+				<div class="img-title">
+					<img class="banner-img" src="../static/img/yunActivity/header.png">
+				</div>
+                <div class="img-downlond">
+                    <img class="downlond-img" src="../static/img/yunActivity/btn-1.png">
+                </div>
+                <div class="midimg-downlond">
+                    <img class="downlond-midimg" src="../static/img/yunActivity/btn-2.png">  
+                </div>
+			</div>
+	</div>
+	<script>
+		toastr.options.positionClass = 'toast-center-center';
+		toastr.options.timeOut = '3000';
+	</script>
+	<script type="text/javascript">
+		// var baseUrl = 'http://14.18.190.141:1280'
+		let timer, flag = true;
+		var url = window.location.href;
+		url = url.split('/')
+		var loc = window.location.search,
+			n1 = loc.length,//地址的总长度
+			n2 = loc.indexOf("="),//取得=号的位置
+			id = loc.substr(n2 + 1, n1 - n2),//从=号后面的内容
+			u = navigator.userAgent,
+			ua = navigator.userAgent.toLowerCase(),
+			isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/),
+			isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //android终端
+        $('.downlond-img')[0].addEventListener('click',()=>{
+                if(isAndroid){
+		 	     const pointName = '0元试用h5落地页安卓点击' + id
+		         operate(pointName,'click');
+				 download()
+		        }else if(isIOS){
+		        	const pointName = '0元试用h5落地页IOS点击' + id
+		        	operate(pointName);
+				 download()
+		        }
+                 // download()
+        },false)   
+        
+        $('.downlond-midimg')[0].addEventListener('click',()=>{
+                if(isAndroid){
+		 	     const pointName = '0元试用h5落地页安卓点击' + id
+		         operate(pointName,'click');
+				download()
+		        }else if(isIOS){
+		        	const pointName = '0元试用h5落地页IOS点击' + id
+		        	operate(pointName);
+				download()
+		        }
+                // download()
+        },false)   
+		function download() {
+            if (isAndroid) {
+				window.location.href = window.location.protocol === 'https:' ? `https://file.phone.androidscloud.com:8121/document/newFile/download/1/edv834e74a9c43eaac02/LowLevelMultipartUpload_19066905949412147255/shuangzixing.apk` : 
+				`http://110.53.221.195:8210/document/newFile/download/1/edv834e74a9c43eaac02/LowLevelMultipartUpload_19066905949412147255/shuangzixing.apk`;
+				stopManyClick(() =>{
+					toastr.error('下载成功')
+				})
+            } else if (isIOS) {
+                document.location.href = 'https://www.pgyer.com/gemini6?timestamp=' + Math.random();
+                // toastr.error('下载成功')
+            } 
+        }
+		// 埋点下载
+		function operate(pointName) {
+			$.ajax({
+				url: baseUrl + '/api/public/v1/systemBuriedPoint/stat',
+				type: 'post',
+				data: JSON.stringify({
+					pointName: pointName
+				}),
+				contentType: "application/json",
+				dataType: 'json',
+				cache: false,
+				success: function (res) {},
+			})
+		}
+		// 埋点页面访问
+		// var newpage = window.location.search.substring(6);
+		$(function() {
+			pushHistory();
+			function pushHistory() {
+				var warids = {
+					"pointName": `0元试用h5落地页打开${id}`  
+				}
+				$.ajax({
+					url: baseUrl + "/api/public/v1/systemBuriedPoint/stat",
+					data: JSON.stringify(warids),
+					type: 'post',
+					dataType: 'json',
+					contentType: "application/json;charset=UTF-8",
+					cache: false,
+					success: function(data) {}
+				})
+			}
+		});
+		function stopManyClick(fn) {
+			if (flag) {
+				fn();
+			}
+			flag = false;
+			if (timer) { clearTimeout(timer); }
+			timer = setTimeout(() => { flag = true }, 1500);
+		}
+	</script>
+</body>
+
+</html>

+ 16 - 0
static/screenAndroid/WXtrialInterface.html

@@ -1394,8 +1394,24 @@
           success: function (res) {},
         });
       }
+      // 观看广告次数上报
+      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();
       });
       // 点击取消

+ 25 - 10
static/screenIos/WXtrialInterface.html

@@ -251,15 +251,6 @@
       });
     </script>
     <script>
-      var videoTimer = null,
-        videoTime = 0,
-        adType = 0,
-        sourceType = isNaN(parameters['sourceType'])
-          ? sourceType
-          : +parameters['sourceType'],
-        disconnectionFlag = false,
-        getDate = false;
-
       // 开发环境
       var isDev =
         /^192\.168\./.test(location.host) || /^localhost/.test(location.host);
@@ -278,6 +269,15 @@
       var token = parameters['token'];
       var mealType = parameters['mealType'];
       var userCardId = parameters['userCardId'];
+      
+      var videoTimer = null,
+        videoTime = 0,
+        adType = 0,
+        sourceType = isNaN(parameters['sourceType'])
+          ? sourceType
+          : +parameters['sourceType'],
+        disconnectionFlag = false,
+        getDate = false;
 
       if (mealType === 'VIP') {
         $('.loading_sceen_pic').attr('src', '../static/img/home_bg_VIP.png');
@@ -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();
       });
       // 点击取消