diff --git a/page_components/fuwu/index.vue b/page_components/fuwu/index.vue
index a61be6c..89db0a8 100644
--- a/page_components/fuwu/index.vue
+++ b/page_components/fuwu/index.vue
@@ -304,6 +304,44 @@
})
},
methods: {
+ //选择套餐
+ btnactive(item) {
+ console.log(item);
+ this.prices = item.price
+ this.sytime = item.value
+ this.zfobj = item
+ this.indexactive = item.suitId
+ this.suitTimeUnit = item.timeUnit
+ this.suitPrice = item.price
+ this.suitGearAmount = item.gearAmount
+ this.suitGearTime = item.gearTime
+ this.suitFeeMode = item.feeMode
+ this.suitFeeType = item.feeType
+ if(item.feeMode == 2 && ['1','2'].includes(item.feeType)){
+ let sum = item.deposit / item.price
+ if(item.timeUnit == 1){
+ this.jine = item.value * 24 * 60 * 60 * sum
+ }else if(item.timeUnit == 2){
+ this.jine = item.value * 60 * 60 * sum
+ }else if(item.timeUnit == 3){
+ this.jine = item.value * 60 * sum
+ }else if(item.timeUnit == 4){
+ this.jine = item.value * sum
+ }
+ }else{
+ if(item.timeUnit == 1){
+ this.jine = item.value * 24 * 60 * 60
+ }else if(item.timeUnit == 2){
+ this.jine = item.value * 60 * 60
+ }else if(item.timeUnit == 3){
+ this.jine = item.value * 60
+ }else if(item.timeUnit == 4){
+ this.jine = item.value
+ }
+ }
+
+ console.log(this.jine);
+ },
// 点击我已知晓隐藏防骗提示
btnswindleflag(){
this.swindleflag = false
@@ -1382,30 +1420,6 @@
}
}, 15);
},
- //选择套餐
- btnactive(item) {
- // this.zhifuflag = true
- this.prices = item.price
- this.sytime = item.value
- this.zfobj = item
- this.indexactive = item.suitId
- this.suitTimeUnit = item.timeUnit
- this.suitPrice = item.price
- this.suitGearAmount = item.gearAmount
- this.suitGearTime = item.gearTime
- this.suitFeeMode = item.feeMode
- this.suitFeeType = item.feeType
- if(item.timeUnit == 1){
- this.jine = item.value * 24 * 60 * 60
- }else if(item.timeUnit == 2){
- this.jine = item.value * 60 * 60
- }else if(item.timeUnit == 3){
- this.jine = item.value * 60
- }else if(item.timeUnit == 4){
- this.jine = item.value
- }
- console.log(this.jine);
- },
checkboxChange(e) {
this.checked = e.value
},
diff --git a/page_user/wifijoint/index.vue b/page_user/wifijoint/index.vue
index 152a878..92f7cdb 100644
--- a/page_user/wifijoint/index.vue
+++ b/page_user/wifijoint/index.vue
@@ -41,10 +41,14 @@
版本号:{{obj.version == undefined ? '--' : obj.version}}
+
+ 最后更新时间:{{obj.lastPullTime == undefined ? '--' : obj.lastPullTime}}
+
最后在线时间:{{obj.lastOnlineTime == undefined ? '--' : obj.lastOnlineTime}}
+
@@ -57,6 +61,14 @@
+
+
+ 重启
+
+
+ 刷新
+
+
开启
@@ -65,7 +77,7 @@
关闭
- 刷新
+ 同步
@@ -84,7 +96,6 @@
backgroundColor: "#F7FAFE",
},
storeId: '',
- storeIds: '',
obj: {},
id: '',
onlineStatus: '--',
@@ -117,6 +128,9 @@
}
},
methods: {
+ btnsxs(){
+
+ },
btnjian(){
this.valuedian = Number(this.valuedian) - 1
},
@@ -124,8 +138,24 @@
this.valuedian = Number(this.valuedian) + 1
},
btnjiaozhun(){
- this.x = this.obj.voltage / this.valuedian * this.xshu
+ this.x = this.valuedian / this.obj.voltage * this.xshu
+ this.x = this.x.toFixed(3)
console.log(this.x)
+ this.$u.put(`/app/device/admin/${this.obj.deviceId}/vxs?vxs=${this.x}`).then(res => {
+ if(res.code == 200){
+ uni.showToast({
+ title: '校准成功',
+ icon: 'success',
+ duration:2000
+ })
+ this.getsn()
+ }else{
+ uni.showToast({
+ title: res.msg,
+ icon: 'none'
+ })
+ }
+ })
},
btnmy() {
@@ -160,14 +190,18 @@
},
getsn() {
- if (this.storeId == '' || this.storeId == null) {
- this.$u.get(`/app/device/${this.storeIds}/bySn`).then(res => {
+ this.$u.get(`/app/device/admin/get?sn=${this.storeId}`).then(res => {
if (res.code == 200) {
this.obj = res.data
this.id = res.data.deviceId
+ if(res.data.vxs == null){
+ this.xshu = 1
+ }else{
+ this.xshu = res.data.vxs
+ }
if (res.data.onlineStatus == 0) {
this.onlineStatus = '离线'
- } else if (res.data.onlineStatus == 1) {
+ } else if (res.data.onlineStatus == 1) {
this.onlineStatus = '在线'
}
if (res.data.powerStatus == 0) {
@@ -189,36 +223,6 @@
})
}
})
- }else{
- this.$u.get(`/app/device/${this.storeId}/bySn`).then(res => {
- if (res.code == 200) {
- this.obj = res.data
- this.id = res.data.deviceId
- if (res.data.onlineStatus == 0) {
- this.onlineStatus = '离线'
- } else if (res.data.onlineStatus == 1) {
- this.onlineStatus = '在线'
- }
- if (res.data.powerStatus == 0) {
- this.powerStatus = '关闭'
- } else if (res.data.powerStatus == 1) {
- this.powerStatus = '开启'
- }
- uni.showToast({
- title: res.msg,
- icon: 'success',
- duration: 2000,
- })
- uni.hideLoading()
- } else {
- uni.showToast({
- title: res.msg,
- icon: 'none',
- duration: 2000,
- })
- }
- })
- }
},
// 返回录入
@@ -349,13 +353,12 @@
.anniulist {
width: 658rpx;
margin: auto;
- margin-top: 200rpx;
+ margin-top: 20rpx;
text-align: left;
font-size: 32rpx;
display: flex;
- justify-content: space-between;
-
.anniu {
+ margin-right: 20rpx;
width: 30%;
height: 90rpx;
border-radius: 20rpx;
diff --git a/pages/shouye/index.vue b/pages/shouye/index.vue
index 650713b..5b0700b 100644
--- a/pages/shouye/index.vue
+++ b/pages/shouye/index.vue
@@ -216,12 +216,12 @@
} else if (res.data == 0) {
uni.showModal({
title: '提示',
- content: '该设备未录入,你需进行录入吗?',
+ content: '该设备未录入,请先进行录入',
success: function(res) {
if (res.confirm) {
- uni.navigateTo({
- url: '/page_fenbao/zhuce?sn=' + id
- })
+ // uni.navigateTo({
+ // url: '/page_fenbao/zhuce?sn=' + id
+ // })
}
}
})
@@ -525,12 +525,12 @@
} else if (res.data == 0) {
uni.showModal({
title: '提示',
- content: '该设备未录入,你需进行录入吗?',
+ content: '该设备未录入,请先进行录入',
success: function(res) {
if (res.confirm) {
- uni.navigateTo({
- url: '/page_fenbao/zhuce?sn=' + id
- })
+ // uni.navigateTo({
+ // url: '/page_fenbao/zhuce?sn=' + id
+ // })
} else if (res.cancel) {
}