修改670人员信息重复发送的问题/修改版本更新的方式/加入检查更新的连接
This commit is contained in:
@ -2,7 +2,7 @@
|
|||||||
const config = {
|
const config = {
|
||||||
// 开发环境
|
// 开发环境
|
||||||
development: {
|
development: {
|
||||||
BASE_URL: 'http://192.168.110.56:8000',
|
BASE_URL: 'https://www.cnxhyc.com/jq',
|
||||||
API_PREFIX: '',
|
API_PREFIX: '',
|
||||||
// MQTT 配置
|
// MQTT 配置
|
||||||
MQTT_HOST: 'www.cnxhyc.com',
|
MQTT_HOST: 'www.cnxhyc.com',
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
"name" : "星汉物联",
|
"name" : "星汉物联",
|
||||||
"appid" : "__UNI__A21EF43",
|
"appid" : "__UNI__A21EF43",
|
||||||
"description" : "设备管控",
|
"description" : "设备管控",
|
||||||
"versionName" : "1.0.3",
|
"versionName" : "1.0.4",
|
||||||
"versionCode" : "100",
|
"versionCode" : "100",
|
||||||
"transformPx" : false,
|
"transformPx" : false,
|
||||||
/* 5+App特有相关 */
|
/* 5+App特有相关 */
|
||||||
|
|||||||
@ -591,8 +591,8 @@
|
|||||||
that.formData.address = res.address;
|
that.formData.address = res.address;
|
||||||
let personnelInfo = res.personnelInfo;
|
let personnelInfo = res.personnelInfo;
|
||||||
if (personnelInfo) {
|
if (personnelInfo) {
|
||||||
that.formData.company = personnelInfo.name;
|
that.formData.company = personnelInfo.unitName;
|
||||||
that.formData.usrname = personnelInfo.unitName;
|
that.formData.usrname = personnelInfo.name;
|
||||||
that.formData.job = personnelInfo.position;
|
that.formData.job = personnelInfo.position;
|
||||||
that.formData.usrid = personnelInfo.code
|
that.formData.usrid = personnelInfo.code
|
||||||
}
|
}
|
||||||
@ -2100,12 +2100,14 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
let requestSend = () => {
|
let requestSend = () => {
|
||||||
|
|
||||||
|
|
||||||
let json = {
|
let json = {
|
||||||
deviceId: this.device.id,
|
deviceId: this.device.id,
|
||||||
deviceImei: this.device.deviceImei ? this.device.deviceImei : this.formData.imei,
|
deviceImei: this.device.deviceImei ? this.device.deviceImei : this.formData.imei,
|
||||||
name: this.formData.company,
|
unitName: this.formData.company,
|
||||||
position: this.formData.usrname,
|
name: this.formData.usrname,
|
||||||
unitName: this.formData.job,
|
position: this.formData.job,
|
||||||
code: this.formData.usrid
|
code: this.formData.usrid
|
||||||
};
|
};
|
||||||
api.sendUsr(json).then((res) => {
|
api.sendUsr(json).then((res) => {
|
||||||
@ -2257,10 +2259,10 @@
|
|||||||
|
|
||||||
// 发送下一个包
|
// 发送下一个包
|
||||||
currentPacket++;
|
currentPacket++;
|
||||||
setTimeout(sendNextPacket, 2000);
|
setTimeout(sendNextPacket, 200);
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
if (err.code == '10007') {
|
if (err.code == '10007') {
|
||||||
setTimeout(sendNextPacket,2000);
|
setTimeout(sendNextPacket,200);
|
||||||
} else {
|
} else {
|
||||||
requestSend();
|
requestSend();
|
||||||
}
|
}
|
||||||
@ -2282,7 +2284,7 @@
|
|||||||
these.HoldYouHand("word transmit start", 120, f.deviceId, f.writeServiceId, f
|
these.HoldYouHand("word transmit start", 120, f.deviceId, f.writeServiceId, f
|
||||||
.wirteCharactId).then(
|
.wirteCharactId).then(
|
||||||
() => {
|
() => {
|
||||||
setTimeout(sendText, 2000);
|
setTimeout(sendText, 200);
|
||||||
}).catch((ex) => {
|
}).catch((ex) => {
|
||||||
requestSend();
|
requestSend();
|
||||||
// console.log("握手没有成功", ex);
|
// console.log("握手没有成功", ex);
|
||||||
|
|||||||
@ -22,9 +22,14 @@
|
|||||||
<text class="title">隐私协议</text>
|
<text class="title">隐私协议</text>
|
||||||
<uni-icons type="right" size="25" color="rgba(255, 255, 255, 0.4)" class="uniIcon"></uni-icons>
|
<uni-icons type="right" size="25" color="rgba(255, 255, 255, 0.4)" class="uniIcon"></uni-icons>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="menu-item" @click="gotoAppStore()">
|
||||||
|
<image src="/static/images/common/ver.png" class="icon"></image>
|
||||||
|
<text class="title">版本更新 ({{appVersion}})</text>
|
||||||
|
<uni-icons type="right" size="25" color="rgba(255, 255, 255, 0.4)" class="uniIcon"></uni-icons>
|
||||||
|
</view>
|
||||||
<view class="menu-item" @click="aboutUs">
|
<view class="menu-item" @click="aboutUs">
|
||||||
<image src="/static/images/common/wm.png" class="icon"></image>
|
<image src="/static/images/common/wm.png" class="icon"></image>
|
||||||
<text class="title">关于我们 ({{appVersion}})</text>
|
<text class="title">关于我们</text>
|
||||||
<uni-icons type="right" size="25" color="rgba(255, 255, 255, 0.4)" class="uniIcon"></uni-icons>
|
<uni-icons type="right" size="25" color="rgba(255, 255, 255, 0.4)" class="uniIcon"></uni-icons>
|
||||||
</view>
|
</view>
|
||||||
<view class="menu-item" @click="account">
|
<view class="menu-item" @click="account">
|
||||||
@ -88,6 +93,25 @@
|
|||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
//版本更新
|
||||||
|
gotoAppStore(){
|
||||||
|
let os=uni.getSystemInfoSync().platform;
|
||||||
|
let url=''
|
||||||
|
if(os==='ios'){
|
||||||
|
url='https://apps.apple.com/cn/app/星汉物联/id6752555460'
|
||||||
|
}
|
||||||
|
|
||||||
|
else if(os==='android'){
|
||||||
|
url='https://www.pgyer.com/xhwl';
|
||||||
|
}
|
||||||
|
|
||||||
|
plus.runtime.openURL(url, (res) => {
|
||||||
|
uni.showToast({
|
||||||
|
title: '打开失败',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
// 取消
|
// 取消
|
||||||
handleDisagree() {
|
handleDisagree() {
|
||||||
this.showAgreement = false,
|
this.showAgreement = false,
|
||||||
|
|||||||
BIN
static/images/common/ver.png
Normal file
BIN
static/images/common/ver.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.0 KiB |
@ -62,7 +62,7 @@ function checkAndUpdateWgt(updateUrl) {
|
|||||||
appId: "xhyc"
|
appId: "xhyc"
|
||||||
},
|
},
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
// console.log("res=>",res)
|
// console.log("res=>",res)//坑,404居然进success
|
||||||
if (res.statusCode === 200) {
|
if (res.statusCode === 200) {
|
||||||
res.type = '1';
|
res.type = '1';
|
||||||
resolve(res);
|
resolve(res);
|
||||||
|
|||||||
Reference in New Issue
Block a user