Ver Fonte

new page ready

Changpeng Duan há 5 anos atrás
pai
commit
e2319754d2

+ 14 - 0
src/api/getApiRes.js

@@ -230,3 +230,17 @@ export function GetChildRegionSelect(postdata) {
     let url = headapi + 'v1/Auth/GetChildRegionSelect';
     return getApiBasic(url, postdata);
 }
+
+// 修改密码
+export function PassEdit(postdata) {
+    // 修改密码
+    let url = headapi + 'v1/Auth/PassEdit';
+    return getApiBasic(url, postdata);
+}
+
+// 获取最新固件版本
+export function GetLastVerionFirmwareinfo(postdata) {
+    // 获取最新固件版本
+    let url = headapi + 'v1/AdminSettings/GetLastVerionFirmwareinfo';
+    return getApiBasic(url, postdata);
+}

+ 4 - 2
src/components/Console.vue

@@ -188,7 +188,9 @@
                         this.loftList = json.Region1Rs;//所有1级
                         this.manageList = json.Region2Rs;//所有2级
                         this.RoomList = json.Region3Rs;//所有3级
-                        this.equipList = json.DectectorRs;//所有设备
+                        if(json.DectectorRs){
+                            this.equipList = json.DectectorRs;//所有设备
+                        }
                         this.FullChildlRs = json.FullChildlRs;//全部关系
                     } else {
                         that.$message.error(json.Memo);
@@ -207,7 +209,7 @@
 
     .other-people {
         width: 350px;
-        min-height: 919px;
+        min-height: 939px;
         margin-left: 0;
     }
 

+ 1 - 1
src/components/EquipInfo.vue

@@ -94,7 +94,7 @@
 <style scoped>
     .other-people {
         width: 439px;
-        height: 422px;
+        height: 432px;
         margin-left: 0;
         overflow: hidden;
         background: #000F2A;

+ 61 - 85
src/components/HistoryRecord.vue

@@ -13,12 +13,12 @@
                     stripe
                     style="width: 100%">
                 <el-table-column
-                        prop="SSID"
-                        label="SSID"
-                        width="">
+                        prop="Macstr"
+                        label="MAC"
+                        width="140">
                     <template slot-scope="scope">
                         <i :class="[{'blue':scope.row.DangerLevel == -1},{'yellow':scope.row.DangerLevel != -1}]"></i>
-                        {{ scope.row.SSID }}
+                        {{ scope.row.Macstr }}
                     </template>
                 </el-table-column>
                 <el-table-column
@@ -31,6 +31,13 @@
                         prop="RegionName"
                         label="地点"
                         width="">
+                    <template slot-scope="scope">
+                        <el-tooltip class="item" effect="dark" :content="scope.row.RegionName" placement="top-start">
+                            <span>
+                                    {{ scope.row.RegionName.length > 6 ?  scope.row.RegionName.substr(0,6)+'...' : scope.row.RegionName }}
+                            </span>
+                        </el-tooltip>
+                    </template>
                 </el-table-column>
                 <el-table-column
                         prop="SignalIntensity"
@@ -54,21 +61,6 @@
     export default {
         data() {
             return {
-                // panel 配置项目
-                panel: {
-                    usercode: '',
-                    username: '',
-                    compname: '',
-                    keyword: '',
-                    USERCODE: '',
-                    taskstatus: 99,
-                    options: [
-                        {value: 99, label: '全部'},
-                        {value: 1, label: '进行中'},
-                        {value: 2, label: '已完成'},
-                    ],
-                    time1: globalBt(),
-                },
                 pageination: {
                     pageItem: 10,
                     pageoptions: pageOptions(),
@@ -91,77 +83,61 @@
         props: ['historyRs'],
         watch: {
             historyRs: function (val) {
-                this.getTableQuery(val)
+                this.loading = false;
+                this.allTableData = val.Rs;
+                this.recordsTotal = val.Rs.length;
+                // 设置分页数据
+                this.setPaginations();
             },
         },
         methods: {
-            // 页面数据查询
-            getTableQuery(val) {
-                let that = this;
-                if (val.Code == 0) {
-                    that.loading = false;
-                    if (val.Rs) {
-                        that.allTableData = val.Rs;
-                        that.recordsTotal = val.Rs.length;
-                    } else {
-                        that.allTableData = [];
-                        that.recordsTotal = 0;
-                    }
-
-                    // 设置分页数据
-                    that.setPaginations();
-                } else {
-                    that.$message.error(json.Memo);
-                }
-            },
-            // 设置分页数据
-            setPaginations() {
-                // 分页属性
-                let that = this;
-                that.pageination.total = that.recordsTotal;
-                // 默认分页
-                that.tableData = that.allTableData.filter((item, index) => {
-                    return index < that.pageination.pageItem;
-                });
-            },
-            // 每页显示数量
-            handleSizeChange() {
-                let that = this;
-                that.tableData = that.allTableData.filter((item, index) => {
-                    return index < that.pageination.pageItem;
-                });
-                that.draw = that.pageination.pageItem;
-                that.getTableQuery();
-            },
-            // 翻页
-            pageChange(pageIndex) {
-                let that = this;
-                // 获取当前页
-                let index = that.pageination.pageItem * (pageIndex - 1);
-                // 数据总数
-                let nums = that.pageination.pageItem * pageIndex;
-                // 容器
-                let tables = [];
-                for (var i = index; i < nums; i++) {
-                    if (that.allTableData[i]) {
-                        tables.push(that.allTableData[i])
-                    }
-                    this.tableData = tables;
+        // 设置分页数据
+        setPaginations() {
+            // 分页属性
+            let that = this;
+            that.pageination.total = that.recordsTotal;
+            // 默认分页
+            that.tableData = that.allTableData.filter((item, index) => {
+                return index < that.pageination.pageItem;
+            });
+        },
+        // 每页显示数量
+        handleSizeChange() {
+            let that = this;
+            that.tableData = that.allTableData.filter((item, index) => {
+                return index < that.pageination.pageItem;
+            });
+            that.draw = that.pageination.pageItem;
+        },
+        // 翻页
+        pageChange(pageIndex) {
+            let that = this;
+            // 获取当前页
+            let index = that.pageination.pageItem * (pageIndex - 1);
+            // 数据总数
+            let nums = that.pageination.pageItem * pageIndex;
+            // 容器
+            let tables = [];
+            for (var i = index; i < nums; i++) {
+                if (that.allTableData[i]) {
+                    tables.push(that.allTableData[i])
                 }
-                that.start = index * that.draw;
-                that.getTableQuery();
-            },
-            // 自动排序
-            sortChange(params) {
-                console.log(params)
-            },
-            // 过滤时间
-            filterFmtDate(value, row, column) {
-                let that = this;
-                return globalfmtDate(column, 10);
-            },
-            // 过滤金额
+                this.tableData = tables;
+            }
+            that.start = index * that.draw;
+        },
+        // 自动排序
+        sortChange(params) {
+            console.log(params)
         },
+        // 过滤时间
+        filterFmtDate(value, row, column) {
+            let that = this;
+            return globalfmtDate(column, 10);
+        },
+        // 过滤金额
+    }
+    ,
     }
 </script>
 

+ 8 - 15
src/components/SingleEquipInfo.vue

@@ -1,5 +1,5 @@
 <template>
-    <div class="equipinfo">
+    <div class="singleEquipinfo">
         <div class="other-people">
             <div class="image-border image-border1"></div>
             <div class="image-border image-border2"></div>
@@ -99,15 +99,8 @@
 </script>
 
 <style scoped>
-    .thisContent {
-        width: 100%;
-        height: 400px;
-        overflow: hidden;
-        display: block;
-        margin: 0 auto;
-    }
 
-    .equipinfo {
+    .singleEquipinfo {
         width: 100%;
         overflow: hidden;
         display: block;
@@ -116,17 +109,17 @@
 
     .other-people {
         width: 439px;
-        height: 422px;
+        height: 432px;
         margin-left: 0;
         overflow: hidden;
         background: #000F2A;
     }
 
-    .equipinfo .image-border2 {
+    .singleEquipinfo .image-border2 {
         right: 0;
     }
 
-    .equipinfo .image-border4 {
+    .singleEquipinfo .image-border4 {
         right: 0;
     }
 
@@ -171,7 +164,7 @@
         margin: 0 auto;
         font-size: 16px;
         font-weight: normal;
-        color: #005EA2;
+        color:#6DC1FF;
         text-align: left;
     }
 
@@ -185,7 +178,7 @@
         display: block;
         margin: 0 auto;
         font-size: 72px;
-        color: #005EA2;
+        color:#6DC1FF;
         text-align: left;
         font-family: UniDreamLED;
         letter-spacing: 1px;
@@ -197,7 +190,7 @@
         display: block;
         margin: 0 auto;
         font-size: 24px;
-        color: #005EA2;
+        color:#6DC1FF;
         text-align: right;
 
     }

+ 7 - 0
src/components/Watching.vue

@@ -8,6 +8,9 @@
                     <i v-if="l.DectectorName">{{l.DectectorName}}</i>
                     {{l.WarnString}}</em>
             </li>
+            <div class="notips" v-show="!list">
+                暂无数据,等待探查信号源
+            </div>
         </ul>
     </div>
 </template>
@@ -37,11 +40,15 @@
         watch: {
             totalRs: function (val) {
                 let that = this;
+                that.list = [];
+                that.readyList = [];
                 // 逐行显示
                 if(val.RegionDetRs){
+                    console.log(that.list);
                     that.wordDisplay(val.RegionDetRs);
                 }
                 if(val.DetRs){
+                    console.log(that.list);
                     that.wordDisplay([val.DetRs]);
                 }
             },

+ 166 - 38
src/views/Equip.vue

@@ -26,16 +26,6 @@
                                 </el-option>
                             </el-select>
                         </el-col>
-                        <!--<el-col :span="4" v-if="panel.regionidOptions2 != []">-->
-                        <!--<el-select v-model="panel.regionid2">-->
-                        <!--<el-option-->
-                        <!--v-for="item in panel.regionidOptions2"-->
-                        <!--:key="item.Id"-->
-                        <!--:label="item.Name"-->
-                        <!--:value="item.Id">-->
-                        <!--</el-option>-->
-                        <!--</el-select>-->
-                        <!--</el-col>-->
                         <el-col :span="4">
                             <el-button size="small" type="primary" @click="query">查询</el-button>
                         </el-col>
@@ -52,7 +42,7 @@
                 :data="tableData"
                 is-horizontal-resize
                 :default-sort="{prop: 'date', order: 'descending'}"
-                v-loading="loading"
+                v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.8)"
                 class=""
                 stripe
         >
@@ -107,6 +97,7 @@
                 <template slot-scope="scope">
                     <span v-if="scope.row.Status == 0">已禁用</span>
                     <span v-if="scope.row.Status == 1">已启用</span>
+                    <span v-if="scope.row.Status == 2">已离线</span>
                 </template>
             </el-table-column>
             <el-table-column
@@ -133,7 +124,7 @@
                 @current-change="pageChange"
         ></el-pagination>
 
-        <el-button class="down_btn" type="primary" @click="goPoster(scope.row)">下载驱动器todo</el-button>
+        <!--<el-button class="down_btn" type="primary" @click="goPoster(scope.row)">下载驱动器todo</el-button>-->
         <dialog_referrer_list
                 :show="dialog_state"
                 :title="dialog_title"
@@ -145,41 +136,67 @@
                 <el-row :gutter="20">
                     <el-col :span="10">
                         <label>
-                            设备ID
+                            MAC地址
                         </label>
                         <el-input v-model="dialog.name"></el-input>
                     </el-col>
                     <el-col :span="10">
                         <label>
-                            MAC地址
+                            标签名
                         </label>
-                        <el-input v-model="dialog.name"></el-input>
+                        <el-input v-model="dialog.tagname "></el-input>
                     </el-col>
                     <el-col :span="10">
                         <label>
-                            标签名
+                            设备所属区域
                         </label>
-                        <el-input v-model="dialog.name"></el-input>
+                        <el-select class="selectStyle" v-model="dialog.regionlevelOneId" placeholder="请选择所属区域">
+                            <el-option
+                                    v-for="item in dialog.regionlevelOneIdOptions"
+                                    :key="item.Id"
+                                    :label="item.Name"
+                                    :value="item.Id">
+                            </el-option>
+                        </el-select>
                     </el-col>
                     <el-col :span="10">
                         <label>
-                            设备所属楼层
+                            设备所属房间
                         </label>
-                        <el-select v-model="dialog.region" placeholder="请选择所属楼层">
+                        <el-select class="selectStyle" v-model="dialog.regionId" placeholder="请选择所属房间">
                             <el-option
-                                    v-for="item in panel.options"
-                                    :key="item.value"
-                                    :label="item.label"
-                                    :value="item.value">
+                                    v-for="item in dialog.regionIdRoomOptions"
+                                    :key="item.Id"
+                                    :label="item.Name"
+                                    :value="item.Id">
                             </el-option>
                         </el-select>
                     </el-col>
+                    <el-col :span="20">
+                        <label>
+                            坐标说明
+                        </label>
+                        <el-input v-model="dialog.coords_memo "></el-input>
+                    </el-col>
                     <el-col :span="20">
                         <label>
                             备注
                         </label>
                         <el-input type="textarea" v-model="dialog.memo"></el-input>
                     </el-col>
+                    <el-col :span="20">
+                        <label>
+                            位置标注
+                        </label>
+                        <div class="imgContianer">
+                            <img :src="dialog.plateImgSrc" alt="">
+                            <div class="pointers">
+                                <i></i>
+                                <i></i>
+                                <i></i>
+                            </div>
+                        </div>
+                    </el-col>
                 </el-row>
             </div>
         </dialog_referrer_list>
@@ -192,7 +209,8 @@
     import {
         DetectorQuery,
         GetChildRegionSelect,
-        DetectorEditStatus
+        DetectorEditStatus,
+        RegionPictureGetByRegionId,
     } from '../api/getApiRes.js'
 
     let qs = require('qs');
@@ -200,13 +218,25 @@
         data() {
             return {
                 // dialog
-                dialog_state: false,
+                dialog_state: true,
                 dialog_title: '添加主建筑',
                 dialog_type: '',//类型,1是添加,2是修改
                 dialog: {
-                    name: 10,
-                    region: 10,
+                    mac: '',
+                    comId: 1,
+                    regionlevelOneId: 0,
+                    regionId: 0,
+                    tagname: '',
+                    longitude: 0,
+                    latitude: 0,
+                    location: '',
+                    x: 0,
+                    y: 0,
+                    coords_memo: '',
                     memo: '',
+                    plateImgSrc: '',
+                    regionlevelOneIdOptions: [],
+                    regionIdRoomOptions: [],
                 },
                 tabIndex: 0,
                 tabs: [
@@ -309,7 +339,7 @@
                                 that.panel.regionid2 = json.Rs[0].Id;
                             } else {
                                 that.panel.regionidOptions2 = [];
-                                that.panel.regionid2 = ''
+                                that.panel.regionid2 = '';
                             }
 
                         }
@@ -318,6 +348,36 @@
                     }
                 })
             },
+            // dialog获取区域下级菜单
+            dialogGetGetChildRegionSelect(regionId, level) {
+                let that = this;
+                let param = {
+                    token: localStorage.token,
+                    regionId: regionId,
+                };
+                let postdata = qs.stringify(param);
+                GetChildRegionSelect(postdata).then(res => {
+                    let json = res;
+                    if (json.Code == 0) {
+                        if (level == 1) {
+                            that.dialog.regionlevelOneIdOptions = json.Rs;
+                            that.dialog.regionlevelOneId = json.Rs[0].Id;
+                        } else {
+                            if (json.Rs) {
+                                console.log(json.Rs);
+                                that.dialog.regionIdRoomOptions = json.Rs;
+
+                                that.dialog.regionId = json.Rs[0].Id;
+                            } else {
+                                that.dialog.regionIdRoomOptions = [];
+                                that.dialog.regionId = '';
+                            }
+                        }
+                    } else {
+                        that.$message.error(json.Memo);
+                    }
+                })
+            },
             // 跳转tab页面
             goTab(url) {
                 this.$router.push({path: url});
@@ -380,6 +440,7 @@
             addList() {
                 this.dialog_state = true;
                 this.dialog_title = '添加设备';
+                this.dialogGetGetChildRegionSelect(0,1);
             },
             delList() {
                 // checkNum
@@ -472,14 +533,13 @@
             },
             // 禁用
             pauseRow(row) {
-                console.log(row);
                 let that = this;
                 this.$confirm('是否禁用' + row.TagName + '设备?', '禁用操作', {
                     confirmButtonText: '确定',
                     cancelButtonText: '取消',
                     type: 'warning'
                 }).then(() => {
-                    that.getDetectorEditStatus(row.Id, '禁用');
+                    that.getDetectorEditStatus(row.Id, 0, '禁用');
                 }).catch(() => {
                     this.$message({
                         type: 'info',
@@ -487,6 +547,24 @@
                     });
                 });
             },
+            // 获取区域位置的平面图
+            getRegionPictureGetByRegionId(regionID) {
+                let that = this;
+                let param = {
+                    token: localStorage.token,
+                    regionID: regionID,
+                };
+                let postdata = qs.stringify(param);
+                RegionPictureGetByRegionId(postdata).then(res => {
+                    let json = res;
+                    that.dialog.plateImgSrc = '';
+                    if (json.Code == 0) {
+                        that.dialog.plateImgSrc = json.EncodeString
+                    } else {
+                        that.$message.error(json.Memo);
+                    }
+                })
+            },
             // 启用
             runRow(row) {
                 console.log(row);
@@ -496,7 +574,7 @@
                     cancelButtonText: '取消',
                     type: 'warning'
                 }).then(() => {
-                    that.getDetectorEditStatus(row.Id, '启用');
+                    that.getDetectorEditStatus(row.Id, 1, '启用');
                 }).catch(() => {
                     this.$message({
                         type: 'info',
@@ -505,13 +583,14 @@
                 });
             }
         },
-        // watch: {
-        //     'panel.regionid': function (val) {
-        //         let that = this;
-        //         console.log(val);
-        //         that.getGetChildRegionSelect(val,2)
-        //     },
-        // },
+        watch: {
+            'dialog.regionlevelOneId': function (val) {
+                this.dialogGetGetChildRegionSelect(val,2)
+            },
+            'dialog.regionId': function (val) {
+                this.getRegionPictureGetByRegionId(val);
+            },
+        },
         components: {
             dialog_referrer_list
         }
@@ -537,4 +616,53 @@
     .content {
         padding-left: 10px;
     }
+
+    .selectStyle {
+        width: 100%;
+        color: #005EA2;
+    }
+
+    .selectStyle ::placeholder {
+        color: #005EA2;
+    }
+
+    /deep/ .modal .el-select .el-input .el-select__caret {
+        position: relative;
+        top: 35px;
+    }
+    .imgContianer {
+        width: 100%;
+        height: 340px;
+        overflow: hidden;
+        display: block;
+        margin: 0 auto;
+    }
+    .imgContianer img {
+        width: 100%;
+        height: 100%;
+        overflow: hidden;
+        display: block;
+        margin: 0 auto;
+    }
+    .pointers {
+        position: relative;
+        bottom: 200px;
+        width: 100%;
+        height: 100%;
+        overflow: hidden;
+        display: block;
+        margin: 0 auto;
+        background: red;
+    }
+    .imgContianer i {
+        position: relative;
+        width: 5px;
+        height: 5px;
+        border-radius: 250px;
+        background: #6DC1FF;
+    }
+    /deep/ .modal-dialog {
+        height: 750px;
+        margin-top: 3%;
+    }
 </style>

+ 252 - 168
src/views/Hardware.vue

@@ -1,5 +1,5 @@
 <template>
-    <div>
+    <div class="content">
         <div class="tabs">
             <ul>
                 <li v-for="(tab,i) in tabs" @click="goTab(tab.url)" :class="{'active':tabIndex == i}">
@@ -12,134 +12,146 @@
             <div class="uploadContainer">
                 <el-upload
                         class="upload-demo"
-                        action="https://jsonplaceholder.typicode.com/posts/"
+                        action="/v1/AdminSettings/FirmwareUpdate"
                         :on-change="handleChange"
+                        :auto-upload="true"
                         :file-list="fileList">
                     <el-button size="small" type="primary">点击上传</el-button>
                 </el-upload>
                 <em class="addMemo" v-show="fileList.length == 0" @click="addMemo">
-                    <i></i>
-                    添加备注
+                    <i></i>添加备注
                 </em>
             </div>
         </div>
         <div class="hardwareList">
             <h5>设备列表</h5>
-        <div class="panel">
-            <div class="panel-body">
-                <div class=" panel_control">
-                    <el-row :gutter="20">
-                        <el-col :span="4">
-                            <em>所属区域:</em>
-                            <el-select v-model="panel.taskstatus">
-                                <el-option
-                                        v-for="item in panel.options"
-                                        :key="item.value"
-                                        :label="item.label"
-                                        :value="item.value">
-                                </el-option>
-                            </el-select>
-                        </el-col>
-                        <el-col :span="4">
-                            <em>固件版本:</em>
-                            <el-input v-model="panel.keyword" placeholder="请输入固件版本"></el-input>
-                        </el-col>
-
-                        <el-col :span="4">
-                            <el-button size="small" type="primary" @click="query">查询</el-button>
-                        </el-col>
-                    </el-row>
+            <div class="panel">
+                <div class="panel-body">
+                    <div class=" panel_control">
+                        <el-row :gutter="20">
+                            <el-col :span="4">
+                                <em>标签名:</em>
+                                <el-input v-model="panel.tagname" placeholder="请输入标签名"></el-input>
+                            </el-col>
+                            <el-col :span="4">
+                                <em>所属区域:</em>
+                                <el-select v-model="panel.regionid">
+                                    <el-option
+                                            v-for="item in panel.regionidOptions"
+                                            :key="item.Id"
+                                            :label="item.Name"
+                                            :value="item.Id">
+                                    </el-option>
+                                </el-select>
+                            </el-col>
+                            <el-col :span="4">
+                                <em>固件版本:</em>
+                                <el-input v-model="panel.keyword" placeholder="请输入固件版本"></el-input>
+                            </el-col>
+                            <el-col :span="4">
+                                <el-button size="small" type="primary" @click="query">查询</el-button>
+                            </el-col>
+                        </el-row>
+                    </div>
                 </div>
             </div>
-        </div>
-        <div class="contorl">
-            <el-button size="small" type="primary" @click="startUpdate">开始更新</el-button>
-            <div class="version">
-                <em>NEW</em>
-                <span>最新固件版本:v.2.0.1版本固件</span>
-            </div>
-            <el-tooltip class="item" effect="dark" content="一键更新全部设备固件" placement="top">
-                <i class="question"></i>
-            </el-tooltip>
-            <el-button class="allItem" size="small" type="primary" @click="changeList">全部更新</el-button>
+            <div class="contorl">
+                <el-button size="small" type="primary" @click="startUpdate">开始更新</el-button>
+                <div class="version">
+                    <em>NEW</em>
+                    <span>最新固件版本:v.2.0.1版本固件</span>
+                </div>
+                <el-tooltip class="item" effect="dark" content="一键更新全部设备固件" placement="top">
+                    <i class="question"></i>
+                </el-tooltip>
+                <el-button class="allItem" size="small" type="primary" @click="changeList">全部更新</el-button>
 
-        </div>
-        <el-table
-                :data="tableData"
-                class=""
-                stripe
-                @selection-change="handleSelectionChange"
-        >
-            <el-table-column
-                    type="selection"
-                    width="55">
-            </el-table-column>
-            <el-table-column
-                    prop="name"
-                    label="设备名称"
-            >
-            </el-table-column>
-            <el-table-column
-                    prop="name"
-                    label="设备安装位置"
-                    width="180">
-            </el-table-column>
-            <el-table-column
-                    prop="name"
-                    label="旧固件版本"
+            </div>
+            <br>
+            <el-table
+                    :data="tableData"
+                    is-horizontal-resize
+                    :default-sort="{prop: 'date', order: 'descending'}"
+                    v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.8)"
+                    class=""
+                    stripe
             >
-            </el-table-column>
-            <el-table-column
-                    prop="date"
-                    label="旧版本更新时间"
-                    width="180">
-            </el-table-column>
-            <el-table-column
-                    prop="address"
-                    label="最新固件版本">
-            </el-table-column>
-            <el-table-column
-                    prop="date"
-                    label="最新版本更新时间">
-            </el-table-column>
-            <el-table-column
-                    prop="address"
-                    label="信号强度">
-            </el-table-column>
-            <el-table-column
-                    prop="address"
-                    label="操作记录">
-                <template slot-scope="scope">
-                    <span @click="goRecord(scope.row)">探测记录</span>
-                </template>
-            </el-table-column>
-        </el-table>
-        <br>
-        <el-pagination
-                background
-                :total="pageination.total"
-                :page-size="pageination.pageItem"
-                @current-change="pageChange"
-        ></el-pagination>
+                <el-table-column
+                        type="selection"
+                        width="55">
+                </el-table-column>
+                <el-table-column
+                        prop="Mac"
+                        label="Mac"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="TagName"
+                        label="标签名"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="Location"
+                        label="位置"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="FirmwareVersion"
+                        label="软件版本"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="HardwareVersion"
+                        label="硬件版本"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="LastOnline"
+                        label="最近上线"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="Memo"
+                        label="备注"
+                >
+                </el-table-column>
+                <el-table-column
+                        prop="Status"
+                        label="状态"
+                >
+                    <template slot-scope="scope">
+                        <span v-if="scope.row.Status == 0">已禁用</span>
+                        <span v-if="scope.row.Status == 1">已启用</span>
+                        <span v-if="scope.row.Status == 2">已离线</span>
+                    </template>
+                </el-table-column>
+            </el-table>
+            <br>
+            <el-pagination
+                    background
+                    :total="pageination.total"
+                    :page-size="pageination.pageItem"
+                    @current-change="pageChange"
+            ></el-pagination>
 
-        <dialog_referrer_list
-                :show="dialog_state"
-                :title="dialog_title"
-                :large="true"
-                @dialog_cancel="dialog_cancel"
-                @dialog_ok="dialog_ok"
-        >
-            <div class="dialogContent">
-                <el-row :gutter="20">
-                    <el-col :span="20">
-                        <label>
-                            备注
-                        </label>
-                        <el-input type="textarea" v-model="dialog.memo"></el-input>
-                    </el-col>
-                </el-row>
-            </div>
-        </dialog_referrer_list>
+            <dialog_referrer_list
+                    :show="dialog_state"
+                    :title="dialog_title"
+                    :large="true"
+                    @dialog_cancel="dialog_cancel"
+                    @dialog_ok="dialog_ok"
+            >
+                <div class="dialogContent">
+                    <el-row :gutter="20">
+                        <el-col :span="20">
+                            <label>
+                                备注
+                            </label>
+                            <el-input type="textarea" v-model="dialog.memo"></el-input>
+                        </el-col>
+                    </el-row>
+                </div>
+            </dialog_referrer_list>
             <el-dialog
                     title="提示"
                     :visible.sync="dialogVisible"
@@ -152,14 +164,20 @@
   </span>
             </el-dialog>
 
-    </div>
+        </div>
     </div>
 </template>
 
 <script>
     import Global from '../Global.js'
     import dialog_referrer_list from '../components/dialog_referrer_list'
-
+    import {
+        DetectorQuery,
+        GetChildRegionSelect,
+        GetLastVerionFirmwareinfo,
+        RegionPictureGetByRegionId,
+    } from '../api/getApiRes.js'
+    let qs = require('qs');
     export default {
         data() {
             return {
@@ -188,6 +206,10 @@
                     keyword: '',
                     USERCODE: '',
                     taskstatus: 99,
+                    regionid: 0,
+                    regionid2: '',
+                    regionidOptions: [],
+                    regionidOptions2: [],
                     options: [
                         {value: 99, label: '全部'},
                         {value: 1, label: '进行中'},
@@ -206,30 +228,85 @@
                     region: 10,
                     memo: '',
                 },
+                draw: 1,
+                start: 0,
+                recordsTotal: 0,
+                tableData: [],
+                allTableData: [],
+                limit: '10',
+                multipleSort: false,
+                loading: true,
                 multipleSelection: [],
-                tableData: [{
-                    date: '2016-05-02',
-                    name: '王小虎',
-                    address: '上海市普陀区金沙江路 1518 弄'
-                }, {
-                    date: '2016-05-04',
-                    name: '王小虎',
-                    address: '上海市普陀区金沙江路 1517 弄'
-                }, {
-                    date: '2016-05-01',
-                    name: '王小虎',
-                    address: '上海市普陀区金沙江路 1519 弄'
-                }, {
-                    date: '2016-05-03',
-                    name: '王小虎',
-                    address: '上海市普陀区金沙江路 1516 弄'
-                }]
             }
         },
         mounted() {
             this.getTableQuery();
         },
         methods: {
+            // 页面数据查询
+            getTableQuery() {
+                let that = this;
+                that.loading = true;
+                this.getGetChildRegionSelect(0, 1);
+                // 查询检测设备。上级区域id,区域id必传。regionid传0,查询supregionid对应所有子区域的检测设备。 如果supregionid,regionid都传0,默认查询企业ID下所有检测设备
+                let param = {
+                    token: localStorage.token,
+                    supregionid: 0,//
+                    regionid: this.panel.regionid,//
+                    comid: 1,//
+                    tagname: that.panel.tagname,//标签名
+                    start: 1,//
+                    tableMax: 300,//
+                };
+                let postdata = qs.stringify(param);
+                DetectorQuery(postdata).then(res => {
+                    let json = res;
+                    if (json.Code == 0) {
+                        that.loading = false;
+                        if (json.Rs) {
+                            that.allTableData = json.Rs;
+                            that.recordsTotal = json.Rs.length;
+                        } else {
+                            that.allTableData = [];
+                            that.recordsTotal = 0;
+                        }
+
+                        // 设置分页数据
+                        that.setPaginations();
+                    } else {
+                        that.$message.error(json.Memo);
+                    }
+                })
+            },
+            // 获取下级列表
+            getGetChildRegionSelect(regionId, level) {
+                let that = this;
+                let param = {
+                    token: localStorage.token,
+                    regionId: regionId,
+                };
+                let postdata = qs.stringify(param);
+                GetChildRegionSelect(postdata).then(res => {
+                    let json = res;
+                    if (json.Code == 0) {
+                        if (level == 1) {
+                            that.panel.regionidOptions = json.Rs;
+                            that.panel.regionidOptions.unshift({Id: 0, Name: "全部"});
+                        } else {
+                            if (json.Rs) {
+                                that.panel.regionidOptions2 = json.Rs;
+                                that.panel.regionid2 = json.Rs[0].Id;
+                            } else {
+                                that.panel.regionidOptions2 = [];
+                                that.panel.regionid2 = '';
+                            }
+
+                        }
+                    } else {
+                        that.$message.error(json.Memo);
+                    }
+                })
+            },
             // 跳转tab页面
             goTab(url) {
                 this.$router.push({path: url});
@@ -244,34 +321,15 @@
                 console.log(val);
             },
             handleChange(file, fileList) {
+                console.log(123);
                 this.fileList = fileList.slice(-3);
             },
-            // 页面数据查询
-            getTableQuery() {
-                // let that = this;
-                // that.loading = true;
-                // let url = headapi + '?ctl=ajax&mod=dial&act=taskListQuery';//获取
-                // let param = {
-                //     'taskstatus': that.panel.taskstatus,
-                //     'bt': globaltime2String(that.panel.time1[0]),
-                //     'et': globaltime2String(that.panel.time1[1]),
-                //     'KEYWORD': that.panel.keyword,
-                //     'USERCODE': that.panel.USERCODE,
-                // };
-                // let JSON = '';
-                // let postdata = qs.stringify(param);
-                // axios.post(url, postdata)
-                //     .then(function (response) {
-                //         JSON = response.data;
-                //         that.loading = false;
-                //         that.allTableData = JSON.rs;
-                //         that.recordsTotal = JSON.rs.length;
-                //         // 设置分页数据
-                //         that.setPaginations();
-                //     })
-                //     .catch(function (error) {
-                //         console.log(error);
-                //     });
+            handleClose() {
+                console.log(123);
+            },
+            handleImgbefore(file) {
+                console.log(file);
+                this.dialog.image = file;
             },
             // 设置分页数据
             setPaginations() {
@@ -370,11 +428,11 @@
                 let id = that.field_id;
             },
             // 添加备注
-            addMemo(){
+            addMemo() {
                 this.dialog_state = true;
             },
             // 开始更新
-            startUpdate(){
+            startUpdate() {
                 // checkNum
                 if (!this.multipleSelection.length) {
                     this.$message({
@@ -397,19 +455,29 @@
     @import "../assets/css/panel.css";
     @import "../assets/css/dialog.css";
 
+    .content {
+        width: 100%;
+        overflow: hidden;
+        display: block;
+        margin: 0 auto;
+        padding-left: 10px;
+    }
+
     .tabs ul {
-        width: 800px;
+        width: 500px;
     }
 
     table span {
         cursor: pointer;
     }
+
     .upload {
         width: 100%;
         overflow: hidden;
         display: block;
         margin: 0 auto;
     }
+
     .upload h5 {
         width: 100%;
         overflow: hidden;
@@ -420,37 +488,45 @@
         text-align: left;
         font-weight: normal;
     }
+
     .uploadContainer {
         width: 100%;
         overflow: hidden;
         display: block;
         margin: 0 auto;
-        background: rgba(27,86,200,0.14);
+        background: rgba(27, 86, 200, 0.14);
         border: 1px solid #005EA2;
         border-radius: 0;
         margin-top: 11px;
         padding: 10px 0;
     }
+
     /deep/ .el-upload {
         float: left;
         margin-left: 27px;
     }
+
     /deep/ .el-upload-list {
         width: 200px;
         float: left;
     }
+
     /deep/ .el-upload-list__item-name [class^=el-icon] {
-        color:#6DC1FF ;
+        color: #6DC1FF;
     }
-    /deep/  .el-upload-list__item-name {
-        color:#6DC1FF ;
+
+    /deep/ .el-upload-list__item-name {
+        color: #6DC1FF;
     }
+
     /deep/ .el-upload-list__item:first-child {
         margin-top: 5px;
     }
+
     /deep/ .el-upload-list__item:hover {
         background: none;
     }
+
     .addMemo {
         width: 120px;
         height: 30px;
@@ -466,17 +542,19 @@
         margin-top: 2px;
         margin-left: 20px;
     }
+
     .addMemo i {
         width: 14px;
         height: 14px;
         overflow: hidden;
         float: left;
-        background: url("../assets/img/icon/addMemo.png")top center no-repeat;
+        background: url("../assets/img/icon/addMemo.png") top center no-repeat;
         background-size: 100% 100%;
         margin-top: 8px;
         margin-left: 20px;
         margin-right: 10px;
     }
+
     .hardwareList {
         width: 100%;
         overflow: hidden;
@@ -484,6 +562,7 @@
         margin: 0 auto;
         margin-top: 35px;
     }
+
     .hardwareList h5 {
         width: 100%;
         overflow: hidden;
@@ -495,6 +574,7 @@
         font-weight: normal;
         margin-bottom: 10px;
     }
+
     .contorl {
         /*width: 100%;*/
         overflow: hidden;
@@ -502,9 +582,11 @@
         margin: 0 auto;
         padding: 17px 23px;
     }
+
     em {
         font-style: normal;
     }
+
     .version {
         float: left;
         color: #6DC1FF;
@@ -513,14 +595,16 @@
         margin-left: 30px;
         line-height: 30px;
     }
+
     .allItem {
         float: right;
     }
+
     .question {
         width: 18px;
         height: 18px;
         cursor: pointer;
-        background: url("../assets/img/icon/question_icon.png")top center no-repeat;
+        background: url("../assets/img/icon/question_icon.png") top center no-repeat;
         float: right;
         margin-top: 7px;
         margin-left: 13px;

+ 48 - 36
src/views/Login.vue

@@ -7,23 +7,25 @@
                 <span class="subtitle">专用场所无线信号安全监控系统</span>
                 <el-card class="box-card">
                     <div class="center">
-                    <el-form ref="form" :model="form" label-width="0px" >
-                        <el-form-item label="">
-                            <el-input v-model="form.name" placeholder="用户名"></el-input>
-                        </el-form-item>
-                        <el-form-item label="">
-                            <el-input type="password" v-model="form.pwd" placeholder="密码"></el-input>
-                        </el-form-item>
-                        <el-form-item label=""  v-loading="validImgState"   element-loading-text="拼命加载中"
-                                      element-loading-spinner="el-icon-loading"
-                                      element-loading-background="rgba(0, 0, 0, 0.4)">
-                            <el-input v-model="form.valid" placeholder="验证码"    @keyup.enter.native="pwdLoginBtn"></el-input>
-                            <img  id="validImg" :src="valImgSrc" alt="" width="100px" height="30px" title="看不清?刷一下试试!" @click="changeValImg" >
-                        </el-form-item>
-                        <el-form-item>
-                            <el-button type="primary" class="primaryBtn" @click="onSubmit">确认</el-button>
-                        </el-form-item>
-                    </el-form>
+                        <el-form ref="form" :model="form" label-width="0px">
+                            <el-form-item label="">
+                                <el-input v-model="form.name" placeholder="用户名"></el-input>
+                            </el-form-item>
+                            <el-form-item label="">
+                                <el-input type="password" v-model="form.pwd" placeholder="密码"></el-input>
+                            </el-form-item>
+                            <el-form-item label="" v-loading="validImgState" element-loading-text="拼命加载中"
+                                          element-loading-spinner="el-icon-loading"
+                                          element-loading-background="rgba(0, 0, 0, 0.4)">
+                                <el-input v-model="form.valid" placeholder="验证码"
+                                          @keyup.enter.native="pwdLoginBtn"></el-input>
+                                <img id="validImg" :src="valImgSrc" alt="" width="100px" height="30px"
+                                     title="看不清?刷一下试试!" @click="changeValImg">
+                            </el-form-item>
+                            <el-form-item>
+                                <el-button type="primary" class="primaryBtn" @click="onSubmit">确认</el-button>
+                            </el-form-item>
+                        </el-form>
                     </div>
                 </el-card>
             </el-main>
@@ -35,14 +37,15 @@
 </template>
 
 <script>
-    import { SignIn,GenVerifyPic } from '../api/getApiRes.js'
+    import {SignIn, GenVerifyPic} from '../api/getApiRes.js'
+
     let qs = require('qs');
     import Global from '../Global.js'
 
     export default {
         data() {
             return {
-                thisYear:new Date().getFullYear(),
+                thisYear: new Date().getFullYear(),
                 form: {
                     name: '',
                     pwd: '',
@@ -67,19 +70,19 @@
             }
         },
         methods: {
-            CurentGenVerifyPic(){
+            CurentGenVerifyPic() {
                 let that = this;
                 let postdata;
                 GenVerifyPic(postdata).then(res => {
-                  let json = res;
-                  if (json.Id) {
-                      that.valImgSrc=json.Pic;
-                      that.form.picId=json.Id;
-                      this.validImgState = false;
-                  } else {
-                      that.$message.error(json.Memo);
-                  }
-              })
+                    let json = res;
+                    if (json.Id) {
+                        that.valImgSrc = json.Pic;
+                        that.form.picId = json.Id;
+                        this.validImgState = false;
+                    } else {
+                        that.$message.error(json.Memo);
+                    }
+                })
             },
             //            点击验证码切换
             changeValImg: function () {
@@ -130,7 +133,7 @@
                     'verifyName': username,
                     'verifyCode': userpwd,
                     'src': 'pc',
-                    'picId': picId ,
+                    'picId': picId,
                     'picCode': uservalid,
                 };
                 let postdata = qs.stringify(param);
@@ -152,9 +155,11 @@
                         } else {
                             that.$notify({
                                 title: '警告',
-                                message: json.Memo,
+                                message: res.Memo,
                                 type: 'warning'
                             });
+                            that.form.valid = '';
+                            that.changeValImg();
                         }
                     }
                 })
@@ -198,14 +203,14 @@
 
     .box-card {
         width: 626px;
-        min-height: 369px;
+        height: 389px;
         overflow: hidden;
         display: block;
         margin: 0 auto;
-        background: rgba(255,255,255,0.18)!important;
+        background: rgba(255, 255, 255, 0.18) !important;
         /*background: url("../assets/img/goss.png");*/
         /*background-image: url("../assets/img/goss.png");*/
-        border: 1px solid rgba(255,255,255,0.41);
+        border: 1px solid rgba(255, 255, 255, 0.41);
         background-repeat: no-repeat;
         background-position: top center;
         background-size: 100% 100%;
@@ -221,16 +226,19 @@
         float: right;
         bottom: 35px;
     }
+
     .center {
         width: 300px;
         overflow: hidden;
         display: block;
         margin: 0 auto;
-        background: rgba(255,255,255,0.25);
+        background: rgba(255, 255, 255, 0.25);
         border-radius: 12px;
         margin-top: 27px;
-        padding: 51px 133px;
+        margin-bottom: 27px;
+        padding: 31px 133px;
     }
+
     .primaryBtn {
         width: 100%;
         overflow: hidden;
@@ -240,17 +248,21 @@
         line-height: 24px;
         font-size: 16px;
     }
+
     .el-card {
         background: none;
     }
+
     /deep/ .el-input__inner {
         background: none;
         border: 1px solid #70C2FF;
         color: #BEE3FF;
     }
+
     /deep/ .el-input__inner::placeholder {
         color: #BEE3FF;
     }
+
     /deep/ .el-footer {
         position: absolute;
         bottom: 0;

+ 0 - 18
src/views/Main.vue

@@ -44,16 +44,6 @@
                                 <Room></Room>
                             </div>
                         </div>
-                        <!--<div class="DetctorContianer" v-if="pageLevel == 4">-->
-                        <!--<div class="tlt">-->
-                        <!--<h5>正在监测</h5>-->
-                        <!--<BigRader :total-rs="totalRs"></BigRader>-->
-                        <!--</div>-->
-                        <!--<div class="trt">-->
-                        <!--<h5>实时监测记录</h5>-->
-                        <!--<Watching :total-rs="totalRs"></Watching>-->
-                        <!--</div>-->
-                        <!--</div>-->
                     </div>
                 </div>
             </div>
@@ -136,14 +126,6 @@
             that.timer = setInterval(() => {
                 that.getDate();
             }, 1115000);
-
-            // let param = {
-            //     token: localStorage.token,
-            //     detectorId: 1,
-            //     regionId: this.regionId
-            // };
-            // let postdata = qs.stringify(param);
-            // that.getDetector06GInfolist(postdata);
         },
         destroyed() {
             //页面销毁时清除定时器

+ 21 - 24
src/views/PhoneSign.vue

@@ -34,12 +34,12 @@
                         </el-col>
                         <el-col :span="4">
                             <em>信道:</em>
-                            <el-select v-model="panel.Operator">
+                            <el-select v-model="panel.channel">
                                 <el-option
                                         v-for="item in panel.OperatorOptions"
                                         :key="item.Id"
                                         :label="item.Name"
-                                        :value="item.value">
+                                        :value="item.Name">
                                 </el-option>
                             </el-select>
                         </el-col>
@@ -54,7 +54,7 @@
                 :data="tableData"
                 is-horizontal-resize
                 :default-sort="{prop: 'date', order: 'descending'}"
-                v-loading="loading"
+                v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.8)"
                 class=""
                 stripe
         >
@@ -64,14 +64,14 @@
             >
             </el-table-column>
             <el-table-column
-                    prop="Wwan"
-                    label="通信方式"
+                    prop="Operator"
+                    label="信道"
                     width="120"
             >
             </el-table-column>
             <el-table-column
-                    prop="SignalType"
-                    label="信号类型"
+                    prop="Wwan"
+                    label="通信方式"
                     width="120"
             >
             </el-table-column>
@@ -85,12 +85,7 @@
                     prop="Path"
                     label="位置">
             </el-table-column>
-            <el-table-column
-                    prop="Operator"
-                    label="信道"
-                    width="120"
-            >
-            </el-table-column>
+
             <el-table-column
                     prop="DeviceType"
                     label="设备类型"
@@ -153,10 +148,10 @@
                     Operator: '',
                     taskstatus: 99,
                     OperatorOptions: [
-                        {Id: 99, Name: '全部',value: ''},
-                        {Id: 1, Name: '移动',value: '移动'},
-                        {Id: 2, Name: '联通',value: '联通'},
-                        {Id: 3, Name: '电信',value: '电信'},
+                        {Id: 99, Name: '全部', value: ''},
+                        {Id: 1, Name: '移动', value: '移动'},
+                        {Id: 2, Name: '联通', value: '联通'},
+                        {Id: 3, Name: '电信', value: '电信'},
                     ], options: [
                         {value: 99, label: '全部'},
                         {value: 1, label: '进行中'},
@@ -220,13 +215,13 @@
                 let that = this;
                 that.loading = true;
                 let param = {
-                    'token': localStorage.token,
-                    'detidstr': that.panel.detidstr + ',',//探测器id列表
-                    'channel ': that.panel.channel,//信道
-                    'bt': globaltime2String(that.panel.time1[0]) + ' 00:00:01',//开始时间
-                    'et': globaltime2String(that.panel.time1[1]) + ' 23:59:59',//结束时间
-                    'start': 1,//
-                    'tableMax': 300,//
+                    token: localStorage.token,
+                    detectorId: that.panel.detidstr + ',',//探测器id列表
+                    channel: that.panel.channel,//信道
+                    bt: globaltime2String(that.panel.time1[0]) + ' 00:00:01',//开始时间
+                    et: globaltime2String(that.panel.time1[1]) + ' 23:59:59',//结束时间
+                    start: 1,//
+                    tableMax: 300,//
                 };
                 let postdata = qs.stringify(param);
                 LogPhoneDetectedQueryByDetector(postdata).then(res => {
@@ -314,9 +309,11 @@
 
 <style scoped>
     @import "../assets/css/panel.css";
+
     .tabs ul {
         width: 400px;
     }
+
     .content {
         width: 100%;
         overflow: hidden;

+ 39 - 16
src/views/Pwd.vue

@@ -24,10 +24,11 @@
                 </el-form-item>
                 <el-form-item label="图形验证码" prop="valid">
                     <el-input v-model="form.valid" type="password"></el-input>
-                    <img  id="validImg" :src="valImgSrc" alt="" width="100px" height="30px" title="看不清?刷一下试试!" @click="changeValImg" >
+                    <img id="validImg" :src="valImgSrc" alt="" width="100px" height="30px" title="看不清?刷一下试试!"
+                         @click="changeValImg">
                 </el-form-item>
                 <!--<s>-->
-                    <!--<i class="el-icon-warning"></i><em>密码由6~32位字母、数字及下划线组成</em>-->
+                <!--<i class="el-icon-warning"></i><em>密码由6~32位字母、数字及下划线组成</em>-->
                 <!--</s>-->
                 <el-form-item>
                     <el-button size="small" type="primary" @click="onSubmit('form')">确认</el-button>
@@ -41,8 +42,12 @@
 <script>
     let qs = require('qs');
     import Global from '../Global.js'
-    import {modPwd, logout} from '../api/getApiRes.js'
-    import {GenVerifyPic } from '../api/getApiRes.js'
+    import {
+        PassEdit,
+        GenVerifyPic,
+        SignOut,
+    } from '../api/getApiRes.js'
+
     export default {
         data() {
             let samepass = (rule, value, callback) => {
@@ -109,14 +114,14 @@
             goTab(url) {
                 this.$router.push({path: url});
             },
-            CurentGenVerifyPic(){
+            CurentGenVerifyPic() {
                 let that = this;
                 let postdata;
                 GenVerifyPic(postdata).then(res => {
                     let json = res;
                     if (json.Id) {
-                        that.valImgSrc=json.Pic;
-                        that.form.picId=json.Id;
+                        that.valImgSrc = json.Pic;
+                        that.form.picId = json.Id;
                         this.validImgState = false;
                     } else {
                         that.$message.error(json.Memo);
@@ -142,6 +147,8 @@
                         that.form.old = '';
                         that.form.newpwd = '';
                         that.form.again = '';
+                        // 提交失败也要重载验证码
+                        this.CurentGenVerifyPic();
                         return false;
                     }
                 });
@@ -152,12 +159,15 @@
             submitPwd() {
                 let that = this;
                 let param = {
-                    oldPwd: that.form.old,
-                    newPwd: that.form.newpwd,
+                    token: localStorage.token,
+                    oldpass: that.form.old,
+                    newpass: that.form.newpwd,
                 };
                 let postdata = qs.stringify(param);
-                modPwd(postdata).then(res => {
+                PassEdit(postdata).then(res => {
                     let json = res;
+                    // 无论成功与否都重载验证码
+                    this.CurentGenVerifyPic();
                     if (json.Code == 0) {
                         that.$message({
                             showClose: true,
@@ -177,8 +187,11 @@
             // 重登录
             logoutPage() {
                 const that = this;
-                let postdata = {};
-                logout(postdata).then(res => {
+                let param = {
+                    token: localStorage.token,
+                };
+                let postdata = qs.stringify(param);
+                SignOut(postdata).then(res => {
                     let json = res;
                     if (json.Code == 0) {
                         that.$router.push({
@@ -199,13 +212,15 @@
     @import "../assets/css/panel.css";
 
     .tabs ul {
-          width: 800px;
-      }
+        width: 500px;
+    }
+
     .image-border {
         position: absolute;
         width: 20px;
         height: 20px;
     }
+
     .image-border1 {
         top: 0;
         left: 25px;
@@ -233,6 +248,7 @@
         border-right: 2px solid #6DC1FF;
         border-bottom: 2px solid #6DC1FF;
     }
+
     .pages {
         /*position: absolute;*/
         /*top: 0;*/
@@ -271,34 +287,40 @@
     s em {
         font-style: normal;
     }
+
     /deep/ .el-form {
         width: 500px;
         overflow: hidden;
         display: block;
         margin: 0 auto;
     }
+
     /deep/ .el-form-item__label {
-        width: 120px!important;
+        width: 120px !important;
         color: #6DC1FF;
         font-size: 16px;
         float: left;
     }
+
     /deep/ .el-form-item__content {
         width: 370px;
         float: right;
         overflow: hidden;
-        margin-left: 0px!important;
+        margin-left: 0px !important;
     }
+
     /deep/ .el-input__inner {
         background: none;
         color: #6DC1FF;
         border: 1px solid #005EA2;
         border-radius: 0;
     }
+
     /deep/ .el-range-input {
         background: none;
         color: #6DC1FF;
     }
+
     .el-button--primary {
         width: 186px;
         height: 30px;
@@ -307,6 +329,7 @@
         border: 1px solid #6DC1FF;
         border-radius: 0;
     }
+
     #validImg {
         position: relative;
         float: right;

+ 1 - 0
src/views/Region.vue

@@ -55,6 +55,7 @@
                         {{plateTitle}}
                     </div>
                     <ul class="list" v-if="loftListState">
+                        <span v-if="!loftList">没有下属区域,请先添加</span>
                         <li v-for="loft in loftList" @click="seePic(loft)">
                             <img src="../assets/img/region/loft.png" height="22"
                                                           width="20"/><em>{{loft.Name}}</em></li>

+ 1 - 1
src/views/Setting.vue

@@ -64,7 +64,7 @@
     @import "../assets/css/panel.css";
 
     .tabs ul {
-        width: 800px;
+        width: 500px;
     }
     .pages {
         width: 96%;

+ 11 - 9
src/views/WifiSign.vue

@@ -47,7 +47,7 @@
                 :data="tableData"
                 is-horizontal-resize
                 :default-sort="{prop: 'date', order: 'descending'}"
-                v-loading="loading"
+                v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.8)"
                 class=""
                 stripe
         >
@@ -175,8 +175,10 @@
                 GetRegionAndDectorSelect(postdata).then(res => {
                     let json = res;
                     if (json.Code == 0) {
+                        console.log(json);
                         this.panel.detOptions = json.DectectorRs;//所有设备
-                        this.panel.detOptions.push({Id: 0, Name: '全部'})
+                        this.panel.detOptions.unshift({Id: 0, Name: '全部'});
+
                     } else {
                         that.$message.error(json.Memo);
                     }
@@ -198,13 +200,13 @@
                 let that = this;
                 that.loading = true;
                 let param = {
-                    'token': localStorage.token,
-                    'detidstr': that.panel.detidstr + ',',//探测器id列表
-                    'detectedmac ': that.panel.detectedmac,//被检测设备Mac
-                    'bt': globaltime2String(that.panel.time1[0]) + ' 00:00:01',//开始时间
-                    'et': globaltime2String(that.panel.time1[1]) + ' 23:59:59',//结束时间
-                    'start': 1,//
-                    'tableMax': 300,//
+                    token: localStorage.token,
+                    detectorId: that.panel.detidstr,//探测器id列表
+                    detectedmac: that.panel.detectedmac,//被检测设备Mac
+                    bt: globaltime2String(that.panel.time1[0]) + ' 00:00:01',//开始时间
+                    et: globaltime2String(that.panel.time1[1]) + ' 23:59:59',//结束时间
+                    start: 1,//
+                    tableMax: 300,//
                 };
                 let postdata = qs.stringify(param);
                 LogWifiDetectedQueryByDetector(postdata).then(res => {