|
@@ -1,9 +1,11 @@
|
|
|
<template>
|
|
<template>
|
|
|
<view>
|
|
<view>
|
|
|
- <view class="title">基本信息</view>
|
|
|
|
|
|
|
+ <view class="title"></view>
|
|
|
<view class="info">
|
|
<view class="info">
|
|
|
<view class="device-id" @click="copy(equipInfo)">
|
|
<view class="device-id" @click="copy(equipInfo)">
|
|
|
- <image class="logo" :src="`http://www.hnyfwlw.com:8006/bigdata_pc/equipdistribute/${equipInfo.type}.png`" mode=""></image>
|
|
|
|
|
|
|
+ <image class="logo"
|
|
|
|
|
+ :src="`http://www.hnyfwlw.com:8006/bigdata_pc/equipdistribute/${equipInfo.type}.png`" mode="">
|
|
|
|
|
+ </image>
|
|
|
{{equipInfo.imei||equipInfo.device_id}}
|
|
{{equipInfo.imei||equipInfo.device_id}}
|
|
|
<image src="https://www.hnyfwlw.com:8006/bigdata_app/image/environment/fuzhi.png" mode="" class="tishi">
|
|
<image src="https://www.hnyfwlw.com:8006/bigdata_app/image/environment/fuzhi.png" mode="" class="tishi">
|
|
|
</image>
|
|
</image>
|
|
@@ -14,87 +16,121 @@
|
|
|
<view class="info-list">
|
|
<view class="info-list">
|
|
|
<span class="float-left">设备名称:</span> <span class="float-right">{{equipInfo.device_name}}</span>
|
|
<span class="float-left">设备名称:</span> <span class="float-right">{{equipInfo.device_name}}</span>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="info-list" v-if="equipInfo.type==32">
|
|
|
|
|
- <span class="float-left">诱虫量:</span> <span class="float-right">{{equipInfo.bug_count?equipInfo.bug_count.join('/'):'0/0/0'}}</span>
|
|
|
|
|
- </view>
|
|
|
|
|
<view class="info-list">
|
|
<view class="info-list">
|
|
|
- <span class="float-left">最新上报时间:</span> <span class="float-right">{{equipInfo.addtime||equipInfo.uptime | timeFormat}}</span>
|
|
|
|
|
|
|
+ <span class="float-left">上报时间:</span> <span
|
|
|
|
|
+ class="float-right">{{equipInfo.addtime||equipInfo.uptime | timeFormat}}</span>
|
|
|
</view>
|
|
</view>
|
|
|
<view class="info-list">
|
|
<view class="info-list">
|
|
|
- <span class="float-left">设备地址:</span> <span class="float-right">{{equipInfo.address?equipInfo.address:"--"}}</span>
|
|
|
|
|
- </view>
|
|
|
|
|
- <view class="info-list" v-if="equipInfo.type==34" @click="operate('jd')">
|
|
|
|
|
- <span class="float-left">卷带到期时间</span>
|
|
|
|
|
- <span> </span>
|
|
|
|
|
- <span class="float-right">
|
|
|
|
|
- <span v-if="equipInfo.jd_expire_time>0">
|
|
|
|
|
- {{ equipInfo.jd_expire_time | timeFormat}}
|
|
|
|
|
- </span>
|
|
|
|
|
- <span v-else> 暂未设置卷带 </span>
|
|
|
|
|
- <u-icon class="arrow" name="arrow-right" color="#666666" size="26"></u-icon>
|
|
|
|
|
- </span>
|
|
|
|
|
|
|
+ <span class="float-left">设备地址:</span> <span
|
|
|
|
|
+ class="float-right">{{equipInfo.address?equipInfo.address:"--"}}</span>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
|
|
+
|
|
|
<u-calendar v-model="calendar_show" mode="date" :max-date="date" @change="timeChange($event)">
|
|
<u-calendar v-model="calendar_show" mode="date" :max-date="date" @change="timeChange($event)">
|
|
|
</u-calendar>
|
|
</u-calendar>
|
|
|
<u-toast ref="toast" />
|
|
<u-toast ref="toast" />
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="title">基本操作</view>
|
|
|
|
|
- <view class="newState" >
|
|
|
|
|
- <view class="item" v-for="item in curEquip" @click="partClick(item.path)">
|
|
|
|
|
- <view class="item_info_img">
|
|
|
|
|
- <image :src="'https://www.hnyfwlw.com:8006/bigdata_app'+item.icon" mode="widthFix"></image>
|
|
|
|
|
|
|
+ <view class="title"></view>
|
|
|
|
|
+ <view class="newState">
|
|
|
|
|
+ <view class="top">
|
|
|
|
|
+ <view class="left">
|
|
|
|
|
+ <image class="img" src="/appIcon/zk.png"></image>
|
|
|
|
|
+ <p> <span class="num">100</span> mm</p>
|
|
|
|
|
+ <p>闸门下降中</p>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="info-text">
|
|
|
|
|
- {{item.tex}}
|
|
|
|
|
|
|
+ <view class="right btn">
|
|
|
|
|
+ <u-button text="设置开度" size="mini" @click="timeshow = true">设置开度</u-button>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
- </view>
|
|
|
|
|
- <view class="title">实时状态</view>
|
|
|
|
|
- <view class="newtishi" v-if="dataloadingtf">
|
|
|
|
|
- <p class="dataloading">加载中</p>
|
|
|
|
|
- </view>
|
|
|
|
|
- <view class="newtishi" v-else-if="newtishitf">
|
|
|
|
|
- 暂无数据
|
|
|
|
|
- </view>
|
|
|
|
|
- <view class="newState" v-else>
|
|
|
|
|
- <view class="item" v-for="item in curState">
|
|
|
|
|
- <view class="item_info_img">
|
|
|
|
|
- <image :src="'https://www.hnyfwlw.com:8006/bigdata_app'+item.icon" mode="widthFix"></image>
|
|
|
|
|
|
|
+ <view class="up-down">
|
|
|
|
|
+ <view class="bottom">
|
|
|
|
|
+ <view class="opt">
|
|
|
|
|
+ <image src="https://www.hnyfwlw.com:8006/bigdata_app/image/cb/2.png"></image>
|
|
|
|
|
+ <p class="num">到位</p>
|
|
|
|
|
+ <p>顶到位</p>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="btn">
|
|
|
|
|
+ <u-button text="上升" size="mini" @click="timeshow = true">上升</u-button>
|
|
|
|
|
+ </view>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="info-con">
|
|
|
|
|
- <view class="active">
|
|
|
|
|
- {{item.value | formatValue(item.txt,type)}}
|
|
|
|
|
|
|
+ <view class="bottom">
|
|
|
|
|
+ <view class="opt">
|
|
|
|
|
+ <image src="https://www.hnyfwlw.com:8006/bigdata_app/image/cb/2.png"></image>
|
|
|
|
|
+ <p class="num">未到位</p>
|
|
|
|
|
+ <p>底到位</p>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="val">
|
|
|
|
|
- {{item.txt}}
|
|
|
|
|
|
|
+ <view class="btn">
|
|
|
|
|
+ <u-button class="active" text="下降" size="mini" @click="timeshow = true">下降</u-button>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+ <view class="btn">
|
|
|
|
|
+ <button text="停止" @click="timeshow = true">停止</button>
|
|
|
|
|
+ </view>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+
|
|
|
|
|
+ <!-- 操作记录 -->
|
|
|
|
|
+ <view class="consoleList">
|
|
|
|
|
+ <view class="title">操作记录</view>
|
|
|
|
|
+ <!-- <view class="histimeBox">
|
|
|
|
|
+ <u-icon name="calendar" color="#C1C1C1" size="24"></u-icon>
|
|
|
|
|
+ <view class="time" @click="consoleshow = true">
|
|
|
|
|
+ {{consoleTime.startDate ? consoleTime.startDate : '开始'}}
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="">至</view>
|
|
|
|
|
+ <view class="time" @click="consoleshow = true">{{consoleTime.endDate ? consoleTime.endDate : '结束'}}
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <u-icon name="close-circle" color="#C1C1C1" size="28" @click="clearContime"
|
|
|
|
|
+ v-if="consoleTime.startDate"></u-icon>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <u-calendar v-model="consoleshow" mode="range" @change="changeConsoleDate"></u-calendar> -->
|
|
|
|
|
+ <view class="tableList tableTitle">
|
|
|
|
|
+
|
|
|
|
|
+ <view>时间</view>
|
|
|
|
|
+ <view>操作内容</view>
|
|
|
|
|
+ <view>操作结果</view>
|
|
|
|
|
+ <view>操作人</view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="tableList" v-for="(item, index) in tableData" :key="item.uptime + index">
|
|
|
|
|
+ <view>{{item.uptime}}</view>
|
|
|
|
|
+ <view :class="item.status ? 'success' : 'error'">{{item.operation_content}}</view>
|
|
|
|
|
+ <view>{{item.uptime}}</view>
|
|
|
|
|
+ <view>{{item.device_name}}</view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <u-loadmore style="margin-top: 16rpx;" :status="status" />
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="item" v-for="item in curState">
|
|
|
|
|
+ <view class="item_info_img">
|
|
|
|
|
+ <image :src="'https://www.hnyfwlw.com:8006/bigdata_app'+item.icon" mode="widthFix"></image>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="info-con">
|
|
|
|
|
+ <view class="active">
|
|
|
|
|
+ {{item.value | formatValue(item.txt,type)}}
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="val">
|
|
|
|
|
+
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
</view>
|
|
</view>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
- import equipState from "../../static/js/equipState_dict.json"
|
|
|
|
|
import {
|
|
import {
|
|
|
- QueryPermission,getPermissionById,getUserPermission
|
|
|
|
|
|
|
+ QueryPermission,
|
|
|
|
|
+ getPermissionById,
|
|
|
|
|
+ getUserPermission
|
|
|
} from "../../util/QueryPermission.js"
|
|
} from "../../util/QueryPermission.js"
|
|
|
export default {
|
|
export default {
|
|
|
data() {
|
|
data() {
|
|
|
return {
|
|
return {
|
|
|
- fieldstyle: {
|
|
|
|
|
- border: "2rpx solid #f6f6f6",
|
|
|
|
|
- "border-radius": "24px",
|
|
|
|
|
- "padding-left": "20rpx",
|
|
|
|
|
- "background-color": "#f6f6f6"
|
|
|
|
|
- },
|
|
|
|
|
city: "",
|
|
city: "",
|
|
|
type: null, //设备类型
|
|
type: null, //设备类型
|
|
|
device_status: null,
|
|
device_status: null,
|
|
|
equipInfo: {},
|
|
equipInfo: {},
|
|
|
cbd: [
|
|
cbd: [
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
],
|
|
],
|
|
|
newState: {}, //设备最新状态
|
|
newState: {}, //设备最新状态
|
|
|
setTimeShow: false,
|
|
setTimeShow: false,
|
|
@@ -105,122 +141,16 @@
|
|
|
newtishitf: false, //暂无数据提示
|
|
newtishitf: false, //暂无数据提示
|
|
|
dataloadingtf: true, //加载中提示
|
|
dataloadingtf: true, //加载中提示
|
|
|
date: "", //日历最大可选日期
|
|
date: "", //日历最大可选日期
|
|
|
- operateType:''
|
|
|
|
|
|
|
+ operateType: '',
|
|
|
|
|
+ status:'',//是否加载更多
|
|
|
|
|
+ page:1,
|
|
|
|
|
+ tableData:[{uptime:'06-11 14:02',operation_content:'指定开度(700mm)',device_name:'admin'}]
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
|
- curEquip(){
|
|
|
|
|
- this.cbd = [{
|
|
|
|
|
- icon: '/image/cb/4.png',
|
|
|
|
|
- tex: '设备控制',
|
|
|
|
|
- path: '/pages/cb/cbd/equip-set/equip-set-new',
|
|
|
|
|
- tf: true
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/cb/6.png',
|
|
|
|
|
- tex: 'sim卡详情',
|
|
|
|
|
- path: '/pages/prevention/sim',
|
|
|
|
|
- tf: true
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/environment/7.png',
|
|
|
|
|
- tex: '一键报修',
|
|
|
|
|
- path: '/pages/afterSale/addafter',
|
|
|
|
|
- tf: true
|
|
|
|
|
- }]
|
|
|
|
|
- let permission = getPermissionById(getUserPermission(),this.equipInfo.pur_id)
|
|
|
|
|
- permission.forEach(item=>{
|
|
|
|
|
-
|
|
|
|
|
- if(item.purview_name =='查看图片'){
|
|
|
|
|
- this.cbd.unshift({
|
|
|
|
|
- icon: '/image/cb/1.png',
|
|
|
|
|
- tex: item.purview_name,
|
|
|
|
|
- path: '/pages/cb/cbd/equip-set/photo',
|
|
|
|
|
- tf: true
|
|
|
|
|
- })
|
|
|
|
|
- }else if(item.purview_name =='数据详情'){
|
|
|
|
|
- this.cbd.unshift({
|
|
|
|
|
- icon: '/image/cb/2.png',
|
|
|
|
|
- tex: item.purview_name,
|
|
|
|
|
- path: '/pages/cb/cbd/equip-set/newhistoryfile',
|
|
|
|
|
- tf: true
|
|
|
|
|
- })
|
|
|
|
|
- }else if(item.purview_name =='分析'){
|
|
|
|
|
- this.cbd.unshift({
|
|
|
|
|
- icon: '/image/cb/3.png',
|
|
|
|
|
- tex: item.purview_name,
|
|
|
|
|
- path: '/pages/cb/cbd/equip-set/new-analyse',
|
|
|
|
|
- tf: true
|
|
|
|
|
- })
|
|
|
|
|
- }
|
|
|
|
|
- })
|
|
|
|
|
- return this.cbd
|
|
|
|
|
- },
|
|
|
|
|
- curState() {
|
|
|
|
|
- return [{
|
|
|
|
|
- icon: '/image/cb/icon02.png',
|
|
|
|
|
- txt: '在线状态',
|
|
|
|
|
- value: this.newState.status,
|
|
|
|
|
- },
|
|
|
|
|
- {
|
|
|
|
|
- icon: '/image/cb/icon05.png',
|
|
|
|
|
- txt: '开关状态',
|
|
|
|
|
- value: Number(this.newState.ds) == 1 ? '开机' : '关机'
|
|
|
|
|
- },
|
|
|
|
|
- {
|
|
|
|
|
- icon: '/image/cb/icon08.png',
|
|
|
|
|
- txt: '环境温度(℃)',
|
|
|
|
|
- value: this.newState.tem
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/cb/icon07.png',
|
|
|
|
|
- txt: '环境湿度(%)',
|
|
|
|
|
- value: this.newState.hum
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/prevention/icon16.png',
|
|
|
|
|
- txt: '信号强度',
|
|
|
|
|
- value: this.newState.signal
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/cb/icon12.png',
|
|
|
|
|
- txt: '设备版本',
|
|
|
|
|
- value: this.newState.dver_num
|
|
|
|
|
- },
|
|
|
|
|
- {
|
|
|
|
|
- icon: '/image/cb/icon17.png',
|
|
|
|
|
- txt: '雨控状态',
|
|
|
|
|
- value: this.newState.rps
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/cb/icon14.png',
|
|
|
|
|
- txt: '温控状态',
|
|
|
|
|
- value: this.newState.tps
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/cb/icon06.png',
|
|
|
|
|
- txt: '光控状态',
|
|
|
|
|
- value: this.newState.lps
|
|
|
|
|
- }, {
|
|
|
|
|
- icon: '/image/cb/icon18.png',
|
|
|
|
|
- txt: '控制模式',
|
|
|
|
|
- value: this.newState.control
|
|
|
|
|
- }
|
|
|
|
|
- ]
|
|
|
|
|
- },
|
|
|
|
|
- operateOptions(){
|
|
|
|
|
- return{
|
|
|
|
|
- yx:{
|
|
|
|
|
- title:'诱芯',
|
|
|
|
|
- url:'/api/api_gateway?method=new_gateway.device_info.youxin',
|
|
|
|
|
- field:'xy_expire_time'
|
|
|
|
|
- },
|
|
|
|
|
- sb:{
|
|
|
|
|
- title:'色板',
|
|
|
|
|
- url:'/api/api_gateway?method=new_gateway.device_info.sban',
|
|
|
|
|
- field:'sban_expire_time'
|
|
|
|
|
- },
|
|
|
|
|
- jd:{
|
|
|
|
|
- title:'卷带',
|
|
|
|
|
- url:'/api/api_gateway?method=new_gateway.device_info.syone_jd',
|
|
|
|
|
- field:'jd_expire_time'
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
},
|
|
},
|
|
|
filters: {
|
|
filters: {
|
|
|
equipType(type) {
|
|
equipType(type) {
|
|
@@ -253,35 +183,80 @@
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
|
|
+ onReachBottom() {
|
|
|
|
|
+ if (this.status == 'loadmore') {
|
|
|
|
|
+ this.page++;
|
|
|
|
|
+ // this.getEquipcontroldata()
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
onLoad(option) {
|
|
onLoad(option) {
|
|
|
|
|
+
|
|
|
this.equipInfo = JSON.parse(option.info)
|
|
this.equipInfo = JSON.parse(option.info)
|
|
|
- this.getDeviceStatus()
|
|
|
|
|
- this.type = Number(this.equipInfo.type) || Number(this.equipInfo.equip_type) || Number(this.equipInfo
|
|
|
|
|
- .device_type_id)
|
|
|
|
|
- this.equipInfo.type = this.type
|
|
|
|
|
- this.device_status = this.equipInfo.is_online
|
|
|
|
|
-
|
|
|
|
|
- this.getState()
|
|
|
|
|
-
|
|
|
|
|
- // this.selectaddress(Number(this.equipInfo.lat), Number(this.equipInfo.lng))
|
|
|
|
|
- var times = new Date()
|
|
|
|
|
- this.date = times.getFullYear() + 1 + "-" + Number(times.getMonth() + 1) + "-" + times.getDate()
|
|
|
|
|
|
|
+ console.log(this.equipInfo)
|
|
|
|
|
+ // this.getDeviceStatus()
|
|
|
|
|
+ // this.type = Number(this.equipInfo.type) || Number(this.equipInfo.equip_type) || Number(this.equipInfo
|
|
|
|
|
+ // .device_type_id)
|
|
|
|
|
+ // this.equipInfo.type = this.type
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ // this.getState()
|
|
|
|
|
+
|
|
|
|
|
+ // // this.selectaddress(Number(this.equipInfo.lat), Number(this.equipInfo.lng))
|
|
|
|
|
+ // var times = new Date()
|
|
|
|
|
+ // this.date = times.getFullYear() + 1 + "-" + Number(times.getMonth() + 1) + "-" + times.getDate()
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
|
|
+ //操作记录
|
|
|
|
|
+ async getEquipcontroldata() {
|
|
|
|
|
+ uni.showLoading({
|
|
|
|
|
+ title: '加载中'
|
|
|
|
|
+ });
|
|
|
|
|
+ const {
|
|
|
|
|
+ consoleTime
|
|
|
|
|
+ } = this;
|
|
|
|
|
+ let begin = consoleTime.startDate ? new Date(consoleTime.startDate).getTime() / 1000 : '';
|
|
|
|
|
+ let end = consoleTime.endDate ? new Date(consoleTime.endDate).getTime() / 1000 : '';
|
|
|
|
|
+ //操作记录
|
|
|
|
|
+ let res = await this.$myRequest({
|
|
|
|
|
+ method: "POST",
|
|
|
|
|
+ url: "/api/api_gateway?method=xphsp.views.control_log",
|
|
|
|
|
+ data: {
|
|
|
|
|
+ device_id: this.device_id,
|
|
|
|
|
+ page_num: this.page,
|
|
|
|
|
+ page_size: 15,
|
|
|
|
|
+ start: begin,
|
|
|
|
|
+ end: end
|
|
|
|
|
+ },
|
|
|
|
|
+ })
|
|
|
|
|
+ uni.hideLoading();
|
|
|
|
|
+ // this.tableData = [];
|
|
|
|
|
+ const record = res.result;
|
|
|
|
|
+ this.tableData = [...this.tableData, ...record];
|
|
|
|
|
+ this.total = res.count;
|
|
|
|
|
+ if (this.page * 15 > this.total) {
|
|
|
|
|
+ this.status = 'nomore'
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.status = 'loadmore'
|
|
|
|
|
+ }
|
|
|
|
|
+ // console.log(this.tableData);
|
|
|
|
|
+ },
|
|
|
async getDeviceStatus() {
|
|
async getDeviceStatus() {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
const res = await this.$myRequest({
|
|
const res = await this.$myRequest({
|
|
|
url: '/api/api_gateway?method=new_gateway.device_info.devices_list',
|
|
url: '/api/api_gateway?method=new_gateway.device_info.devices_list',
|
|
|
data: {
|
|
data: {
|
|
|
device_type_id: this.equipInfo.type,
|
|
device_type_id: this.equipInfo.type,
|
|
|
- id: this.equipInfo.imei|| this.equipInfo.device_id,
|
|
|
|
|
- page:1,
|
|
|
|
|
- size:999
|
|
|
|
|
|
|
+ id: this.equipInfo.imei || this.equipInfo.device_id,
|
|
|
|
|
+ page: 1,
|
|
|
|
|
+ size: 999
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
let newRes = res.device[0]
|
|
let newRes = res.device[0]
|
|
|
- this.equipInfo ={...this.equipInfo,...newRes}
|
|
|
|
|
- console.log('响应',this.equipInfo)
|
|
|
|
|
|
|
+ this.equipInfo = {
|
|
|
|
|
+ ...this.equipInfo,
|
|
|
|
|
+ ...newRes
|
|
|
|
|
+ }
|
|
|
|
|
+ console.log('响应', this.equipInfo)
|
|
|
},
|
|
},
|
|
|
async getState() {
|
|
async getState() {
|
|
|
this.dataloadingtf = true
|
|
this.dataloadingtf = true
|
|
@@ -294,9 +269,9 @@
|
|
|
})
|
|
})
|
|
|
this.newState = res
|
|
this.newState = res
|
|
|
this.dataloadingtf = false
|
|
this.dataloadingtf = false
|
|
|
- console.log('res',res)
|
|
|
|
|
|
|
+ console.log('res', res)
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
partClick(path) {
|
|
partClick(path) {
|
|
|
console.log(path)
|
|
console.log(path)
|
|
|
var device_id = this.equipInfo.device_id || this.equipInfo.imei
|
|
var device_id = this.equipInfo.device_id || this.equipInfo.imei
|
|
@@ -305,15 +280,15 @@
|
|
|
.type
|
|
.type
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
- operate(type){
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ operate(type) {
|
|
|
this.calendar_show = true
|
|
this.calendar_show = true
|
|
|
this.operateType = type
|
|
this.operateType = type
|
|
|
},
|
|
},
|
|
|
timeChange(e, filed) {
|
|
timeChange(e, filed) {
|
|
|
// // 根据type_id,执行相应的操作
|
|
// // 根据type_id,执行相应的操作
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
// let typeId = this.equipInfo.type
|
|
// let typeId = this.equipInfo.type
|
|
|
// let postData = {}
|
|
// let postData = {}
|
|
|
// if(typeId===32){
|
|
// if(typeId===32){
|
|
@@ -327,32 +302,36 @@
|
|
|
// }
|
|
// }
|
|
|
this.yxSubmit(e.result)
|
|
this.yxSubmit(e.result)
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
async yxSubmit(time) {
|
|
async yxSubmit(time) {
|
|
|
- let {title,url,field} = this.operateOptions[this.operateType]
|
|
|
|
|
|
|
+ let {
|
|
|
|
|
+ title,
|
|
|
|
|
+ url,
|
|
|
|
|
+ field
|
|
|
|
|
+ } = this.operateOptions[this.operateType]
|
|
|
if (!time) {
|
|
if (!time) {
|
|
|
this.$refs.toast.show({
|
|
this.$refs.toast.show({
|
|
|
- title: '请填写'+title+'到期时间!',
|
|
|
|
|
|
|
+ title: '请填写' + title + '到期时间!',
|
|
|
type: 'warning',
|
|
type: 'warning',
|
|
|
})
|
|
})
|
|
|
return false
|
|
return false
|
|
|
}
|
|
}
|
|
|
let postData = {
|
|
let postData = {
|
|
|
device_type_id: this.equipInfo.type,
|
|
device_type_id: this.equipInfo.type,
|
|
|
- id: this.equipInfo.device_id
|
|
|
|
|
|
|
+ id: this.equipInfo.device_id
|
|
|
}
|
|
}
|
|
|
- postData[field] = +new Date(time) / 1000
|
|
|
|
|
|
|
+ postData[field] = +new Date(time) / 1000
|
|
|
const res = await this.$myRequest({
|
|
const res = await this.$myRequest({
|
|
|
url: url,
|
|
url: url,
|
|
|
data: postData
|
|
data: postData
|
|
|
})
|
|
})
|
|
|
if (res) {
|
|
if (res) {
|
|
|
this.$refs.toast.show({
|
|
this.$refs.toast.show({
|
|
|
- title: title+'时间设置成功!',
|
|
|
|
|
|
|
+ title: title + '时间设置成功!',
|
|
|
type: 'success',
|
|
type: 'success',
|
|
|
})
|
|
})
|
|
|
this.getDeviceStatus()
|
|
this.getDeviceStatus()
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
// 色板
|
|
// 色板
|
|
@@ -369,7 +348,7 @@
|
|
|
data: {
|
|
data: {
|
|
|
device_type_id: this.equipInfo.type,
|
|
device_type_id: this.equipInfo.type,
|
|
|
id: this.equipInfo.device_id,
|
|
id: this.equipInfo.device_id,
|
|
|
- sban_expire_time: +new Date(time) / 1000
|
|
|
|
|
|
|
+ sban_expire_time: +new Date(time) / 1000
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
if (res) {
|
|
if (res) {
|
|
@@ -378,7 +357,7 @@
|
|
|
type: 'success',
|
|
type: 'success',
|
|
|
})
|
|
})
|
|
|
this.getDeviceStatus()
|
|
this.getDeviceStatus()
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
async jdSubmit(time) {
|
|
async jdSubmit(time) {
|
|
@@ -394,7 +373,7 @@
|
|
|
data: {
|
|
data: {
|
|
|
device_type_id: this.equipInfo.type,
|
|
device_type_id: this.equipInfo.type,
|
|
|
id: this.equipInfo.device_id,
|
|
id: this.equipInfo.device_id,
|
|
|
- jd_expire_time: +new Date(time) / 1000
|
|
|
|
|
|
|
+ jd_expire_time: +new Date(time) / 1000
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
if (res) {
|
|
if (res) {
|
|
@@ -403,7 +382,7 @@
|
|
|
type: 'success',
|
|
type: 'success',
|
|
|
})
|
|
})
|
|
|
this.getDeviceStatus()
|
|
this.getDeviceStatus()
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
selectaddress(lat, lng) { //获取分布位置
|
|
selectaddress(lat, lng) { //获取分布位置
|
|
@@ -433,26 +412,30 @@
|
|
|
|
|
|
|
|
<style lang='scss'>
|
|
<style lang='scss'>
|
|
|
page {
|
|
page {
|
|
|
- padding: 0rpx 48rpx;
|
|
|
|
|
|
|
+ padding: 0rpx 32rpx;
|
|
|
box-sizing: border-box;
|
|
box-sizing: border-box;
|
|
|
background: #F7F7F7;
|
|
background: #F7F7F7;
|
|
|
- .title{
|
|
|
|
|
|
|
+
|
|
|
|
|
+ .title {
|
|
|
color: #999999;
|
|
color: #999999;
|
|
|
margin: 32rpx 0;
|
|
margin: 32rpx 0;
|
|
|
}
|
|
}
|
|
|
- .logo{
|
|
|
|
|
|
|
+
|
|
|
|
|
+ .logo {
|
|
|
width: 36rpx;
|
|
width: 36rpx;
|
|
|
height: 36rpx;
|
|
height: 36rpx;
|
|
|
margin-right: 12rpx;
|
|
margin-right: 12rpx;
|
|
|
position: relative;
|
|
position: relative;
|
|
|
top: 8rpx;
|
|
top: 8rpx;
|
|
|
}
|
|
}
|
|
|
- .device-id{
|
|
|
|
|
|
|
+
|
|
|
|
|
+ .device-id {
|
|
|
height: 60rpx;
|
|
height: 60rpx;
|
|
|
line-height: 60rpx;
|
|
line-height: 60rpx;
|
|
|
margin-bottom: 18rpx;
|
|
margin-bottom: 18rpx;
|
|
|
color: #5C5C5C;
|
|
color: #5C5C5C;
|
|
|
- .float-right{
|
|
|
|
|
|
|
+
|
|
|
|
|
+ .float-right {
|
|
|
float: right;
|
|
float: right;
|
|
|
width: 88px;
|
|
width: 88px;
|
|
|
height: 30px;
|
|
height: 30px;
|
|
@@ -463,17 +446,18 @@
|
|
|
border-top-right-radius: 24rpx;
|
|
border-top-right-radius: 24rpx;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
.on {
|
|
.on {
|
|
|
background-image: url('/static/images/cb/online.png');
|
|
background-image: url('/static/images/cb/online.png');
|
|
|
color: #fff;
|
|
color: #fff;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
.off {
|
|
.off {
|
|
|
background-image: url('/static/images/cb/outline.png');
|
|
background-image: url('/static/images/cb/outline.png');
|
|
|
color: #999999;
|
|
color: #999999;
|
|
|
}
|
|
}
|
|
|
- .info {
|
|
|
|
|
|
|
+
|
|
|
|
|
+ .info {
|
|
|
position: relative;
|
|
position: relative;
|
|
|
padding: 8rpx 32rpx 32rpx 32rpx;
|
|
padding: 8rpx 32rpx 32rpx 32rpx;
|
|
|
|
|
|
|
@@ -510,10 +494,6 @@
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
.tit {
|
|
.tit {
|
|
|
font-weight: 800;
|
|
font-weight: 800;
|
|
|
height: 50rpx;
|
|
height: 50rpx;
|
|
@@ -531,97 +511,103 @@
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- .newtishi {
|
|
|
|
|
- width: 90%;
|
|
|
|
|
- margin: 0 auto;
|
|
|
|
|
- text-align: center;
|
|
|
|
|
- padding-top: 40rpx;
|
|
|
|
|
- font-size: 32rpx;
|
|
|
|
|
|
|
|
|
|
- .dataloading:after {
|
|
|
|
|
- overflow: hidden;
|
|
|
|
|
- display: inline-block;
|
|
|
|
|
- vertical-align: bottom;
|
|
|
|
|
- animation: ellipsis 2s infinite;
|
|
|
|
|
- content: "\2026";
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ .newState {
|
|
|
|
|
+ padding: 32rpx;
|
|
|
|
|
+ border-radius: 16rpx;
|
|
|
|
|
+ background: #FFF;
|
|
|
|
|
|
|
|
- @keyframes ellipsis {
|
|
|
|
|
- from {
|
|
|
|
|
- width: 2px;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ .top {
|
|
|
|
|
+ height: 112rpx;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ justify-content: space-between;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
|
|
|
- to {
|
|
|
|
|
- width: 15px;
|
|
|
|
|
|
|
+ .left {
|
|
|
|
|
+ width: 80%;
|
|
|
}
|
|
}
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
|
|
|
- .newState {
|
|
|
|
|
- display: flex;
|
|
|
|
|
- flex-wrap: wrap;
|
|
|
|
|
- text-align: center;
|
|
|
|
|
- margin: 0 -10rpx;
|
|
|
|
|
|
|
+ .right {
|
|
|
|
|
+ width: 160rpx;
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
- .item {
|
|
|
|
|
- display: flex;
|
|
|
|
|
- flex-wrap: nowrap;
|
|
|
|
|
- margin: 10rpx;
|
|
|
|
|
- width: 316rpx;
|
|
|
|
|
- justify-content: flex-start;
|
|
|
|
|
- padding: 20rpx 10rpx;
|
|
|
|
|
- box-sizing: border-box;
|
|
|
|
|
- border-radius: 4px;
|
|
|
|
|
-
|
|
|
|
|
- background-color: #fff;
|
|
|
|
|
- font-size: 24rpx;
|
|
|
|
|
- .info-text{
|
|
|
|
|
- line-height: 76rpx;
|
|
|
|
|
- padding-left: 30rpx;
|
|
|
|
|
- font-size: 14px;
|
|
|
|
|
- color: #666666;
|
|
|
|
|
|
|
+ .img {
|
|
|
|
|
+ float: left;
|
|
|
|
|
+ width: 112rpx;
|
|
|
|
|
+ height: 112rpx;
|
|
|
}
|
|
}
|
|
|
- .info-con {
|
|
|
|
|
- padding-left: 30rpx;
|
|
|
|
|
- text-align: left;
|
|
|
|
|
- line-height: 40rpx;
|
|
|
|
|
- color: #666666;
|
|
|
|
|
- .active{
|
|
|
|
|
- font-size: 36rpx;
|
|
|
|
|
- }
|
|
|
|
|
- .val{
|
|
|
|
|
- font-size: 24rpx;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+
|
|
|
|
|
+ .num {
|
|
|
|
|
+ font-size: 40rpx;
|
|
|
|
|
+
|
|
|
|
|
+ font-weight: 700;
|
|
|
|
|
+ color: #042118;
|
|
|
}
|
|
}
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
- .item_info_img {
|
|
|
|
|
- width: 30%;
|
|
|
|
|
- text-align: center;
|
|
|
|
|
|
|
+ .up-down {
|
|
|
|
|
+ height: 222rpx;
|
|
|
|
|
+ margin: 32rpx 0;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ gap: 18rpx;
|
|
|
|
|
+ justify-content: space-between;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ .bottom {
|
|
|
|
|
+ box-sizing: border-box;
|
|
|
|
|
+ height: 100%;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ padding: 32rpx 0;
|
|
|
|
|
+ flex-direction: column;
|
|
|
|
|
+ justify-content: center;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ gap: 30rpx;
|
|
|
|
|
+ flex: 1 0 0;
|
|
|
|
|
+ border-radius: 16rpx;
|
|
|
|
|
+ background: linear-gradient(180deg, #14a4781a 0%, #14a47800 100%), #FFF;
|
|
|
|
|
|
|
|
|
|
+ .opt {
|
|
|
|
|
+ width: 160rpx;
|
|
|
|
|
+ height: 70rpx;
|
|
|
|
|
+ font-size: 24rpx;
|
|
|
|
|
+ color: #687A74;
|
|
|
image {
|
|
image {
|
|
|
width: 64rpx;
|
|
width: 64rpx;
|
|
|
height: 64rpx;
|
|
height: 64rpx;
|
|
|
- margin-top: 10rpx;
|
|
|
|
|
|
|
+ float: left;
|
|
|
|
|
+ margin-right: 16rpx;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ .num {
|
|
|
|
|
+ color: #042118;
|
|
|
|
|
+ font-weight: 700;
|
|
|
|
|
+ font-size: 28rpx;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
}
|
|
}
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- .btn-box {
|
|
|
|
|
- text-align: center;
|
|
|
|
|
- padding: 30rpx;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- .field {
|
|
|
|
|
- /deep/.uni-input-input {
|
|
|
|
|
- border: 2rpx solid #FF0000;
|
|
|
|
|
- border-radius: 24rpx;
|
|
|
|
|
- width: 140px;
|
|
|
|
|
- padding-left: 10rpx;
|
|
|
|
|
- box-sizing: border-box;
|
|
|
|
|
|
|
+ .btn{
|
|
|
|
|
+ button{
|
|
|
|
|
+ font-size: 28rpx;
|
|
|
|
|
+ width: 100%;
|
|
|
|
|
+ background: #EEF0F8;
|
|
|
|
|
+ height: 63rpx;
|
|
|
|
|
+ line-height: 63rpx;
|
|
|
|
|
+ border: none;
|
|
|
|
|
+ outline: none;
|
|
|
|
|
+ border-radius: 16rpx;
|
|
|
|
|
+ &:after{
|
|
|
|
|
+ border: none;
|
|
|
|
|
+ }
|
|
|
|
|
+ &.active{
|
|
|
|
|
+ color: #fff;
|
|
|
|
|
+ background: #14A478;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/deep/.u-calendar__action {
|
|
/deep/.u-calendar__action {
|
|
@@ -636,4 +622,59 @@
|
|
|
.red {
|
|
.red {
|
|
|
color: rgb(235, 103, 101);
|
|
color: rgb(235, 103, 101);
|
|
|
}
|
|
}
|
|
|
|
|
+ .consoleList {
|
|
|
|
|
+ padding: 32rpx;
|
|
|
|
|
+ background: #fff;
|
|
|
|
|
+ border-radius: 16rpx;
|
|
|
|
|
+ margin-top: 32rpx;
|
|
|
|
|
+
|
|
|
|
|
+ .title{
|
|
|
|
|
+ margin: 0;
|
|
|
|
|
+ color: #042118;
|
|
|
|
|
+ font-weight: 600;
|
|
|
|
|
+ }
|
|
|
|
|
+ .histimeBox {
|
|
|
|
|
+ margin: 32rpx 0;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ .tableList {
|
|
|
|
|
+ font-size: 28rpx;
|
|
|
|
|
+ height: 93rpx;
|
|
|
|
|
+ color: #042118;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ justify-content: space-between;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ border-bottom: 2rpx solid var(--neutral-color-border-base, #DCE6E3);
|
|
|
|
|
+
|
|
|
|
|
+ view {
|
|
|
|
|
+ text-align: center;
|
|
|
|
|
+ }
|
|
|
|
|
+ .success{
|
|
|
|
|
+ color: #14A478;
|
|
|
|
|
+ }
|
|
|
|
|
+ .error{
|
|
|
|
|
+ color: #FF5951;
|
|
|
|
|
+ }
|
|
|
|
|
+ view:nth-child(1) {
|
|
|
|
|
+ width: 160rpx;
|
|
|
|
|
+ text-align: left;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ view:nth-child(2) {
|
|
|
|
|
+ width: 170rpx;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ view:nth-child(3) {
|
|
|
|
|
+ width: 120rpx;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ .tableTitle {
|
|
|
|
|
+ /* background: #E8F3F0; */
|
|
|
|
|
+ color: #042118;
|
|
|
|
|
+ font-weight: 500;
|
|
|
|
|
+ height: 78rpx;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
</style>
|
|
</style>
|