|
|
@@ -1,44 +1,42 @@
|
|
|
<template>
|
|
|
<view class="">
|
|
|
<view class="status_bar"></view>
|
|
|
- <view class="" style="position: relative;top: 44px;">
|
|
|
+ <view class="" style="position: relative;top: 40px;">
|
|
|
<view style="position: fixed;z-index: 100;">
|
|
|
- <uni-nav-bar @clickRight="clickRight" @clickLeft="clickLeft" left-icon="back" left-text="返回"
|
|
|
- right-icon="search" title="测报系统"></uni-nav-bar>
|
|
|
- <view class="inputs" :style="{'width':width+'rpx'}">
|
|
|
- <input type="text" value="" placeholder="请输入设备ID或设备名称" v-model="imports" @input="searchinp"
|
|
|
- class="inputbox" :clearable="false" />
|
|
|
- <u-icon name="search" size="40" class="icon" @click="search"></u-icon>
|
|
|
+ <uni-nav-bar @clickLeft="clickLeft" left-icon="back" left-text="返回"
|
|
|
+ ></uni-nav-bar>
|
|
|
+ <view class="bases_search">
|
|
|
+ <view class="bases_search_text" @click="clickRight">
|
|
|
+ <u-icon name="search" class="search" @click="search"></u-icon>
|
|
|
+ <input type="text" v-model="data.search" placeholder="设备ID搜索" @input="searchinput" disabled/>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view>
|
|
|
+ <image :src="'https://www.hnyfwlw.com:8006/bigdata_app'+'/image/cb/banner.jpg'" mode="widthFix"></image>
|
|
|
</view>
|
|
|
- <view style="width: 100%;">
|
|
|
- <image :src="'http://www.hnyfwlw.com:8006/bigdata_app'+'/image/cb/banner.jpg'" mode="widthFix">
|
|
|
- </image>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="tab-box">
|
|
|
- <view v-for="(item,index) in equipArr" :key="item.type" v-if="item.tf" @click="tabClick(index)"
|
|
|
- :class="['tab-item',active==index?'active':'']">
|
|
|
- <text>{{item.name}}</text>
|
|
|
- <text class="bottom-line"></text>
|
|
|
+ <view class="tab-box">
|
|
|
+ <!-- <view v-for="(item,index) in equipArr" :key="item.type" @click="tabClick(index,item)" :class="['tab-item',active==index?'active':'']">
|
|
|
+ <text>{{item.type_name}}</text>
|
|
|
+ <text class="bottom-line"></text>
|
|
|
+ </view> -->
|
|
|
+ <u-tabs :list="equipArr" :current="active" active-color="#14A478" @change="tabClick"></u-tabs>
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="loading" v-if="loadingtf">
|
|
|
<image src="../../../static/images/ajax-loader.gif" mode="" class="img"></image>
|
|
|
</view>
|
|
|
- <view class="" style="position: absolute;top: 180px;width: 100%;">
|
|
|
+ <view class="" style="position: absolute;top: 190px;width: 100%;">
|
|
|
<view class="content">
|
|
|
- <template v-for="(item,index) in equipArr[active].list">
|
|
|
+ <template v-for="(item,index) in equipArr[active].list" >
|
|
|
<equipItem @click.native="itemClick(item)" v-bind:item="item" :key="index">
|
|
|
<view class="date">
|
|
|
- <p>设备ID:{{item.imei || item.device_id}}</p>
|
|
|
+ <p>设备ID:{{item.imei||item.device_id}}</p>
|
|
|
<p>最新上报时间:{{item.uptime|timeFormat}}</p>
|
|
|
- <view class="" style="display: flex;justify-content: space-between;"
|
|
|
- v-if="(device_type == 3 || device_type==7) && showLastTime">
|
|
|
+ <view class="" style="display: flex;justify-content: space-between;" v-if="(device_type == 3 || device_type==7) && $QueryPermission(325)">
|
|
|
<p>设备到期情况:<span
|
|
|
:class="'prevents_item_bot_sapn'+item.device_expire">{{item.device_expiretext}}</span>
|
|
|
</p>
|
|
|
- <p style="color: #3C84FE;" v-if="item.device_expire!=0" @click.stop="examine(item)">
|
|
|
- 查看详情</p>
|
|
|
+ <p style="color: #3C84FE;" v-if="item.device_expire!=0" @click.stop="examine(item)">查看详情</p>
|
|
|
</view>
|
|
|
</view>
|
|
|
</equipItem>
|
|
|
@@ -46,8 +44,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <u-modal v-model="show" :title="title" :showConfirmButton="false"
|
|
|
- :title-style="{'text-align':'left','padding-left':'10px','font-weight':700}" :mask-close-able="true">
|
|
|
+ <u-modal v-model="show" :title="title" :showConfirmButton="false" :title-style="{'text-align':'left','padding-left':'10px','font-weight':700}" :mask-close-able="true">
|
|
|
<view class="slot-content">
|
|
|
<rich-text :nodes="content"></rich-text>
|
|
|
</view>
|
|
|
@@ -56,29 +53,28 @@
|
|
|
<view class="backtop" @click="top" v-if="isTop">
|
|
|
<image src="../../../static/images/1.png" mode="" class="img0"></image>
|
|
|
</view>
|
|
|
+
|
|
|
<view class="more">
|
|
|
- <view class="box" @click="online" v-show="filtrateTF">
|
|
|
+ <view class="box" @click="findSearch(1)" v-show="filtrateTF">
|
|
|
<p>在线</p>
|
|
|
</view>
|
|
|
- <view class="box" @click="offline" v-show="filtrateTF">
|
|
|
+ <view class="box" @click="findSearch(0)" v-show="filtrateTF">
|
|
|
<p>离线</p>
|
|
|
</view>
|
|
|
- <view class="box" @click="complete" v-show="filtrateTF">
|
|
|
+ <view class="box" @click="findSearch('')" v-show="filtrateTF">
|
|
|
<p>全部</p>
|
|
|
</view>
|
|
|
<view @click="filtrate">
|
|
|
- <image src="../../../static/images/b0bcdb0e3fe8690520f743aa8303bf2.png" mode="" class="img1">
|
|
|
- </image>
|
|
|
+ <image src="../../../static/images/b0bcdb0e3fe8690520f743aa8303bf2.png" mode="" class="img1"></image>
|
|
|
</view>
|
|
|
</view>
|
|
|
+
|
|
|
+
|
|
|
</view>
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
- import {
|
|
|
- Debounce
|
|
|
- } from "../../../util/anitthro.js"
|
|
|
import equipItem from "../../../components/equip-item/equip-item"
|
|
|
import uniNavBar from "@/components/uni-nav-bar/uni-nav-bar.vue"
|
|
|
export default {
|
|
|
@@ -86,119 +82,34 @@
|
|
|
return {
|
|
|
active: 0, //默认选中虫情测报
|
|
|
equipArr: [{
|
|
|
- name: '虫情测报',
|
|
|
- type: 3, //3虫情测报灯 7孢子仪 4智能性诱
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- tf: false,
|
|
|
- }, {
|
|
|
- name: '孢子仪',
|
|
|
- type: 7, //3虫情测报灯 7孢子仪 4智能性诱
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- tf: false,
|
|
|
- }, {
|
|
|
- name: '性诱测报',
|
|
|
- type: 4, //3虫情测报灯 7孢子仪 4智能性诱
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- device_model: 1,
|
|
|
- tf: false,
|
|
|
- },
|
|
|
- {
|
|
|
- name: '性诱2.0',
|
|
|
- type: 10, //3虫情测报灯 7孢子仪 4智能性诱 性诱2.0
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- tf: false
|
|
|
- },
|
|
|
- {
|
|
|
- name: '性诱3.0',
|
|
|
- type: 8, //3虫情测报灯 7孢子仪 4智能性诱 性诱2.0
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- tf: false
|
|
|
- }, {
|
|
|
- name: '吸虫塔',
|
|
|
- type: 12, //3虫情测报灯 7孢子仪 4智能性诱 性诱2.0
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- tf: false
|
|
|
- }, {
|
|
|
- name: '病虫害可视监测',
|
|
|
- type: 14, //3虫情测报灯 7孢子仪 4智能性诱 性诱2.0
|
|
|
- list: [],
|
|
|
- pageIndex: 1,
|
|
|
- tf: false
|
|
|
- }
|
|
|
- ],
|
|
|
- device_type: '3', //筛选的设备id
|
|
|
+ name: ''
|
|
|
+ }],
|
|
|
isTop: false,
|
|
|
- filtrateTF: false,
|
|
|
- device_status: "",
|
|
|
- width: 0, //顶部搜索栏宽度
|
|
|
- imports: "", //搜索id
|
|
|
- loadingtf: false, //loading
|
|
|
+ filtrateTF:false,
|
|
|
+ device_status:"",
|
|
|
+ loadingtf:false,//设备列表加载中
|
|
|
+ device_type:3,
|
|
|
show: false,
|
|
|
title: "",
|
|
|
content: "",
|
|
|
- showLastTime: false,
|
|
|
+ searchinput:'',
|
|
|
+ data:{search:''}
|
|
|
}
|
|
|
},
|
|
|
- onLoad() {
|
|
|
- uni.getStorage({
|
|
|
- key: "jurisdiction",
|
|
|
- success: (res) => {
|
|
|
- let list = res.data;
|
|
|
- this.showLastTime = this.testId(325, JSON.parse(res.data));
|
|
|
- console.log(this.showLastTime);
|
|
|
- let items = JSON.parse(res.data).filter((item) => {
|
|
|
- return item.pur_id == 36
|
|
|
- })
|
|
|
- var arr = items[0].children
|
|
|
- for (var i = 0; i < arr.length; i++) {
|
|
|
- switch (arr[i].pur_id) {
|
|
|
- case 37:
|
|
|
- this.equipArr[0].tf = true //"虫情测报灯"
|
|
|
- this.getEquipList(0)
|
|
|
- break
|
|
|
- case 38:
|
|
|
- this.equipArr[2].tf = true //"性诱测报"
|
|
|
- this.getEquipList(2)
|
|
|
- break
|
|
|
- case 39:
|
|
|
- this.equipArr[1].tf = true //"孢子仪"
|
|
|
- this.getEquipList(1)
|
|
|
- break
|
|
|
- case 161:
|
|
|
- this.equipArr[3].tf = true //"性诱2.0"
|
|
|
- this.getxyEquipList(3)
|
|
|
- break
|
|
|
- case 198:
|
|
|
- this.equipArr[4].tf = true //"性诱2.0"
|
|
|
- this.getthxyEquipList(4)
|
|
|
- break
|
|
|
- case 171:
|
|
|
- this.equipArr[5].tf = true //"性诱3.0"
|
|
|
- this.getxctEquipList(5)
|
|
|
- break
|
|
|
- case 167:
|
|
|
- this.equipArr[6].tf = true //"性诱3.0"
|
|
|
- this.getEquipList(6)
|
|
|
- break
|
|
|
- }
|
|
|
- }
|
|
|
- for (var i = 0; i < this.equipArr.length; i++) {
|
|
|
- if (this.equipArr[i].tf) {
|
|
|
- this.active = i
|
|
|
- this.device_type = this.equipArr[i].type
|
|
|
- console.log(i)
|
|
|
- break
|
|
|
- }
|
|
|
- }
|
|
|
+ computed:{
|
|
|
+ tabActiveStyle(){
|
|
|
+ return {
|
|
|
+ color: '#303133',
|
|
|
+ fontWeight: 'bold'
|
|
|
}
|
|
|
- })
|
|
|
-
|
|
|
+ }
|
|
|
+ },
|
|
|
+ onLoad() {
|
|
|
+ this.equipArr = [{
|
|
|
+ name: ''
|
|
|
+ }]
|
|
|
+ this.usertype()
|
|
|
+
|
|
|
},
|
|
|
onShow() {
|
|
|
|
|
|
@@ -212,7 +123,6 @@
|
|
|
onPullDownRefresh() {
|
|
|
this.equipArr[this.active].pageIndex = 1
|
|
|
this.equipArr[this.active].list = []
|
|
|
-
|
|
|
if (this.active == 4) {
|
|
|
this.getthxyEquipList(4)
|
|
|
} else if (this.active == 5) {
|
|
|
@@ -239,7 +149,7 @@
|
|
|
} else if (this.active == 3) {
|
|
|
this.getxyEquipList(3)
|
|
|
} else {
|
|
|
- this.getEquipList(act)
|
|
|
+ this.getEquipList(this.active)
|
|
|
}
|
|
|
},
|
|
|
onPageScroll(e) { //nvue暂不支持滚动监听,可用bindingx代替
|
|
|
@@ -257,40 +167,50 @@
|
|
|
return true;
|
|
|
},
|
|
|
methods: {
|
|
|
- testId(id, list) {
|
|
|
- for (var i = 0; i < list.length; i++) {
|
|
|
- if (list[i].children) {
|
|
|
- var data = list[i].children
|
|
|
- for (var j = 0; j < data.length; j++) {
|
|
|
- if (data[j].children) {
|
|
|
- var item = data[j].children
|
|
|
- for (var k = 0; k < item.length; k++) {
|
|
|
- if (item[k].pur_id == id) {
|
|
|
- return true
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- }
|
|
|
+ search(){
|
|
|
+
|
|
|
+ },
|
|
|
+ //获取用户测报设备列表
|
|
|
+ async usertype() {
|
|
|
+ const res = await this.$myRequest({
|
|
|
+ url: '/api/api_gateway?method=home.homes.user_device_type',
|
|
|
+ data:{
|
|
|
+ model:'测报'
|
|
|
}
|
|
|
- };
|
|
|
+ })
|
|
|
+ console.log('设备列表',res)
|
|
|
+ // this.equipArr = res
|
|
|
+ this.equipArr.shift()
|
|
|
+ res.forEach(item=>{
|
|
|
+ item.name=item.type_name
|
|
|
+ item.list = []
|
|
|
+ item.pageIndex = 1
|
|
|
+ this.equipArr.push(item)
|
|
|
+ })
|
|
|
+ if (res.length) {
|
|
|
+ this.device_type =this.equipArr[0].id
|
|
|
+ this.choosePOST()
|
|
|
+ }
|
|
|
},
|
|
|
async getEquipList(act) {
|
|
|
+
|
|
|
this.loadingtf = true
|
|
|
const res = await this.$myRequest({
|
|
|
url: '/api/api_gateway?method=forecast.worm_lamp.lamp_list',
|
|
|
data: {
|
|
|
- device_type_id: this.equipArr[act].type,
|
|
|
+ device_type_id: this.equipArr[act].id,
|
|
|
page: this.equipArr[act].pageIndex,
|
|
|
page_size: 10,
|
|
|
- device_status: this.device_status,
|
|
|
- device_id: this.imports,
|
|
|
- device_model: this.equipArr[act].device_model ? this.equipArr[act].device_model : 0
|
|
|
+ device_status:this.device_status,
|
|
|
+ device_model: this.equipArr[act].device_model ? this.equipArr[act].device_model:0
|
|
|
}
|
|
|
})
|
|
|
- this.loadingtf = false
|
|
|
+ this.loadingtf =false
|
|
|
console.log(res)
|
|
|
this.equipArr[act].list = [...this.equipArr[act].list, ...res.data]
|
|
|
+ this.equipArr[act].list.forEach(item => {
|
|
|
+ item.uptime = item.addtime;
|
|
|
+ })
|
|
|
for (var i = 0; i < this.equipArr[act].list.length; i++) {
|
|
|
if (this.equipArr[act].list[i].device_expire == 0) {
|
|
|
this.equipArr[act].list[i]['device_expiretext'] = "未到期"
|
|
|
@@ -300,82 +220,99 @@
|
|
|
this.equipArr[act].list[i]['device_expiretext'] = "即将到期"
|
|
|
}
|
|
|
}
|
|
|
- this.equipArr[act].list.forEach(item => {
|
|
|
- item.uptime = item.addtime;
|
|
|
- })
|
|
|
- console.log(this.equipArr[act].list)
|
|
|
+ console.log('处理后的结果',this.equipArr[act].list)
|
|
|
},
|
|
|
+ // 性诱2.0
|
|
|
async getxyEquipList(act) {
|
|
|
this.loadingtf = true
|
|
|
const res = await this.$myRequest({
|
|
|
url: '/api/api_gateway?method=sex_lure_nl.sex_lure.nl_device_list',
|
|
|
data: {
|
|
|
- device_type_id: this.equipArr[act].type,
|
|
|
+ device_type_id: this.equipArr[act].id,
|
|
|
page: this.equipArr[act].pageIndex,
|
|
|
page_size: 10,
|
|
|
- device_status: this.device_status,
|
|
|
- device_id: this.imports,
|
|
|
+ device_status:this.device_status
|
|
|
}
|
|
|
})
|
|
|
- this.loadingtf = false
|
|
|
+ this.loadingtf =false
|
|
|
console.log(res)
|
|
|
this.equipArr[act].list = [...this.equipArr[act].list, ...res.data]
|
|
|
- // this.equipArr[act].list.forEach(item => {
|
|
|
- // item.addtime = item.uptime;
|
|
|
- // })
|
|
|
console.log(this.equipArr[act].list)
|
|
|
},
|
|
|
+ // 性诱3.0
|
|
|
async getthxyEquipList(act) {
|
|
|
this.loadingtf = true
|
|
|
const res = await this.$myRequest({
|
|
|
url: '/api/api_gateway?method=forecast.worm_lamp.xy_three_list',
|
|
|
data: {
|
|
|
- device_type_id: this.equipArr[act].type,
|
|
|
+ device_type_id: this.equipArr[act].id,
|
|
|
page: this.equipArr[act].pageIndex,
|
|
|
page_size: 10,
|
|
|
device_status: this.device_status,
|
|
|
- device_id: this.imports,
|
|
|
}
|
|
|
})
|
|
|
this.loadingtf = false
|
|
|
console.log(res)
|
|
|
- this.equipArr[act].list = [...this.equipArr[act].list, ...res.data];
|
|
|
- // this.equipArr[act].list.forEach(item => {
|
|
|
- // item.addtime = item.uptime;
|
|
|
- // })
|
|
|
+ this.equipArr[act].list = [...this.equipArr[act].list, ...res.data]
|
|
|
console.log(this.equipArr[act].list)
|
|
|
},
|
|
|
+ // 吸虫塔
|
|
|
async getxctEquipList(act) {
|
|
|
this.loadingtf = true
|
|
|
const res = await this.$myRequest({
|
|
|
url: '/api/api_gateway?method=forecast.worm_lamp.xct_list',
|
|
|
data: {
|
|
|
- device_type_id: this.equipArr[act].type,
|
|
|
+ device_type_id: this.equipArr[act].id,
|
|
|
page: this.equipArr[act].pageIndex,
|
|
|
page_size: 10,
|
|
|
device_status: this.device_status,
|
|
|
- device_id: this.imports,
|
|
|
}
|
|
|
})
|
|
|
this.loadingtf = false
|
|
|
console.log(res)
|
|
|
- this.equipArr[act].list = [...this.equipArr[act].list, ...res.data];
|
|
|
- // this.equipArr[act].list.forEach(item => {
|
|
|
- // item.addtime = item.uptime;
|
|
|
- // })
|
|
|
+ this.equipArr[act].list = [...this.equipArr[act].list, ...res.data]
|
|
|
+ console.log(this.equipArr[act].list)
|
|
|
},
|
|
|
tabClick(index) {
|
|
|
- this.width = 0
|
|
|
- this.imports = ""
|
|
|
+
|
|
|
this.active = index;
|
|
|
- this.device_type = this.equipArr[index].type
|
|
|
+ this.device_type = this.equipArr[index].id
|
|
|
+ this.equipArr[this.active].list = []
|
|
|
+ this.equipArr[this.active].pageIndex=1
|
|
|
+ this.choosePOST()
|
|
|
+ },
|
|
|
+
|
|
|
+ choosePOST(){
|
|
|
+ let index = this.active
|
|
|
+ let typeId = this.device_type
|
|
|
+ if(typeId == 10){
|
|
|
+ // 性诱2.0
|
|
|
+ this.getxyEquipList(index)
|
|
|
+ }else if(typeId == 8){
|
|
|
+ // 性诱3.0
|
|
|
+ this.getthxyEquipList(index)
|
|
|
+ }else if(typeId == 12){
|
|
|
+ // 吸虫塔
|
|
|
+ this.getxctEquipList(index)
|
|
|
+ }
|
|
|
+ else{
|
|
|
+ // 测报接口
|
|
|
+ this.getEquipList(index)
|
|
|
+ }
|
|
|
},
|
|
|
clickRight() {
|
|
|
- this.width = 600
|
|
|
+ console.log('点击了搜索')
|
|
|
+ uni.navigateTo({
|
|
|
+ url: "./search?device_type_id=" + this.device_type+'&pur_id=' + this.equipArr[this.active].pur_id
|
|
|
+ })
|
|
|
},
|
|
|
- itemClick(item) {
|
|
|
- item.type = this.equipArr[this.active].type
|
|
|
+ itemClick(itemOld) {
|
|
|
+ let item = JSON.parse(JSON.stringify(itemOld))
|
|
|
+ item.type= this.equipArr[this.active].id
|
|
|
+ item.pur_id = this.equipArr[this.active].pur_id||0
|
|
|
let data = JSON.stringify(item)
|
|
|
+
|
|
|
+
|
|
|
if (item.type == 10) {
|
|
|
uni.navigateTo({
|
|
|
url: '/pages/cb/xy2.0/particulars?info=' + data
|
|
|
@@ -393,7 +330,11 @@
|
|
|
uni.navigateTo({
|
|
|
url: '/pages/cb/sy/detail?detail=' + data
|
|
|
});
|
|
|
- } else {
|
|
|
+ }else if (item.type == 32||item.type == 33||item.type == 34||item.type == 35) {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/cb/equip-detail/equip-detail-new?info=' + data
|
|
|
+ });
|
|
|
+ } else{
|
|
|
uni.navigateTo({
|
|
|
url: '/pages/cb/equip-detail/equip-detail?info=' + data
|
|
|
});
|
|
|
@@ -404,7 +345,7 @@
|
|
|
url: "../../index/index"
|
|
|
})
|
|
|
},
|
|
|
- filtrate() {
|
|
|
+ filtrate(){
|
|
|
this.filtrateTF = !this.filtrateTF
|
|
|
},
|
|
|
top() {
|
|
|
@@ -413,78 +354,19 @@
|
|
|
duration: 500
|
|
|
})
|
|
|
},
|
|
|
- online() {
|
|
|
- this.equipArr[this.active].pageIndex = 1
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.device_status = 1
|
|
|
- if (this.active == 4) {
|
|
|
- this.getthxyEquipList(4)
|
|
|
- } else if (this.active == 5) {
|
|
|
- this.getxctEquipList(5)
|
|
|
- } else if (this.active == 3) {
|
|
|
- this.getxyEquipList(3)
|
|
|
- } else {
|
|
|
- this.getEquipList(this.active)
|
|
|
- }
|
|
|
- this.filtrateTF = !this.filtrateTF
|
|
|
- },
|
|
|
- offline() {
|
|
|
- this.equipArr[this.active].pageIndex = 1
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.device_status = 0
|
|
|
- if (this.active == 4) {
|
|
|
- this.getthxyEquipList(4)
|
|
|
- } else if (this.active == 5) {
|
|
|
- this.getxctEquipList(5)
|
|
|
- } else if (this.active == 3) {
|
|
|
- this.getxyEquipList(3)
|
|
|
- } else {
|
|
|
- this.getEquipList(this.active)
|
|
|
- }
|
|
|
- this.filtrateTF = !this.filtrateTF
|
|
|
- },
|
|
|
- complete() {
|
|
|
- this.equipArr[this.active].pageIndex = 1
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.device_status = ""
|
|
|
- if (this.active == 4) {
|
|
|
- this.getthxyEquipList(4)
|
|
|
- } else if (this.active == 5) {
|
|
|
- this.getxctEquipList(5)
|
|
|
- } else if (this.active == 3) {
|
|
|
- this.getxyEquipList(3)
|
|
|
- } else {
|
|
|
- this.getEquipList(this.active)
|
|
|
- }
|
|
|
+ findSearch(device_status){
|
|
|
+
|
|
|
+ this.device_status = device_status
|
|
|
+ this.equipArr[this.active].pageIndex=1
|
|
|
+ this.equipArr[this.active].list =[]
|
|
|
+ this.choosePOST()
|
|
|
this.filtrateTF = !this.filtrateTF
|
|
|
},
|
|
|
- search() { //搜索按钮搜索
|
|
|
- this.searchinp()
|
|
|
- },
|
|
|
- searchinp() { //自动搜索
|
|
|
- Debounce(() => {
|
|
|
- this.equipArr[this.active].pageIndex = 1
|
|
|
- if (this.active == 4) {
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.getthxyEquipList(this.active)
|
|
|
- } else if (this.active == 5) {
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.getxctEquipList(this.active)
|
|
|
- } else if (this.active == 3) {
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.getxyEquipList(this.active)
|
|
|
- } else {
|
|
|
- this.equipArr[this.active].list = []
|
|
|
- this.getEquipList(this.active)
|
|
|
- }
|
|
|
- }, 1000)()
|
|
|
- },
|
|
|
examine(e) {
|
|
|
// console.log(this)
|
|
|
this.show = true
|
|
|
this.title = e.device_expiretext
|
|
|
- this.content =
|
|
|
- `<p style="padding-left:10px;margin:10px 0;font-size:14px;">到期时间 ${this.timezhuan(e.device_expire_time)}
|
|
|
+ this.content = `<p style="padding-left:10px;margin:10px 0;font-size:14px;">到期时间 ${this.timezhuan(e.device_expire_time)}
|
|
|
</p><p style="font-size:14px;text-align:right;color:#3C84FE;margin-bottom:10px;padding-right:10px">注:请前往PC端进行充值</p>`
|
|
|
},
|
|
|
timezhuan(time) {
|
|
|
@@ -515,100 +397,59 @@
|
|
|
.content {
|
|
|
padding: 0 20rpx 20rpx 20rpx;
|
|
|
box-sizing: border-box;
|
|
|
-
|
|
|
- .prevents_item_bot_sapn0 {
|
|
|
- color: #00B075;
|
|
|
- }
|
|
|
-
|
|
|
- .prevents_item_bot_sapn1 {
|
|
|
- color: #FF4747;
|
|
|
- }
|
|
|
-
|
|
|
- .prevents_item_bot_sapn2 {
|
|
|
- color: #FFAB00;
|
|
|
- }
|
|
|
}
|
|
|
}
|
|
|
|
|
|
image {
|
|
|
width: 100%;
|
|
|
}
|
|
|
-
|
|
|
- .inputs {
|
|
|
- height: 54rpx;
|
|
|
- background-color: #E4E4E4;
|
|
|
- border-radius: 27rpx;
|
|
|
- position: absolute;
|
|
|
- right: 20rpx;
|
|
|
- top: 20rpx;
|
|
|
- transition: width 0.5s;
|
|
|
- overflow: hidden;
|
|
|
- padding-top: 8rpx;
|
|
|
- box-sizing: border-box;
|
|
|
-
|
|
|
- .inputbox {
|
|
|
- width: 85%;
|
|
|
- text-indent: 1rem;
|
|
|
- font-size: 26rpx;
|
|
|
- }
|
|
|
-
|
|
|
- .icon {
|
|
|
- position: absolute;
|
|
|
- top: 8rpx;
|
|
|
- right: 26rpx;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- .loading {
|
|
|
+ .loading{
|
|
|
position: fixed;
|
|
|
top: 440px;
|
|
|
width: 95%;
|
|
|
left: 2.5%;
|
|
|
text-align: center;
|
|
|
-
|
|
|
- .img {
|
|
|
+ z-index: 100;
|
|
|
+ .img{
|
|
|
width: 300rpx;
|
|
|
height: 40rpx;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+ .bases_search {
|
|
|
+ width: 80%;
|
|
|
+ background-color: #FFFFFF;
|
|
|
+ position: absolute;
|
|
|
+ top: 10rpx;
|
|
|
+ left: 50%;
|
|
|
+ margin-left: -33%;
|
|
|
+ .bases_search_text {
|
|
|
+ width: 90%;
|
|
|
+ margin: 0 auto;
|
|
|
+ background-color: #F8F8F8;
|
|
|
+ height: 60rpx;
|
|
|
+ border-radius: 30rpx;
|
|
|
+ display: flex;
|
|
|
+ line-height: 60rpx;
|
|
|
+
|
|
|
+ .search {
|
|
|
+ padding: 0 20rpx;
|
|
|
+ font-size: 34rpx;
|
|
|
+ }
|
|
|
+
|
|
|
+ input {
|
|
|
+ width: 80%;
|
|
|
+ margin-top: 10rpx;
|
|
|
+ font-size: 28rpx;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
.tab-box {
|
|
|
- position: fixed;
|
|
|
- top: 170px;
|
|
|
font-size: 30rpx;
|
|
|
line-height: 80rpx;
|
|
|
background-color: #ffffff;
|
|
|
width: 100vw;
|
|
|
z-index: 2;
|
|
|
- overflow-y: hidden;
|
|
|
- overflow-x: auto;
|
|
|
- white-space: nowrap;
|
|
|
-
|
|
|
- .tab-item {
|
|
|
- cursor: pointer;
|
|
|
- position: relative;
|
|
|
- padding: 10rpx 20rpx;
|
|
|
- text-align: center;
|
|
|
- display: inline-block;
|
|
|
-
|
|
|
- span {
|
|
|
- display: inline-block;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- .tab-item.active {
|
|
|
- .bottom-line {
|
|
|
- bottom: 0;
|
|
|
- position: absolute;
|
|
|
- display: inline-block;
|
|
|
- width: 90rpx;
|
|
|
- height: 6rpx;
|
|
|
- left: 0;
|
|
|
- right: 0;
|
|
|
- margin: auto;
|
|
|
- background: $uni-color-success;
|
|
|
- }
|
|
|
- }
|
|
|
+ margin-top: -10rpx;
|
|
|
}
|
|
|
|
|
|
.top {
|
|
|
@@ -616,26 +457,22 @@
|
|
|
right: 10px;
|
|
|
bottom: 40px;
|
|
|
z-index: 100;
|
|
|
-
|
|
|
image {
|
|
|
width: 100rpx;
|
|
|
height: 100rpx;
|
|
|
}
|
|
|
-
|
|
|
- .backtop {
|
|
|
+ .backtop{
|
|
|
display: flex;
|
|
|
justify-content: flex-end;
|
|
|
margin-bottom: 10rpx;
|
|
|
}
|
|
|
-
|
|
|
- .more {
|
|
|
+ .more{
|
|
|
display: flex;
|
|
|
}
|
|
|
-
|
|
|
- .box {
|
|
|
+ .box{
|
|
|
width: 80rpx;
|
|
|
height: 80rpx;
|
|
|
- background-color: rgba(161, 161, 161, 0.45);
|
|
|
+ background-color: rgba(161,161,161,0.45);
|
|
|
border-radius: 50%;
|
|
|
text-align: center;
|
|
|
line-height: 80rpx;
|
|
|
@@ -644,4 +481,4 @@
|
|
|
color: #fff;
|
|
|
}
|
|
|
}
|
|
|
-</style>
|
|
|
+</style>
|