究极更新

This commit is contained in:
lxz 2024-01-09 18:17:29 +08:00
parent 0813c46109
commit 38881b3947
6 changed files with 16 additions and 26 deletions

View File

@ -2,8 +2,8 @@
"name": "种植溯源",
"appid": "__UNI__D087881",
"description": "",
"versionName": "1.0.4",
"versionCode": 104,
"versionName": "1.0.7",
"versionCode": 107,
"transformPx": false,
/* 5+App */
"app-plus": {

View File

@ -42,7 +42,7 @@
<view class="get-code" :style="{color: countDown?'#ADADAD':''}" @click="getCode"><text
class="lineY"></text>
获取验证码 <text v-if='countDown'>{{countDown}}s</text> </view>
验证码 <text v-if='countDown'>{{countDown}}s</text> </view>
</view>
<view class="" style="margin: 30rpx 0;">

View File

@ -32,7 +32,7 @@
shwovideo: false,
shwovideoTimer: "",
initFailTimer: "",
flag: true
flag: true,
}
},
@ -49,7 +49,7 @@
scene: 'app',
}
this.openScoket(data)
this.canplay(option.device)
// this.canplay(option.device)
this.platform = uni.getSystemInfoSync().platform
this.windowWidth = uni.getSystemInfoSync().screenWidth //
this.boxStyle.width = this.windowWidth + 'px' //px
@ -95,22 +95,7 @@
}
},
plusDownloader(url, options = {}) {
return new Promise((result, reject) => {
let dtask = plus.downloader.createDownload(url, options, function(d, status) {
if (status == 200) {
console.log("Download success: " + JSON.stringify(d));
plus.runtime.openFile(d.filename, (err) => {
console.log(err);
});
} else {
console.log("Download failed: " + status);
}
});
dtask.start();
})
},
// base64
receiveImg(data) {
@ -134,16 +119,21 @@
this.vsrc = options;
},
openScoket(scoketData) {
let that = this
uni.connectSocket({
url: 'wss://iot.lihaink.cn/test'
});
uni.onSocketOpen(function(res) {
console.log("scoket open")
uni.sendSocketMessage({
data: JSON.stringify(scoketData)
});
uni.onSocketMessage(function(res) {
console.log(res);
console.log(JSON.parse(res.data).code, "收到消息")
if (JSON.parse(res.data).code == 200) {
that.shwovideo = true
}
});
});
uni.onSocketError(function(res) {

View File

@ -2,7 +2,7 @@
<view id="subNvue">
<view class="" style="background-color: white;width: 750rpx;height:1000px;position: relative;">
<view class="" style="margin-top: 350px;">
<u-loading-icon mode="semicircle" text="疯狂加载中..." textSize="18"></u-loading-icon>
<u-loading-icon mode="semicircle" text="初始化中,请稍等..." textSize="18"></u-loading-icon>
</view>
</view>

File diff suppressed because one or more lines are too long

View File

@ -7,8 +7,8 @@
"id": "__UNI__D087881",
"name": "种植溯源",
"version": {
"name": "1.0.4",
"code": 104
"name": "1.0.7",
"code": 107
},
"description": "",
"developer": {