究极更新
This commit is contained in:
parent
0813c46109
commit
38881b3947
|
@ -2,8 +2,8 @@
|
||||||
"name": "种植溯源",
|
"name": "种植溯源",
|
||||||
"appid": "__UNI__D087881",
|
"appid": "__UNI__D087881",
|
||||||
"description": "",
|
"description": "",
|
||||||
"versionName": "1.0.4",
|
"versionName": "1.0.7",
|
||||||
"versionCode": 104,
|
"versionCode": 107,
|
||||||
"transformPx": false,
|
"transformPx": false,
|
||||||
/* 5+App特有相关 */
|
/* 5+App特有相关 */
|
||||||
"app-plus": {
|
"app-plus": {
|
||||||
|
|
|
@ -42,7 +42,7 @@
|
||||||
|
|
||||||
<view class="get-code" :style="{color: countDown?'#ADADAD':''}" @click="getCode"><text
|
<view class="get-code" :style="{color: countDown?'#ADADAD':''}" @click="getCode"><text
|
||||||
class="lineY"></text>
|
class="lineY"></text>
|
||||||
获取验证码 <text v-if='countDown'>{{countDown}}s</text> </view>
|
验证码 <text v-if='countDown'>{{countDown}}s</text> </view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="" style="margin: 30rpx 0;">
|
<view class="" style="margin: 30rpx 0;">
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
shwovideo: false,
|
shwovideo: false,
|
||||||
shwovideoTimer: "",
|
shwovideoTimer: "",
|
||||||
initFailTimer: "",
|
initFailTimer: "",
|
||||||
flag: true
|
flag: true,
|
||||||
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -49,7 +49,7 @@
|
||||||
scene: 'app',
|
scene: 'app',
|
||||||
}
|
}
|
||||||
this.openScoket(data)
|
this.openScoket(data)
|
||||||
this.canplay(option.device)
|
// this.canplay(option.device)
|
||||||
this.platform = uni.getSystemInfoSync().platform
|
this.platform = uni.getSystemInfoSync().platform
|
||||||
this.windowWidth = uni.getSystemInfoSync().screenWidth //获取屏幕宽度
|
this.windowWidth = uni.getSystemInfoSync().screenWidth //获取屏幕宽度
|
||||||
this.boxStyle.width = this.windowWidth + 'px' //给宽度加px
|
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编码
|
// 接收图片的base64编码
|
||||||
receiveImg(data) {
|
receiveImg(data) {
|
||||||
|
@ -134,16 +119,21 @@
|
||||||
this.vsrc = options;
|
this.vsrc = options;
|
||||||
},
|
},
|
||||||
openScoket(scoketData) {
|
openScoket(scoketData) {
|
||||||
|
let that = this
|
||||||
uni.connectSocket({
|
uni.connectSocket({
|
||||||
url: 'wss://iot.lihaink.cn/test'
|
url: 'wss://iot.lihaink.cn/test'
|
||||||
});
|
});
|
||||||
uni.onSocketOpen(function(res) {
|
uni.onSocketOpen(function(res) {
|
||||||
|
|
||||||
|
console.log("scoket open")
|
||||||
uni.sendSocketMessage({
|
uni.sendSocketMessage({
|
||||||
data: JSON.stringify(scoketData)
|
data: JSON.stringify(scoketData)
|
||||||
|
|
||||||
});
|
});
|
||||||
uni.onSocketMessage(function(res) {
|
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) {
|
uni.onSocketError(function(res) {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<view id="subNvue">
|
<view id="subNvue">
|
||||||
<view class="" style="background-color: white;width: 750rpx;height:1000px;position: relative;">
|
<view class="" style="background-color: white;width: 750rpx;height:1000px;position: relative;">
|
||||||
<view class="" style="margin-top: 350px;">
|
<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>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -7,8 +7,8 @@
|
||||||
"id": "__UNI__D087881",
|
"id": "__UNI__D087881",
|
||||||
"name": "种植溯源",
|
"name": "种植溯源",
|
||||||
"version": {
|
"version": {
|
||||||
"name": "1.0.4",
|
"name": "1.0.7",
|
||||||
"code": 104
|
"code": 107
|
||||||
},
|
},
|
||||||
"description": "",
|
"description": "",
|
||||||
"developer": {
|
"developer": {
|
||||||
|
|
Loading…
Reference in New Issue