From 1f745600c96e344fb2e1db0fae42a5472d1b56cc Mon Sep 17 00:00:00 2001 From: zhaojs <349234519@qq.com> Date: 星期四, 13 七月 2023 15:48:48 +0800 Subject: [PATCH] no message --- public/html/compareprice.html | 63 +++++++++++++++++++------------ 1 files changed, 39 insertions(+), 24 deletions(-) diff --git a/public/html/compareprice.html b/public/html/compareprice.html index 0c4c5e1..ed7ed01 100644 --- a/public/html/compareprice.html +++ b/public/html/compareprice.html @@ -28,7 +28,6 @@ { width: 95%; margin: 0 auto; - min-height: 23rem; margin-top: 5.3rem; position:relative; } @@ -104,7 +103,7 @@ width: 100%; text-align: center; margin: 0 auto; - line-height: 6.2rem; + line-height: 1.2rem; color: #a69b9b; font-size: 14px; } @@ -369,7 +368,11 @@ })(); function scanCode(str) { - app.coptest(str); + app.copytxt(str); + } + function likeDataGet(data) + { + app.likeDataGet(data); } Vue.use(VueLazyload, { preLoad: 1.3,// @@ -388,13 +391,42 @@ txtplaceholder:'1銆佹敮鎸佹窐瀹濄�佸ぉ鐚�佷含涓溿�佹姈闊炽�佹嫾澶氬绛夊瀹剁數鍟� \r\n 2銆佽绮樿创鎮ㄩ渶瑕佽浆鎹㈢殑鍒嗕韩鏂囨/閾炬帴鍜屽彛浠�/鍟嗗搧閾炬帴;涓嶆敮鎸佸埜閾炬帴' }, methods:{ + likeDataGet:function(postData) + { + $.ajax({ + headers:{ + "token":this.getUrlPar("token") + }, + + url:_this.posturl+'/api/taoke/get_goods_things', + type:"post", + dataType:"json", + async: false, + data:{ + deviceType:postData.postData, + deviceValue:postData.deviceValue, + pageId:1, + pageSize:10, + type:1 + } + }).done(function(res){ + console.log(res); + }) + }, + getLikeGoods:function() + { + uni.postMessage({ + data: { + action: 'copy' + } + }) + }, clear:function() { this.txtareatxt=''; }, copytxt(str) { - alert(str.data); if(str&&str.data&&str.data.length>0) { this.txtareatxt=str.data; @@ -406,25 +438,6 @@ data: { action: 'copy' } - }) - }, - getCmsUrl:function(){ - var _this = this; - _this.loading=true; - $.ajax({ - headers:{ - "token":this.getUrlPar("token") - }, - - url:_this.posturl+'/api/activity/cmsGet', - type:"post", - dataType:"json", - async: false, - data:{ - - } - }).done(function(res){ - }) }, getUrlPar:function(name) @@ -458,7 +471,9 @@ }, }, mounted:function(){ - this.getGoodsList(); + document.addEventListener('UniAppJSBridgeReady', function() { + this.getLikeGoods(); + }); } }) </script> \ No newline at end of file -- Gitblit v1.9.3