wx-program
sunmeng 2024-09-09 17:27:21 +08:00
parent 6c3aec7e61
commit 90d0d82de1
3 changed files with 13 additions and 9 deletions

View File

@ -55,6 +55,7 @@ let api = {
camera_gethls:'/camera/gethls',//获取摄像头得地址 camera_gethls:'/camera/gethls',//获取摄像头得地址
camera_getphonehls:'/camera/getphonehls',//获取摄像头得地址 Copy Copy Copy Copy camera_getphonehls:'/camera/getphonehls',//获取摄像头得地址 Copy Copy Copy Copy
getFi_getName:'/getFi/getName',//查看用户智能灌溉组名称信息
readFs_byid:'/readFs/byid',//查看用户施肥机名称信息 readFs_byid:'/readFs/byid',//查看用户施肥机名称信息
getFiState:"/getFI/getState",//智能灌溉控制器读取. getFiState:"/getFI/getState",//智能灌溉控制器读取.
getFi_rtdata:"/getFi/rtdata",//首页智能灌溉 getFi_rtdata:"/getFi/rtdata",//首页智能灌溉

View File

@ -1,6 +1,6 @@
<template> <template>
<view class="fertilizer_machine"> <view class="fertilizer_machine">
<u-navbar :background="background" :is-back='true' back-icon-color='#FFFFFF' :border-bottom="false" title="施肥机" <u-navbar :background="background" :is-back='true' back-icon-color='#FFFFFF' :border-bottom="false" title="智能灌溉控制器"
title-color='#FFFFFF' :title-bold='true' title-size='32'></u-navbar> title-color='#FFFFFF' :title-bold='true' title-size='32'></u-navbar>
<view class="content"> <view class="content">
@ -106,10 +106,11 @@
</view> </view>
</view> </view>
</view> </view>
<view class="set"> <view class="set" v-if="readFs_byid_name_obj">
<view class="item" v-for="(item,index) in 16" :key="index" @click="showPop(index+1)"> <view class="item" v-for="(item,index) in 16" :key="index" @click="showPop(index+1)">
<view class="left"> <view class="left">
{{index+1}}#灌溉组 {{readFs_byid_name_obj['name'+(index+1)]}}
</view> </view>
<view class="right"> <view class="right">
<text>设置</text> <text>设置</text>
@ -395,7 +396,7 @@
timer_: null, timer_: null,
readFs_byid_name_obj:{}, readFs_byid_name_obj:null,
readFs_byid_list:[ readFs_byid_list:[
'solenoidOne', 'solenoidOne',
'solenoidTwo', 'solenoidTwo',
@ -501,7 +502,7 @@
getReadFs_byid(){ getReadFs_byid(){
let deviceId = this.deviceId; let deviceId = this.deviceId;
this.$http({ this.$http({
url:this.api.readFs_byid + '?deviceId=' + deviceId, url:this.api.getFi_getName + '?deviceId=' + deviceId,
method:'GET' method:'GET'
}).then(res=>{ }).then(res=>{
if(res.code == 200){ if(res.code == 200){

View File

@ -561,11 +561,13 @@
.getcontrol_rtdata) + "?equipmentId=" + i.deviceId, .getcontrol_rtdata) + "?equipmentId=" + i.deviceId,
method: 'post', method: 'post',
}).then(res => { }).then(res => {
uni.hideLoading({
title: '完成'
});
if (res.code == 200 && res.data.length != 0) { if (res.code == 200 && res.data.length != 0) {
uni.hideLoading({ // uni.hideLoading({
title: '完成' // title: ''
}); // });
uni.stopPullDownRefresh(); uni.stopPullDownRefresh();
i.childList = res.data; i.childList = res.data;
i.childList_mubiao = res.data.filter(el => (this.getStatus(el.equipmentNumber, el.targetValue)) == '目标' || (this.getStatus(el.equipmentNumber, el.targetValue)) == ('目标' + el.equipmentNumber +'#')); i.childList_mubiao = res.data.filter(el => (this.getStatus(el.equipmentNumber, el.targetValue)) == '目标' || (this.getStatus(el.equipmentNumber, el.targetValue)) == ('目标' + el.equipmentNumber +'#'));