|
|
@@ -11,24 +11,41 @@
|
|
|
<div class="panel-body">
|
|
|
<div class=" panel_control">
|
|
|
<div class="pline">
|
|
|
- <em>设备ID:</em>
|
|
|
+ <em>MAC地址:</em>
|
|
|
<el-input v-model="panel.tagname" placeholder=""></el-input>
|
|
|
</div>
|
|
|
<div class="pline">
|
|
|
- <em>MAC地址:</em>
|
|
|
- <el-input v-model="panel.tagname" placeholder=""></el-input>
|
|
|
+ <em>设备类型 :</em>
|
|
|
+ <el-select v-model="panel.deviceType">
|
|
|
+ <el-option
|
|
|
+ v-for="item in panel.deviceTypeOptions"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</div>
|
|
|
<div class="pline">
|
|
|
- <em>所属区域:</em>
|
|
|
- <el-select v-model="panel.regionid">
|
|
|
+ <em>安全等级 :</em>
|
|
|
+ <el-select v-model="panel.level">
|
|
|
<el-option
|
|
|
- v-for="item in panel.regionidOptions"
|
|
|
- :key="item.Id"
|
|
|
- :label="item.Name"
|
|
|
- :value="item.Id">
|
|
|
+ v-for="item in panel.levelOptions"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</div>
|
|
|
+ <div class="pline">
|
|
|
+ <em>时间范围</em>
|
|
|
+ <el-date-picker
|
|
|
+ v-model="panel.time1"
|
|
|
+ type="daterange"
|
|
|
+ range-separator="至"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期">
|
|
|
+ </el-date-picker>
|
|
|
+ </div>
|
|
|
<div class="pline">
|
|
|
<el-button size="medium" type="primary" @click="query">查询</el-button>
|
|
|
</div>
|
|
|
@@ -65,38 +82,115 @@
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
prop="Mac"
|
|
|
- label="区域名称"
|
|
|
+ label="Mac"
|
|
|
+ >
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="ApMac"
|
|
|
+ label="ApMac"
|
|
|
+ >
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="Oem"
|
|
|
+ label="品牌"
|
|
|
+ width="140"
|
|
|
+ align="center"
|
|
|
+ sortable
|
|
|
+ >
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-tooltip class="item" effect="dark" :content="scope.row.Oem" placement="top-start">
|
|
|
+ <span v-if="scope.row.Oem">
|
|
|
+ {{ scope.row.Oem.length > 9 ? scope.row.Oem.substr(0,9)+'...' : scope.row.Oem }}
|
|
|
+ </span>
|
|
|
+ <span v-else>
|
|
|
+ 未知
|
|
|
+ </span>
|
|
|
+
|
|
|
+ </el-tooltip>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="DetectorTag"
|
|
|
+ label="探测器"
|
|
|
+ sortable
|
|
|
+ >
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="DeviceType"
|
|
|
+ label="设备类型"
|
|
|
+ :formatter="filterType"
|
|
|
+ sortable
|
|
|
>
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
- prop="Xmax"
|
|
|
- label="长/m"
|
|
|
+ prop="Down"
|
|
|
+ label="下载"
|
|
|
+ sortable
|
|
|
>
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
- prop="Ymax"
|
|
|
- label="宽/m"
|
|
|
+ prop="Up"
|
|
|
+ label="上传"
|
|
|
+ sortable
|
|
|
>
|
|
|
</el-table-column>
|
|
|
+
|
|
|
<el-table-column
|
|
|
- prop="Memo"
|
|
|
- label="备注"
|
|
|
+ prop="Ssid"
|
|
|
+ label="Ssid"
|
|
|
+ sortable
|
|
|
>
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-tooltip class="item" effect="dark" :content="scope.row.Ssid" placement="top-start">
|
|
|
+ <span v-if="scope.row.Ssid">
|
|
|
+ {{ scope.row.Ssid.length > 9 ? scope.row.Ssid.substr(0,9)+'...' : scope.row.Ssid }}
|
|
|
+ </span>
|
|
|
+ <span v-else>
|
|
|
+ 未知
|
|
|
+ </span>
|
|
|
+ </el-tooltip>
|
|
|
+ </template>
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
- prop="address"
|
|
|
- label="操作记录"
|
|
|
- width="220"
|
|
|
+ prop="Rssi"
|
|
|
+ label="Rssi"
|
|
|
+ sortable
|
|
|
+ >
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="RltLevel"
|
|
|
+ label="安全等级"
|
|
|
+ sortable
|
|
|
>
|
|
|
<template slot-scope="scope">
|
|
|
+ <span v-if="scope.row.RltLevel == 1">安全</span>
|
|
|
+ <span v-if="scope.row.RltLevel == 2" class="yellow">可疑</span>
|
|
|
+ <span v-if="scope.row.RltLevel == 3" class="red">危险</span>
|
|
|
+ <span v-if="scope.row.RltLevel == 4" class="red">危险</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="UpdateTs"
|
|
|
+ label="更新时间"
|
|
|
+ width="180"
|
|
|
+ :formatter="filterTime"
|
|
|
+ sortable
|
|
|
+ >
|
|
|
+ </el-table-column>
|
|
|
+ <!--<el-table-column-->
|
|
|
+ <!--prop="address"-->
|
|
|
+ <!--label="操作记录"-->
|
|
|
+ <!--width="220"-->
|
|
|
+ <!-->-->
|
|
|
+ <!--<template slot-scope="scope">-->
|
|
|
<!--<el-button class="" type="text" @click="goPhoneRecord(scope.row)">手机信号记录</el-button>-->
|
|
|
- <el-button class="" type="primary" size="small" @click="goWifiRecord(scope.row)">监测记录</el-button>
|
|
|
+ <!--<el-button class="" type="primary" size="small" @click="goWifiRecord(scope.row)">监测记录</el-button>-->
|
|
|
<!--<el-button v-if="scope.row.Status == 1" class="yellow" type="text" @click="pauseRow(scope.row)">禁用-->
|
|
|
<!--</el-button>-->
|
|
|
<!--<el-button v-if="scope.row.Status == 0" class="green" type="text" @click="runRow(scope.row)">启用-->
|
|
|
<!--</el-button>-->
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
+ <!--</template>-->
|
|
|
+ <!--</el-table-column>-->
|
|
|
</el-table>
|
|
|
<br>
|
|
|
<el-pagination
|
|
|
@@ -161,6 +255,7 @@
|
|
|
DetectorEdit,
|
|
|
GetDetectorCoords,
|
|
|
GeFullRegionSelect,
|
|
|
+ DetectorNetDevList
|
|
|
} from '../api/getApiRes.js'
|
|
|
|
|
|
let qs = require('qs');
|
|
|
@@ -200,22 +295,14 @@
|
|
|
],
|
|
|
// panel 配置项目
|
|
|
panel: {
|
|
|
- usercode: '',
|
|
|
- username: '',
|
|
|
- compname: '',
|
|
|
- keyword: '',
|
|
|
- USERCODE: '',
|
|
|
- taskstatus: 99,
|
|
|
- regionid: 0,
|
|
|
- regionid2: '',
|
|
|
- regionidOptions: [],
|
|
|
- regionidOptions2: [],
|
|
|
- options: [
|
|
|
- {value: 99, label: '全部'},
|
|
|
- {value: 1, label: '进行中'},
|
|
|
- {value: 2, label: '已完成'},
|
|
|
- ],
|
|
|
- time1: globalBt3(2),
|
|
|
+ mac: '',
|
|
|
+ deviceType: '',
|
|
|
+ level:'',
|
|
|
+ detectorId: '',
|
|
|
+ time1: globalBt3(1),
|
|
|
+ deviceTypeOptions: AllTypeOption(),
|
|
|
+ levelOptions: levelOptions(),
|
|
|
+ detectorIdOptions: [],
|
|
|
},
|
|
|
pageination: {
|
|
|
pageItem: 100,
|
|
|
@@ -237,11 +324,6 @@
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
|
- if (this.$route.query.RegionId) {
|
|
|
- this.panel.regionid = this.$route.query.RegionId;
|
|
|
- this.panel.tagname = this.$route.query.TagName;
|
|
|
- }
|
|
|
-
|
|
|
this.getTableQuery();
|
|
|
},
|
|
|
methods: {
|
|
|
@@ -251,27 +333,26 @@
|
|
|
// 页面数据查询
|
|
|
getTableQuery() {
|
|
|
let that = this;
|
|
|
- // this.getGetChildRegionSelect(0, 1);
|
|
|
- this.getGeFullRegionSelect();
|
|
|
that.loading = true;
|
|
|
- // 查询检测设备。上级区域id,区域id必传。regionid传0,查询supregionid对应所有子区域的检测设备。 如果supregionid,regionid都传0,默认查询企业ID下所有检测设备
|
|
|
+ let bt = parseInt(new Date(that.panel.time1[0]).getTime() / 1000);
|
|
|
+ let et = parseInt(new Date(that.panel.time1[1]).getTime() / 1000);
|
|
|
let param = {
|
|
|
token: localStorage.token,
|
|
|
mac: this.panel.mac,//
|
|
|
- regionId: that.panel.regionId,//
|
|
|
- name: that.panel.tagname,//标签名
|
|
|
- comid: 1,//
|
|
|
- start: 1,//
|
|
|
- tableMax: 9999,//
|
|
|
+ deviceType: that.panel.deviceType,//
|
|
|
+ level: that.panel.level,//标签名
|
|
|
+ bt: bt,//
|
|
|
+ et: et,//
|
|
|
+ offset: this.start,
|
|
|
+ limit: this.start + 100,//
|
|
|
};
|
|
|
let postdata = qs.stringify(param);
|
|
|
- DetectorList(postdata).then(res => {
|
|
|
+ DetectorNetDevList(postdata).then(res => {
|
|
|
let json = res;
|
|
|
if (json.Code == 0) {
|
|
|
that.loading = false;
|
|
|
if (json.Rs) {
|
|
|
that.allTableData = json.Rs;
|
|
|
- console.log(json.Rs);
|
|
|
that.recordsTotal = json.Rs.length;
|
|
|
} else {
|
|
|
that.allTableData = [];
|
|
|
@@ -821,7 +902,11 @@
|
|
|
},
|
|
|
filterTime(val, row, column) {
|
|
|
return nonTfmtDate(column, 10);
|
|
|
- }
|
|
|
+ },
|
|
|
+ // 过滤设备类型
|
|
|
+ filterType(value, row, column) {
|
|
|
+ return filterAllType(column);
|
|
|
+ },
|
|
|
},
|
|
|
watch: {
|
|
|
// 'dialog.regionlevelOneId': function (val) {
|