likang 2 年之前
父节点
当前提交
9cfcb942f4

+ 2 - 1
.env.development

@@ -4,4 +4,5 @@ ENV = 'development'
 # base api
 #VUE_APP_BASE_API = 'http://wxt.rltest.cn:8102'
 #VUE_APP_BASE_API = '127.0.0.1'
-VUE_APP_BASE_API = 'http://192.168.1.105:80'
+VUE_APP_BASE_API = 'http://192.168.1.105:8000'
+

+ 20 - 70
src/config/componentsMap.js

@@ -1,3 +1,11 @@
+/*
+ * @Descripttion: 
+ * @version: 1.0.0
+ * @Author: likang
+ * @Date: 2022-08-12 10:40:39
+ * @LastEditors: likang
+ * @LastEditTime: 2022-08-12 11:50:05
+ */
 /**
  * export component map
  */
@@ -20,8 +28,7 @@ export default {
     generate: () =>  import ('@/views/system/generate'),
     //邮箱管理
     email: () => import('@/views/system/email'),
-    //下发版本  用于下发日志使用
-    IssuedVersion: () => import('@/views/system/Issued_version'),
+   
     
     database: () => import ('@/views/system/database'),
     attachment: () =>  import ('@/views/system/attachments'),
@@ -40,46 +47,11 @@ export default {
     wechatMenus: () => import ('@/views/wechat/menus'),
 
     // 微信用户
-    wechatUsers: () => import ('@/views/wechat/users'),
-    // 微信用户标签
-    wechatTags: () => import ('@/views/wechat/tags'),
-    // wechatGraphic:() => import('@/views/catchAdmin/wechat/graphic'),
-    wechatReply: () =>  import ('@/views/wechat/reply'),
-    //微信公众号轮播图管理
-    wechatBanner: () => import ('@/views/wechat/banner'),
-    //微信公众号公告管理
-    wechatNotice: () => import ('@/views/wechat/notice'),
-    //微信公众号补卡管理
-    wechatUpdateCard: () =>  import ('@/views/wechat/updatecard'),
-    routeMap: () => import ('@/views/map/routeMap.vue'),
-    //智能工具箱地图
+ 
     WorkBoxMap: () => import ('@/views/work_box_map/routeMap.vue'),    
-    //设备管理
-    hyd_equipment: () => import ('@/views/device/hyd_equipment'),
-    storage_equipment: () => import('@/views/device/storage_equipment'),
-    //特种吊具
-    hanger_equipment:() => import('@/views/device/hanger_equipment'),
-    hydraulic: () => import ('@/views/device/hydraulic'),
-    wrench: () => import ('@/views/device/wrench'),
-    flange: () => import ('@/views/device/flange'),
-    maintenance: () => import ('@/views/device/maintenance'),
-    wind: () =>  import ('@/views/wind/wind'),
-    fan: () => import('@/views/wind/fan'),
-    //全部设备管理********************
-    equipments: () => import('@/views/device/equipments'),
-    
-    work_record: () => import ('@/views/work_record/work_record'),
-    //作业记录参数 映射表
-    maintenancemapper: () => import ('@/views/work_record/maintenancemapper'),
-    //作业位置管理表
-    worklocal_config: () =>  import ('@/views/work_record/worklocal_config'),
-    //工作计划
-    work_plan: () =>  import ('@/views/work_record/work_plan'),
-     //设备类别表
-    equipmentType: () => import ('@/views/equipment/equipment_type'),
-    //同步方案
-    synscheme: () => import ('@/views/device/synscheme'),
-    device_mold: () => import ('@/views/device/mold'),
+   
+   
+  
     // stolenVehicles: () => import('@/views/yunying/vehicle/stolen'),
     // 短信平台
     sms: () =>  import ('@/views/sms'),
@@ -94,34 +66,12 @@ export default {
     //类型字典
     sysDictType: () => import ('@/views/system/sysDictType'),
    
-
-    // 报表分析 => 设备汇总
-    // 液压泵统计
-    hydraulicCount: () =>  import ('@/views/report/hydraulicCount'),
-    // 告警设备统计
-    alarmDeviceCount: () => import ('@/views/report/alarmDeviceCount'),
-    // 作业记录统计
-    workCount: () =>  import ('@/views/report/workCount'),
-    maintainCount: () => import ('@/views/report/maintainCount'),
-    // 报表分析 => 概览 => 数据统计
-    dataCount: () => import ('@/views/report/dataCount'),
-    // 热力图
-    heatmap: () => import ('@/views/report/heatmap'),
-
-    
     //大屏
-    screen: () => import ('@/views/screen'),
-
-
-    //告警记录
-    alarmRecords: () => import ('@/views/alarm/alarmRecords/index'),
-    alarmReport: () => import ('@/views/alarm/alarmReport/index'),
-    alarmDevice: () => import ('@/views/alarm/device/index'),
-    pushResult: () => import ('@/views/alarm/pushResult/index'),
-    //轨迹地图
-    routeMap: () => import ('@/views/map/routeMap'),
-
-    // 围栏列表
-    fence: () => import ('@/views/fence/index'),
-
+    screen: () => import('@/views/screen'),
+    //基站标签
+    tag_history: () => import ('@/views/tag_history'),
+    
+   
+    
+   
 }

src/views/wind/fan/detail.vue → src/views/tag_history/detail.vue


src/views/wind/fan/index.scss → src/views/tag_history/index.scss


+ 433 - 0
src/views/tag_history/index.vue

@@ -0,0 +1,433 @@
+<template>
+  <div class="app-container">
+    <div class="filter-container" multiple style="padding-bottom: 0px">
+  
+          <el-select
+            v-model="queryParam.mac"
+            placeholder="所属基站"
+            class="filter-item form-search-input fl"
+            clearable
+             multiple
+          >
+          <el-option
+                v-for="item in MacOptions"
+                :key="item"
+                :label="item"
+                :value="item">
+              </el-option>
+          </el-select>
+          <el-select
+            v-model="queryParam.tage"
+            placeholder="标签"
+            class="filter-item form-search-input fl"
+            clearable
+             multiple
+          >
+          <el-option
+                v-for="item in TagOptions"
+                :key="item"
+                :label="item"
+                :value="item">
+              </el-option>
+          </el-select>
+          
+          <el-input
+            v-model="queryParam.meter"
+            placeholder="距离"
+            clearable
+            multiple
+            class="filter-item form-search-input fl"
+          />
+       
+         <el-button v-show="start"
+          class="filter-item search fl"
+          icon="el-icon-video-play"
+          type="warning"
+          @click="beforehandleSearch"
+          >开始计时</el-button
+        >
+
+        <el-button v-show="!start"
+          class="filter-item fl"
+          type="danger"
+          icon="el-icon-video-pause
+"
+          @click="beforhandleRefresh"
+          > {{timer}}</el-button
+        >
+      
+        <el-button
+          class="filter-item search fl"
+          icon="el-icon-refresh-right"
+          @click="refresh"
+          >刷新</el-button
+        >
+
+
+    </div>
+
+
+
+
+
+    <el-table
+      :data="data"
+      v-loading="loading"
+      ref="multipleTable"
+      @selection-change="hydraulicSelectMulti"
+      @sort-change="sortChange"
+      :dynamicColumnSetting="true"
+      tooltip-effect="dark"
+      style="width: 100%"
+      border
+      fit
+    >
+      <el-table-column
+        type="selection"
+        fixed="left"
+        width="55"
+      ></el-table-column>
+      
+      <el-table-column
+        prop="mac"
+        label="基站mac地址"
+        align="center"
+        :show-overflow-tooltip="true"
+      />
+      
+      <el-table-column
+        prop="lable"
+        label="标签号"
+        align="center"
+        sortable
+        :show-overflow-tooltip="true"
+      />
+       <el-table-column
+        prop="time"
+        label="上报时间"
+        align="center"
+        sortable
+        :show-overflow-tooltip="true"
+      />
+       <el-table-column
+        prop="addTime"
+        label="标签上报时间"
+        align="center"
+        sortable
+        :show-overflow-tooltip="true"
+      />
+       <el-table-column
+        prop="rssi"
+        label="当前信号强度"
+        align="center"
+        sortable
+        :show-overflow-tooltip="true"
+      />
+        <el-table-column
+        prop="ave_rssi"
+        label="平均信号强度"
+        align="center"
+        sortable
+        :show-overflow-tooltip="true"
+      />
+      <el-table-column
+        prop="num"
+        label="次数"
+        align="center"
+        sortable
+        :show-overflow-tooltip="true"
+      />
+  
+      <el-table-column
+        label="操作"
+        min-width="120"
+        align="center"
+        fixed="right"
+         width="180"
+      >
+        <template slot-scope="record">
+            
+            <el-button type="primary" size="mini" icon="el-icon-data-line" @click="handleDetail(record.row)" ></el-button>
+            
+        </template>
+      </el-table-column>
+    </el-table>
+
+    
+    <el-pagination
+      background
+      class="pagination-container"
+      @size-change="handleSizeChange"
+      @current-change="handleCurrentChange"
+      :current-page="paginate.current"
+      :page-sizes="paginate.sizes"
+      :page-size="paginate.limit"
+      :layout="paginate.layout"
+      :total="paginate.total"
+    />
+    
+    <detail
+      :detailVisible="detailVisible"
+       @sendVal="closeDrawer"
+       :data="detail"
+    />
+    
+  </div>
+</template>
+
+<script>
+import rlListOperate from "@/layout/rl-list-operate/rlListOperate";
+import { action } from "@/directive/permission/index.js";
+import { getToken } from "../../utils/auth";
+import detail from "./detail.vue";
+
+export default {
+  name: "fan",
+  directives: { action },
+  mixins: [rlListOperate],
+  components: {
+   
+    detail,
+  },
+  data() {
+    return {
+      url: "tagHistory",
+      TagOptions: [],
+      MacOptions:[],
+      queryParam: {
+        mac: "",
+        tage: '',
+        meter: '',
+        time:''
+      },
+      current_type: {
+        0: "success",
+        1: "danger",
+      },
+      start:true,
+      //搜索
+      searchDisplay: true,
+      departments: [],
+
+      //详情
+      detailVisible:false,
+      detail:{},
+      //定时器
+      refreshTageAndStation: '',
+      //计时
+      timer: '00:00:00',
+      //定时请求数据
+      refreshData:'',
+
+      refreshTime:'',
+      isShowColumn: false,
+      // 列的配置化对象,存储配置信息
+     
+      //导入请求url
+      actionUrl: process.env.VUE_APP_BASE_API + "/upload/file_excel",
+      headers: { authorization: "Bearer " + getToken() },
+      excel_url: "", //上传学生Excel返回的url
+      uploadDialogVisible: false, //下发配置显示与否
+      selectedWindId: "",
+      loadings: false,
+      submitText: "确 定",
+    };
+  },
+  created() {
+    this.queryParam.time = parseInt(new Date().getTime() / 1000);
+    this.refreshTagAndSta();
+  
+  },
+  mounted() { 
+    this.refreshTageAndStation = setInterval(() => {
+      this.refreshTagAndSta()
+    }, 1000 * 4);
+    //定时请求数据
+    this.refreshData =
+      setInterval(() => {
+        this.getData()
+      }, 1000 * 2);
+    
+  
+  },
+  beforeDestroy() {
+    clearInterval(this.refreshTageAndStation);
+    clearInterval(this.refreshTime);
+    clearInterval(this.refreshData);
+    this.refreshTime=null
+    this.refreshData = null;
+    this.refreshData = null;
+  },
+  methods: {
+    refreshTagAndSta()
+    {
+      this.$http.get("getStations").then((response) => {
+        this.MacOptions = response.data;
+      });
+      this.$http.get("getTages").then((response) => {
+        this.TagOptions = response.data;
+      });
+
+    },
+  
+
+
+    hydraulicSelectMulti(data) {
+      this.selectedIds = [];
+      data.forEach((item) => {
+        this.selectedIds.push(item.id);
+      });
+    },
+   
+    closeAddDialog(){
+      this.addFormVisible = false
+    },
+    handleAddSubmit() {
+      this.$http.post(this.$refs[this.AddFormName].url, this.$refs[this.AddFormName].formFieldsData).then(response => {
+          this.addFormVisible = false
+          this.handleRefresh()
+      })
+      
+    },
+       
+    closeDrawer(){
+      this.detailVisible = false
+    },
+    beforehandleSearch() {
+     
+      this.start = false;
+      this.queryParam.time = parseInt(new Date().getTime() / 1000); //开始计时
+      this.timetool()
+      this.handleSearch(); 
+    },
+    beforhandleRefresh()
+    {
+      clearInterval(this.refreshTime);
+      this.refreshTime = null
+      this.start = true
+      
+      //this.handleRefresh()
+    },
+    handleChange(val) {
+      //  console.log(val)
+      this.queryParam.department_id = val;
+      this.handleSearch();
+    },
+    timetool()
+    {
+      var i, j, k,i1,j1,k1;
+
+      i = 0;
+
+      j = 0;
+
+      k = 0;
+
+     this.refreshTime = setInterval(function () {
+
+          k++;
+          if (k > 59) {
+
+            k = 0;
+
+            j++;
+
+           
+            if (j > 59) {
+
+              j = 0;
+
+              i++;
+
+             
+
+            };
+    
+          };
+      
+       this.timer = i + ':' + j + ':' + k;
+      
+       //this.$set(this.timer, 'timer', i1 + ':' + j1 + ':' + k1)
+       console.log(this.timer);
+
+  }, 1000);
+
+  
+    },
+    refresh() {
+      this.queryParam.page = this.paginate.current;
+      this.getList();
+    },
+    //定时请求数据
+    getData()
+    {
+      
+        const query = this.queryParam
+        this.$http.get(this.url, { params: query }).then(response => {
+
+          this.data = response.data
+          this.handlePaginateResponse(response)
+          if (this.afterGetList !== undefined) {
+            this.afterGetList()
+          }
+        }).catch(() => {
+          
+        })
+    },
+    remoteMethod(query) {
+        if (query !== '') {
+          this.loading = true;
+          let url = 'wind?name='+query;
+          this.$http.get(url).then((response) => {
+          this.loading = false;
+            this.options = response.data;
+          });
+  
+        } else {
+          this.options = [];
+        }
+      },
+
+   
+    closeDrawer(){
+      this.detailVisible = false
+    },
+    importExcel() {
+      this.uploadDialogVisible = true;
+    },
+    beforeUpload(file) {
+      if (!/\.(xlsx|xls|XLSX|XLS)$/.test(file.name)) {
+        this.$notify.error({
+          title: "错误",
+          message: "上传文件只能为excel文件,且为xlsx,xls格式",
+        });
+        return false;
+      }
+      return true;
+    },
+    onremove() {
+      //移除文件钩子
+      this.excel_url = "";
+    },
+    onexeced(files) {
+      if (files.length == 1) {
+        this.$message.error("只能上传一个文件");
+      }
+    },
+    onchange(file, fileList) {
+      if (file.response) {
+        this.$message.success(file.response.data.msg);
+        this.excel_url = file.response.data.excel_url;
+      } else {
+        // console.log(file);
+      }
+    },
+    
+  },
+
+};
+</script>
+<style lang="scss" scoped>
+
+ @import "@/views/tag_history/index.scss";
+</style>

src/views/wind/fan/updateModel.vue → src/views/tag_history/updateModel.vue


+ 0 - 154
src/views/wind/fan/formModel.vue

@@ -1,154 +0,0 @@
-<template>
-  <ele-form-dialog
-    v-bind="formConfig"
-    v-model="formFieldsData"
-    v-dialogDrag
-    :title="title"
-    :request-fn="handleFormSubmit"
-    :visible.sync="DialogVisible"
-    width="550px"
-    custom-class="abow_dialog"
-    label-width="100px"
-    label-position="left"
-    :dialogAttrs="{ 'close-on-click-modal': false,'top':'8vh'}"
-  >
-    <template v-slot:number_rules="{ }" >
-       <el-input class="form-item1" v-model="rule_data.number_first" placeholder="机位号前缀"></el-input>
-       <el-input class="form-item1" v-model="rule_data.start_number" placeholder="起始编号"></el-input>
-       <el-input class="form-item1" v-model="rule_data.number_last" placeholder="机位号后缀"></el-input>
-       <el-input class="form-item1" v-model="rule_data.number_length" placeholder="生成数量"></el-input>
-       
-       <!-- <el-switch
-          v-model="zero_fill"
-          active-text="补零"
-          inactive-text="不补零">
-        </el-switch> -->
-        <el-checkbox class="form-item1" label="中间是否补零"  v-model="rule_data.zero_fill"></el-checkbox>
-        <el-input class="form-item1" v-if="rule_data.zero_fill" v-model="rule_data.zero_length" placeholder="补零长度"></el-input>
-    </template>
-  </ele-form-dialog>
-</template>
-
-<script>
-export default {
-  props: ["formModelVisible", "title"],
-  data() {
-    return {
-      url: "fan",
-      formData: {},
-      rule_data:{
-        start_number:'',
-        number_first:'',
-        number_length:'',
-        number_last:'',
-        zero_fill:'',
-        zero_length:'',
-      },
-      deviceTypes:[],
-      formFieldsData: {
-        wind_id: "",
-        number_rules: "",
-        fan_model:"",
-        supplier:"",
-        out_date:"",
-        address:"",
-        info: "",
-        mul_number:'',
-      },
-      formConfig: {
-        formDesc: {
-          wind_id: {
-            type: "select",
-            label: "所属风场",
-            isOptions: true,
-            options: [],
-            required: true,
-            prop: {
-              text: 'name',
-              value: 'id'
-            }
-          },
-          supplier: {
-            type: "input",
-            label: "供应商",
-             required: true,
-          },
-          out_date: {
-            type: "date",
-            label: "出厂日期",
-             required: true,
-          },
-          address: {
-            type: "input",
-            label: "地址",
-          },
-          fan_model: {
-            type: "select",
-            label: "型号",
-            required:true,
-            options: [],
-          },
-          number_rules: {
-   
-            label: "机位号规则",
-          },
-          mul_number: {
-            type: "textarea",
-            label: "机位号",
-            attrs: {
-              placeholder: '请输入机位号,多个机位号用英文逗号(,)相隔'
-            }
-          },
-           info: {
-            type: "textarea",
-            label: "备注",
-          },
-         
-        },
-        order: ["wind_id","fan_model","supplier","out_date","address", "number_rules","mul_number","info"]
-      }
-    };
-  },
-  created() {
-    this.$http.get("wind").then(response => {
-      this.formConfig.formDesc.wind_id.options = response.data;
-    });
-     // 4-风机
-    this.$http.get("get_device_mold",{ params: {type:4} }).then(resp => {
-        this.formConfig.formDesc.fan_model.options = resp.data
-     });
-  },
-  methods: {
-    handleFormSubmit(data) {
-      // console.log(this.rule_data)
-      // console.log(this.formFieldsData)
-      this.formFieldsData.rule_data=this.rule_data
-      this.$parent.handleAddSubmit();
-    },
-    handleRequest(data) {
-      return Promise.resolve();
-    },
-    handleRequestSuccess() {
-      this.$message.success("发送成功");
-    }
-  },
-  computed: {
-    DialogVisible: {
-      set(val) {
-        this.$emit("sendVal", val); // 表示将子组件改变的值传递给父组件
-      },
-      get() {
-        console.log(this.formFieldsData)
-        return this.formModelVisible; // 表示获取父组件的值
-      }
-    }
-  }
-};
-</script>
-<style lang="scss" scoped>
-.form-item1{
-  width:110px;
-  margin-right: 5px;
-  margin-bottom: 5px;
-}
-</style>

+ 0 - 527
src/views/wind/fan/index.vue

@@ -1,527 +0,0 @@
-<template>
-  <div class="app-container">
-    <div class="filter-container" style="padding-bottom: 0px">
-  
-      
-          <el-select
-            v-model="queryParam.wind_id"
-            placeholder="所属风场"
-            class="filter-item form-search-input fl"
-            clearable
-          >
-          <el-option
-                v-for="item in windOptions"
-                :key="item.id"
-                :label="item.name"
-                :value="item.id">
-              </el-option>
-          </el-select>
-
-          <el-select
-            v-model="queryParam.model"
-            placeholder="风机型号"
-            class="filter-item form-search-input fl"
-            clearable
-          >
-          <el-option
-                v-for="item in deviceTypes"
-                :key="item.value"
-                :label="item.text"
-                :value="item.value">
-              </el-option>
-          </el-select>
-     
-          <el-input
-            v-model="queryParam.number"
-            placeholder="编号"
-            clearable
-            class="filter-item form-search-input fl"
-            @keyup.enter.native="handleSearch"
-          />
-       
-         <el-button
-          class="filter-item search fl"
-          icon="el-icon-search"
-          @click="handleSearch"
-          >搜索</el-button
-        >
-        <el-button
-          class="filter-item fl"
-          icon="el-icon-refresh"
-          @click="handleRefresh"
-          >重置</el-button
-        >
-        
-     
-
-     
-        <el-button
-          class="filter-item search fl"
-          icon="el-icon-refresh-right"
-          @click="refresh"
-          >刷新</el-button
-        >
-     
-    </div>
-    <el-table
-      :data="data"
-      v-loading="loading"
-      ref="multipleTable"
-      @selection-change="hydraulicSelectMulti"
-      @sort-change="sortChange"
-      :dynamicColumnSetting="true"
-      tooltip-effect="dark"
-      style="width: 100%"
-      border
-      fit
-    >
-      <el-table-column
-        type="selection"
-        fixed="left"
-        width="55"
-      ></el-table-column>
-      
-      <el-table-column
-        prop="wind_name"
-        label="风场名称"
-        align="center"
-        :show-overflow-tooltip="true"
-      />
-      
-      <el-table-column
-        prop="number"
-        label="机位号"
-        align="center"
-        sortable
-        :show-overflow-tooltip="true"
-      />
-       <el-table-column
-        prop="model_name"
-        label="风机型号"
-        align="center"
-        sortable
-        :show-overflow-tooltip="true"
-      />
-       <el-table-column
-        prop="supplier"
-        label="供应商"
-        align="center"
-        sortable
-        :show-overflow-tooltip="true"
-      />
-       <el-table-column
-        prop="out_date"
-        label="出厂日期"
-        align="center"
-        sortable
-        :show-overflow-tooltip="true"
-      />
-       <el-table-column
-        prop="address"
-        label="地址"
-        align="center"
-        sortable
-        :show-overflow-tooltip="true"
-      />
-
-       <el-table-column
-        prop="info"
-        label="备注"
-        align="center"
-        :show-overflow-tooltip="true"
-      />  
-      <el-table-column
-        prop="created_at"
-        label="添加时间"
-        align="center"
-        sortable
-        :show-overflow-tooltip="true"
-      />
-   
-      
-      <el-table-column
-        label="操作"
-        min-width="120"
-        align="center"
-        fixed="right"
-         width="180"
-      >
-        <template slot-scope="record">
-            <el-button type="primary" size="mini" icon="el-icon-edit" @click="handleUpdate(record.row)" ></el-button>
-            <el-button type="primary" size="mini" icon="el-icon-data-line" @click="handleDetail(record.row)" ></el-button>
-            <el-button type="danger" size="mini" icon="el-icon-delete" @click="handleDelete(record.row.id)" />
-        </template>
-      </el-table-column>
-    </el-table>
-    <!-- <transition name="fade">
-      <div class="columnOption" v-show="isShowColumn">
-        <div class="content">
-          <div class="head">选择显示字段</div>
-          <div class="body">
-            <el-checkbox v-model="checkList.wind_name">所属部门风场</el-checkbox>
-            <el-checkbox v-model="checkList.number" disabled>编号</el-checkbox>
-            <el-checkbox v-model="checkList.name" disabled>名称</el-checkbox>
-            <el-checkbox v-model="checkList.supplier">供应商</el-checkbox>
-            <el-checkbox v-model="checkList.production_date">出厂日期</el-checkbox>
-            <el-checkbox v-model="checkList.install_date">安装日期</el-checkbox>
-            <el-checkbox v-model="checkList.location">位置</el-checkbox>
-          </div>
-          <div class="footer">
-            <el-button size="small" type="primary" plain @click="saveColumn"
-              >保存列配置</el-button
-            >
-          </div>
-        </div>
-      </div>
-    </transition> -->
-    <el-button
-      type="primary"
-      icon="el-icon-plus"
-      :loading="downloadLoading"
-      style="margin-top: 15px"
-      @click="handleAddFan()"
-      >添加</el-button
-    >
-    <el-button
-      type="danger"
-      icon="el-icon-delete"
-      v-if="selectedIds.length > 0"
-      style="margin-top: 15px"
-      @click="handleMultiDelete()"
-      >删除</el-button
-    >
-    <el-button
-      type="warning"
-      icon="el-icon-download"
-      :loading="downloadLoading"
-      style="margin-top: 15px"
-      @click="exportExcel"
-      >导出</el-button
-    >
-    <el-button
-      type="success"
-      icon="el-icon-upload"
-      :loading="downloadLoading"
-      style="margin-top: 15px"
-      @click="importExcel"
-      >导入</el-button
-    >
-    <el-pagination
-      background
-      class="pagination-container"
-      @size-change="handleSizeChange"
-      @current-change="handleCurrentChange"
-      :current-page="paginate.current"
-      :page-sizes="paginate.sizes"
-      :page-size="paginate.limit"
-      :layout="paginate.layout"
-      :total="paginate.total"
-    />
-    <form-model
-      @sendVal="closeAddDialog"
-      :formModelVisible="addFormVisible"
-      :title="title"
-      :ref="AddFormName"
-    />
-    <update-model
-      @sendVal="closeDialog"
-      :formModelVisible="formVisible"
-      :title="title"
-      :ref="formName"
-    />
-    <detail
-      :detailVisible="detailVisible"
-       @sendVal="closeDrawer"
-       :data="detail"
-    />
-    <el-dialog
-      title="导入风机"
-      append-to-body
-      width="400px"
-      :visible.sync="uploadDialogVisible"
-      custom-class="upload-dialog"
-    >
-
-      <el-select
-            v-model="selectedWindId"
-            placeholder="所属风场"
-            class="filter-item form-search-input fl"
-            clearable
-          >
-          <el-option
-                v-for="item in windOptions"
-                :key="item.id"
-                :label="item.name"
-                :value="item.id">
-              </el-option>
-          </el-select>
-      <el-upload
-        class="upload-demo"
-        drag
-        :action="actionUrl"
-        :headers="headers"
-        :before-upload="beforeUpload"
-        :show-file-list="true"
-        :on-change="onchange"
-        :on-remove="onremove"
-        :on-exceed="onexeced"
-        :limit="1"
-        ref="upload"
-      >
-        <i class="el-icon-upload"></i>
-        <div class="el-upload__text">
-          将文件拖到此处,或
-          <em>点击上传</em>
-        </div>
-        <div class="el-upload__tip upload-tips" slot="tip">
-          只能上传xls/xlsx文件
-        </div>
-      </el-upload>
-      <el-link
-        type="primary"
-        href="https://rlfd.oss-cn-hangzhou.aliyuncs.com/smart_tool/import_fan.xlss"
-        style="margin-top: 10px"
-        >下载模板</el-link
-      >
-      <span slot="footer" class="dialog-footer">
-        <el-button @click="uploadDialogVisible = false">取 消</el-button>
-        <el-button type="primary" @click="importDevices" :loading="loadings">{{
-          submitText
-        }}</el-button>
-      </span>
-    </el-dialog>
-  </div>
-</template>
-
-<script>
-import rlListOperate from "@/layout/rl-list-operate/rlListOperate";
-import { action } from "@/directive/permission/index.js";
-import { getToken } from "../../../utils/auth";
-import detail from "./detail.vue";
-import formModel from './formModel.vue';
-import updateModel from './updateModel.vue';
-export default {
-  name: "fan",
-  directives: { action },
-  mixins: [rlListOperate],
-  components: {
-    formModel,
-    updateModel,
-    detail,
-  },
-  data() {
-    return {
-      url: "fan",
-      options: [],
-      deviceTypes:[],
-      windOptions:[],
-      queryParam: {
-        number: "",
-        wind_id: '',
-      },
-      current_type: {
-        0: "success",
-        1: "danger",
-      },
-      AddFormName:'addFan',
-      formName:'fan',
-      addFormVisible:false,
-      formVisible:false, 
-      //搜索
-      searchDisplay: true,
-      departments: [],
-
-      //详情
-      detailVisible:false,
-      detail:{},
-
-      isShowColumn: false,
-      // 列的配置化对象,存储配置信息
-      checkList: {},
-      showColumn: {
-        wind_name: true,
-        production_date: true,
-        name:true,
-        location:true,
-        number: true,
-        production_date: true,
-        install_date: true,
-      },
-      //导入请求url
-      actionUrl: process.env.VUE_APP_BASE_API + "/upload/file_excel",
-      headers: { authorization: "Bearer " + getToken() },
-      excel_url: "", //上传学生Excel返回的url
-      uploadDialogVisible: false, //下发配置显示与否
-      selectedWindId: "",
-      loadings: false,
-      submitText: "确 定",
-    };
-  },
-  created() {
-    this.$http.get("wind").then((response) => {
-      this.windOptions = response.data;
-    });
-    // 4-风机
-    this.$http.get("get_device_mold",{ params: {type:4} }).then(resp => {
-        this.deviceTypes = resp.data
-     });
-  },
-  methods: {
-    handleAddFan(){
-      this.title = '新增'
-      this.isReadonly=false
-      this.id = null
-      this.resetFormFields();
-      this.addFormVisible = true
-    },
-    closeAddDialog(){
-      this.addFormVisible = false
-    },
-    handleAddSubmit() {
-      this.$http.post(this.$refs[this.AddFormName].url, this.$refs[this.AddFormName].formFieldsData).then(response => {
-          this.addFormVisible = false
-          this.handleRefresh()
-      })
-      
-    },
-        handleDetail(row){
-      this.detailVisible = true,
-      this.detail = row
-    },
-    closeDrawer(){
-      this.detailVisible = false
-    },
-    handleChange(val) {
-      //  console.log(val)
-      this.queryParam.department_id = val;
-      this.handleSearch();
-    },
-    hydraulicSelectMulti(data) {
-      this.selectedIds = [];
-      data.forEach((item) => {
-        this.selectedIds.push(item.id);
-      });
-    },
-    refresh() {
-      this.queryParam.page = this.paginate.current;
-      this.getList();
-    },
-    remoteMethod(query) {
-        if (query !== '') {
-          this.loading = true;
-          let url = 'wind?name='+query;
-          this.$http.get(url).then((response) => {
-          this.loading = false;
-            this.options = response.data;
-          });
-  
-        } else {
-          this.options = [];
-        }
-      },
-
-   
-    closeDrawer(){
-      this.detailVisible = false
-    },
-    importExcel() {
-      this.uploadDialogVisible = true;
-    },
-    beforeUpload(file) {
-      if (!/\.(xlsx|xls|XLSX|XLS)$/.test(file.name)) {
-        this.$notify.error({
-          title: "错误",
-          message: "上传文件只能为excel文件,且为xlsx,xls格式",
-        });
-        return false;
-      }
-      return true;
-    },
-    onremove() {
-      //移除文件钩子
-      this.excel_url = "";
-    },
-    onexeced(files) {
-      if (files.length == 1) {
-        this.$message.error("只能上传一个文件");
-      }
-    },
-    onchange(file, fileList) {
-      if (file.response) {
-        this.$message.success(file.response.data.msg);
-        this.excel_url = file.response.data.excel_url;
-      } else {
-        // console.log(file);
-      }
-    },
-    importDevices() {
-      // console.log(this.excel_url);
-      var url = this.excel_url
-      var wind_id = this.selectedDepartId;
-      if (depart_id == "") {
-        this.$message.error("请选择风场");
-        return;
-      }
-      if (url == "") {
-        this.$message.error("请上传文件");
-        return;
-      }
-      this.loadings = true;
-      this.submitText = "导入中";
-      this.$http
-        .post("cardDevice/import", { url: url, depart_id: depart_id })
-        .then((response) => {
-          if (response.data.error) {
-            this.$message.error(response.data.msg);
-          } else {
-            this.$message.success(response.data);
-          }
-          this.excel_url = "";
-          this.selectedDepartId = "";
-          this.$refs.upload.clearFiles();
-          this.loadings = false;
-          this.submitText = "确定";
-          this.uploadDialogVisible = false;
-          this.getList();
-        });
-    },
-  },
-  watch: {
-    // 监听复选框配置列所有的变化
-    checkList: {
-      handler: function (newnew, oldold) {
-        // console.log(newnew);
-        this.showColumn = newnew;
-        // 这里需要让表格重新绘制一下,否则会产生固定列错位的情况
-        this.$nextTick(() => {
-          this.$refs.multipleTable.doLayout();
-        });
-      },
-      deep: true,
-      immediate: true,
-    },
-  },
-
-  mounted() {
-    // this.getIsUseVoice();
-
-    // 发请求得到checkListInitData的列的名字
-    if (localStorage.getItem("fan")) {
-      this.checkList = JSON.parse(localStorage.getItem("fan"));
-    } else {
-      this.checkList = {
-        wind_name: true,
-        name:true,
-        production_date: true,
-        location:true,
-        number: true,
-        production_date: true,
-        install_date: true,
-      };
-    }
-  },
-};
-</script>
-<style lang="scss" scoped>
- @import "@/views/wind/fan/index.scss";
-</style>

+ 0 - 161
src/views/wind/wind/components/viewDialog.vue

@@ -1,161 +0,0 @@
-<template>
-  <el-dialog
-    :visible.sync="dialogVisible"
-    width="460px"
-    custom-class="view-dialog"
-    :modal-append-to-body="false"
-    :append-to-body="true">
-    <el-divider class="dialog-divider"></el-divider>
-      <div class="dialog-content">
-        <el-row class="dialog-row">
-          <div class="dialog-row-title">风场信息</div>
-          <div class="dialog-row-content">
-            <span class="content-row"> <span class="name-item">风场编号: </span> <span>{{info.number}}</span> </span>
-            <span class="content-row"> <span class="name-item">风场名称: </span> <span>{{info.name}}</span> </span>
-            <span class="content-row"> <span class="name-item">所属部门: </span> <span>{{info.depart_name}}</span> </span>
-            <span class="content-row"> <span class="name-item">所属区域: </span> <span>浙江省杭州市滨江区</span> </span>
-            <span class="content-row"> <span class="name-item">详细地址: </span> <span>{{info.address}}</span> </span>
-            <span class="content-row"> <span class="name-item">风场类型: </span> <span>海上</span> </span>
-            <span class="content-row"> <span class="name-item">环境类型: </span> <span>潮间带</span> </span>
-            <span class="content-row"> <span class="name-item">海拔高度: </span> <span>100米</span> </span>
-            <span class="content-row"> <span class="name-item">主机制造商: </span> <span>上海电气</span> </span>
-           
-            <span class="content-row"> <span class="name-item">添加人员: </span> <span>{{info.creator}}</span> </span>
-            <span class="content-row"> <span class="name-item">添加时间: </span> <span>{{info.created_at}}</span> </span>
-            <span class="content-row"> <span class="name-item" v-html="'备       注: '"> </span> <span>{{info.remark}}</span> </span>
-
-          </div>
-        </el-row>
-
-        <el-row class="dialog-row">
-          <div class="dialog-row-title">风机统计  
-          </div>
-          <div class="dialog-row-content">
-            <span class="content-row"> <span class="name-item"> 机型(SWT-2.5-108): </span> <span>40台</span> </span>
-            <span class="content-row"> <span class="name-item"> 机型(SWT-2.5WM-108): </span> <span>40台</span> </span>
-          </div>
-        </el-row>
-
-        <el-row class="dialog-row">
-          <div class="dialog-row-title">设备统计  
-          </div>
-          <div class="dialog-row-content">
-            <span class="content-row"> <span class="name-item"> 液压泵: </span> <span>40台</span> </span>
-            <span class="content-row"> <span class="name-item"> 液压扳手: </span> <span>40台</span> </span>
-          </div>
-        </el-row>
-
-      </div>
-    <el-divider class="dialog-divider"></el-divider>
-    <span slot="footer" class="dialog-footer">
-      <el-button style="margin-left:20px" type="primary" @click="dialogVisible = false">确 定</el-button>
-    </span>
-    <!-- <device-dialog 
-    :deviceVisible="innerVisible" 
-    @sendVal="closeDeviceDialog" 
-    :assetNo="dialogAssetNo"
-    /> -->
-  </el-dialog>
-
-</template>
-<script>
-
-// import deviceDialog from "./deviceDialog"
-  export default {
-    props:['detailVisible',"info"],
-    components: {
-      // deviceDialog
-    },
-    data() {
-      return {
-
-        deviceInfo:{},
-        dialogAssetNo:'',
-        path:"",
-        innerVisible: false,
-      };
-    },
-    methods: {
-      handleDeviceInfo(){
-        // console.log(this.deviceInfo)
-        this.innerVisible=true
-        this.dialogAssetNo=this.deviceInfo.asset_no
-      },
-      closeDeviceDialog(){
-        this.innerVisible=false
-      }
-    },
-    watch:{
-     
-    }, 
-    computed: {
-      dialogVisible: {
-      set (val) {
-
-        this.$emit('sendVal', val) 
-      },
-      get () {
-
-        return this.detailVisible
-      }
-    },
-    }
-  };
-</script>
-<style scoped>
-::v-deep .el-dialog{
-  min-width: 360px;
-}
- .el-dialog__body{
-  padding: 0px!important;
-  /* padding-bottom: 0px!important; */
-}
-
-
-.dialog-divider{
-  margin:0px;
-}
-.dialog-content{
-  padding: 5px;
-}
-
-.dialog-row{
-  display: flex;
-  flex-direction: column;
-  padding: 10px;
-  font-size: 12px;
-}
-.dialog-row-title{
-  margin-left: 20px;
-  margin-bottom: 10px;
-  font-size: 15px;
-  color: #FFF;
-}
-.dialog-row-content{
-  margin-left: 50px;
-  display: flex;
-  flex-direction: column; 
-}
-.content-row{
-  margin-top: 5px;
-  color:#FFF;
-}
-.name-item{
-  width: 60px;
-  white-space:pre;
-  word-wrap: break-word;
-}
-.el-drawer__body{
-  max-height:100vh;
-  overflow: hidden;
-   overflow-y: auto;
-   width:100%;
-
-}
-.primary-btn{
-  color: #fff;
-  background-color: #409eff;
-  border-color: #98a9b9;
-  margin-left:5px;
-}
-</style>

+ 0 - 151
src/views/wind/wind/components/viewPumpDialog.vue

@@ -1,151 +0,0 @@
-<template>
-  <el-dialog
-    :visible.sync="dialogVisible"
-    width="460px"
-    custom-class="view-dialog"
-    :modal-append-to-body="false"
-    :append-to-body="true">
-    <el-divider class="dialog-divider"></el-divider>
-      <div class="dialog-content">
-        <el-row class="dialog-row">
-          <div class="dialog-row-title">液压泵信息</div>
-          <div class="dialog-row-content">
-            <span class="content-row"> <span class="name-item">液压泵名称: </span> <span>{{info.name}}</span> </span>
-            <span class="content-row"> <span class="name-item">液压泵编号: </span> <span>{{info.number}}</span> </span>
-            <span class="content-row"> <span class="name-item">所属部门: </span> <span>{{info.depart_name}}</span> </span>
-   
-            <span class="content-row"> <span class="name-item">设备型号: </span> <span>{{info.model_name}}</span> </span>
-            <span class="content-row"> <span class="name-item">添加人远: </span> <span>{{info.creator_user}}</span> </span>
-            <span class="content-row"> <span class="name-item">添加时间: </span> <span>{{info.created_at}}</span> </span>
-            <span class="content-row"> <span class="name-item">压力范围: </span> <span>{{info.min_pressure}}~{{info.max_pressure}}</span> </span>
-          
-            <span class="content-row"> <span class="name-item">供 应 商 : </span> <span>{{info.supplier}}</span> </span>
-            <!-- <span class="content-row"> <span class="name-item">在线时间: </span> <span>{{info.online_time}}</span> </span> -->
-      
-
-          </div>
-        </el-row>
-
-        <!-- <el-row class="dialog-row">
-          <div class="dialog-row-title">定位信息  
-          </div>
-          <div class="dialog-row-content">
-            <span class="content-row"> <span class="name-item"> 定位类型: </span> <span>{{info.station_name || ''}}</span> </span>
-            <span class="content-row"> <span class="name-item"> 详细地址: </span> <span>{{info.address || ''}}</span> </span>
-          </div>
-        </el-row> -->
-
-      </div>
-    <el-divider class="dialog-divider"></el-divider>
-    <span slot="footer" class="dialog-footer">
-      <!-- <el-button @click="dialogVisible = false">取 消</el-button> -->
-      <el-button style="margin-left:20px" type="primary" @click="dialogVisible = false">确 定</el-button>
-    </span>
-    <!-- <device-dialog 
-    :deviceVisible="innerVisible" 
-    @sendVal="closeDeviceDialog" 
-    :assetNo="dialogAssetNo"
-    /> -->
-  </el-dialog>
-
-</template>
-<script>
-
-// import deviceDialog from "./deviceDialog"
-  export default {
-    props:['detailVisible',"info"],
-    components: {
-      // deviceDialog
-    },
-    data() {
-      return {
-
-        deviceInfo:{},
-        dialogAssetNo:'',
-        path:"",
-        innerVisible: false,
-      };
-    },
-    methods: {
-      handleDeviceInfo(){
-        // console.log(this.deviceInfo)
-        this.innerVisible=true
-        this.dialogAssetNo=this.deviceInfo.asset_no
-      },
-      closeDeviceDialog(){
-        this.innerVisible=false
-      }
-    },
-    watch:{
-     
-    }, 
-    computed: {
-      dialogVisible: {
-      set (val) {
-
-        this.$emit('sendVal', val) 
-      },
-      get () {
-
-        return this.detailVisible
-      }
-    },
-    }
-  };
-</script>
-<style scoped>
-::v-deep .el-dialog{
-  min-width: 360px;
-}
- .el-dialog__body{
-  padding: 0px!important;
-  /* padding-bottom: 0px!important; */
-}
-
-
-.dialog-divider{
-  margin:0px;
-}
-.dialog-content{
-  padding: 5px;
-}
-
-.dialog-row{
-  display: flex;
-  flex-direction: column;
-  padding: 10px;
-  font-size: 12px;
-}
-.dialog-row-title{
-  margin-left: 20px;
-  margin-bottom: 10px;
-  font-size: 15px;
-  color: black;
-}
-.dialog-row-content{
-  margin-left: 50px;
-  display: flex;
-  flex-direction: column; 
-}
-.content-row{
-  margin-top: 5px;
-}
-.name-item{
-  width: 60px;
-  white-space:pre;
-  word-wrap: break-word;
-}
-.el-drawer__body{
-  max-height:100vh;
-  overflow: hidden;
-   overflow-y: auto;
-   width:100%;
-
-}
-.primary-btn{
-  color: #fff;
-  background-color: #409eff;
-  border-color: #98a9b9;
-  margin-left:5px;
-}
-</style>

+ 0 - 332
src/views/wind/wind/floor/index.vue

@@ -1,332 +0,0 @@
-<template>
-    <div class="app-container">
-        <div class="table-header">
-            <div class="tatble-toolbar">
-                <el-row style="float: right;margin: 5px 0;">
-                    <el-button type="primary" icon="el-icon-plus" @click="showFormDialog = true">添加楼层</el-button>
-                </el-row>
-            </div>
-        </div>
-        <div class="table-body">
-            <el-table
-                :data="tableData"
-                border
-                fit
-                style="width: 100%">
-                <el-table-column
-                    fixed
-                    prop="name"
-                    label="楼层名称"
-                    align="center"
-                    width="100"
-                />
-                <el-table-column
-                    prop="building_name"
-                    label="所属建筑"
-                    align="center"
-                />
-                <el-table-column
-                    prop="school_name"
-                    label="所属学校"
-                    align="center"
-                />
-                <el-table-column
-                    prop="drawing_path"
-                    label="楼层图纸"
-                    align="center"
-                >
-                    <template slot-scope="scope">
-                        <el-image
-                            style="width: 50px;"
-                            :src="scope.row.drawing_path"
-                            :preview-src-list="[scope.row.drawing_path]">
-                            <div slot="error" class="image-slot">
-                                <i class="el-icon-picture-outline"></i>
-                            </div>
-                        </el-image>
-                    </template>
-                </el-table-column>
-                <el-table-column
-                    prop="sort"
-                    label="排序"
-                    align="center"
-                    width="100"
-                />
-                <el-table-column
-                    label="操作"
-                    align="center"
-                    width="100">
-                    <template slot-scope="scope">
-                        <el-tooltip content="修改" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-edit" @click="updateInfo(scope.row)"></el-button>
-                        </el-tooltip>
-                        <el-tooltip content="删除" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-delete" @click="deleteFloor(scope.row.id)"></el-button>
-                        </el-tooltip>
-                    </template>
-                </el-table-column>
-            </el-table>
-        </div>
-        <div class="table-footer">
-            <div class="table-pagination">
-                <el-pagination
-                    @size-change="handleSizeChange"
-                    @current-change="handleCurrentChange"
-                    :current-page="paginate.current"
-                    :page-sizes="paginate.sizes"
-                    :page-size="paginate.limit"
-                    layout="total, sizes, prev, pager, next, jumper"
-                    :total="paginate.total">
-                </el-pagination>
-            </div>
-        </div>
-
-        <!-- form 表单 -->
-        <el-dialog title="楼层信息" :visible.sync="showFormDialog" append-to-body destroy-on-close @closed="onFormDialogClosed" width="500px">
-            <el-form ref="floorForm" :rules="rules" :model="form" label-width="80px">
-                <!-- <el-form-item label="所属学校" required prop="school_id">
-                    <el-select v-model="form.school_id" filterable placeholder="请选择所属学校">
-                        <el-option v-for="school in schoolData" :key="school.id" :label="school.name" :value="school.id"></el-option>
-                    </el-select>
-                </el-form-item>
-                <el-form-item label="所属建筑" required prop="building_id">
-                    <el-select v-model="form.school_id" filterable placeholder="请选择所属建筑">
-                        <el-option v-for="school in schoolData" :key="school.id" :label="school.name" :value="school.id"></el-option>
-                    </el-select>
-                </el-form-item> -->
-                <el-form-item label="楼层名称" required prop="name">
-                    <el-input v-model="form.name" ></el-input>
-                </el-form-item>
-                <el-form-item label="排序编号">
-                    <el-input-number v-model="form.sort" label="楼层排序编号"></el-input-number>
-                </el-form-item>
-                <el-form-item label="楼层图纸">
-                    <!-- <el-upload
-                        class="avatar-uploader"
-                        name="image"
-                        :action="uploadUrl"
-                        :headers="uploadHeaders"
-                        :show-file-list="false"
-                        :on-success="onUploadSuccess"
-                        :before-upload="beforeUpload">
-                        <img v-if="imageUrl" :src="imageUrl" class="avatar">
-                        <i v-else class="el-icon-plus avatar-uploader-icon"></i>
-                    </el-upload> -->
-
-                    <el-web-to-oss
-                        @input="getUploadImages"
-                        type="image"
-                        :fileList="imageList"
-                        :maxSize="2"
-                    />
-                </el-form-item>
-            </el-form>
-            <div slot="footer" class="dialog-footer">
-                <el-button @click="closeDialog">取 消</el-button>
-                <el-button type="primary" @click="submitForm">确 定</el-button>
-            </div>
-        </el-dialog>
-    </div>
-</template>
-
-<script>
-
-import rlListOperate from '@/layout/rl-list-operate/rlListOperate'
-import ElWebToOss from "@/components/Upload/ElWebToOss";
-
-  export default {
-    mixins: [ rlListOperate ],
-    components: {
-        ElWebToOss,
-    },
-    props: {
-        buildingInfo: {
-            type: Object,
-            default: function() {
-                return {}
-            }
-        }
-    },
-    watch: {
-        buildingInfo: function(val) {
-            this.url = 'kqFloor/getBuildingFloorList/' + val.id,
-            this.handleRefresh()
-        },
-    },
-    data() {
-      return {
-        url: 'kqFloor/getBuildingFloorList/' + this.buildingInfo.id,
-        uploadUrl: process.env.VUE_APP_BASE_API + '/upload/image',
-        uploadHeaders: {
-            Authorization: 'Bearer ' + this.$store.state.user.token,
-        },
-        tableData: [],
-        showFormDialog: false, // 显示form表单
-        form: {
-            sort: 0, // 默认排序
-        }, // 
-        rules: {
-            name: [
-                { required: true, message: '请输入楼层名称', trigger: 'blur' },
-                { required: true, message: '请输入楼层名称', trigger: 'change' },
-                { min: 1, max: 50, message: '长度在 1 到 50 个字符', trigger: 'blur' },
-            ],
-        }, // 验证规则
-        // imageUrl: '',
-        imageList: [], // 图片数据
-      }
-    },
-    methods: {
-        /**
-         * 图片文件
-         */
-        getUploadImages(files) {
-            if (files.length) {
-                this.form.drawing_path = files[0].url;
-            } else {
-                this.form.drawing_path = '';
-            }
-        },
-        afterGetList(){
-            this.tableData = this.data
-        },
-        // 提交表单
-        submitForm() {
-            if (!this.form.name) {
-                this.$message.error('请输入楼层名称');
-                return;
-            }
-            if (!this.form.id) {
-                this.form.school_id = this.buildingInfo.school_id;
-                this.form.building_id = this.buildingInfo.id;
-                this.form.longitude = this.buildingInfo.longitude;
-                this.form.latitude = this.buildingInfo.latitude;
-
-                this.$http.post('kqFloor', this.form)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message.success('添加成功')
-                                    this.showFormDialog = false
-                                }
-                            })
-            } else { // 修改操作,删除不必要字段
-                this.$delete(this.form, 'latitude')
-                this.$delete(this.form, 'longitude')
-                this.$delete(this.form, 'school_id')
-                this.$delete(this.form, 'creator_id')
-                this.$delete(this.form, 'created_at')
-                this.$delete(this.form, 'updated_at')
-                this.$delete(this.form, 'deleted_at')
-
-                this.$http.put('kqFloor/'+ this.form.id, this.form)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message.success('修改成功')
-                                    this.showFormDialog = false
-                                }
-                            })
-            }
-
-        },
-        onFormDialogClosed() {
-            // 关闭弹窗时重置form
-            this.form = {
-                sort: 0
-            }
-            // 去除照片
-            // this.imageUrl = ''
-            // 刷新数据
-            this.handleRefresh()
-        },
-        // 修改楼层
-        updateInfo(info) {
-            this.form = info
-            this.showFormDialog = true
-            this.imageUrl = [{
-                name: info.drawing_path.slice(info.drawing_path.lastIndexOf('/') + 1),
-                url: info.drawing_path,
-            }]
-        },
-        // 删除楼层
-        deleteFloor(id) {
-            this.$confirm('确定要删除吗?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-            }).then(() => {
-                    this.$http.delete('kqFloor/' + id)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message({
-                                        type: 'success',
-                                        message: '删除成功!'
-                                    });
-                                    this.handleRefresh()
-                                }
-                            }).catch(() => {})
-
-            }).catch(() => {});
-        },
-        // 上传成功回调
-        onUploadSuccess(res, file) {
-            if (res.code !== 10000) {
-                this.$message.error('上传失败,只支持 jpg 和 png 格式');
-                return false;
-            }
-            this.form.drawing_path = res.data;
-            this.imageUrl = URL.createObjectURL(file.raw);
-        },
-        // 上传前
-        beforeUpload(file) {
-            const isTrueFormat = (file.type === 'image/jpeg' || file.type === 'image/png');
-            const isLt2M = file.size / 1024 / 1024 < 2;
-
-            if (!isTrueFormat) {
-            this.$message.error('上传头像图片只能是 JPG 格式!');
-            }
-            if (!isLt2M) {
-            this.$message.error('上传头像图片大小不能超过 2MB!');
-            }
-            return isTrueFormat && isLt2M;
-        },
-        closeDialog() {
-            this.showFormDialog = false
-        },
-    },
-  }
-</script>
-<style lang="scss" scoped>
-    .el-select { width: 100%; }
-
-    .table-footer {
-        margin-top: 10px;
-
-        .table-pagination {
-            float: right;
-        }
-    }
-
-    ::v-deep .avatar-uploader .el-upload {
-        border: 1px dashed #d9d9d9;
-        border-radius: 6px;
-        cursor: pointer;
-        position: relative;
-        overflow: hidden;
-    }
-    ::v-deep .avatar-uploader .el-upload:hover {
-        border-color: #409EFF;
-    }
-    ::v-deep .avatar-uploader-icon {
-        font-size: 28px;
-        color: #8c939d;
-        width: 178px;
-        height: 178px;
-        line-height: 178px;
-        text-align: center;
-    }
-    ::v-deep .avatar {
-        width: 178px;
-        height: 178px;
-        display: block;
-    }
-</style>

+ 0 - 644
src/views/wind/wind/floor/map.vue

@@ -1,644 +0,0 @@
-<template>
-    <div class="app-container">
-        <!-- 平面图 -->
-        <div class="floorMap" :id="mapId"></div>
-        <!-- 右侧列表 -->
-        <div id="floorMapPanel">
-
-            <!-- 左侧:楼层 -->
-            <div id="floorList">
-                <el-tooltip content="展开/收起" placement="left" effect="light" enterable>
-                    <el-button type="text" id="toggleStationList" :icon="'el-icon-d-arrow-' + toggleIcon" style="font-size: 20px;"></el-button>
-                </el-tooltip>
-
-                <p>楼层</p>
-                
-                <el-button type="text" id="scrollUp" icon="el-icon-caret-top"></el-button>
-                <ul id="floorUl">
-                    <li v-for="(floor,index) in floorList" :key="index" :class="currentFloorInfo.id == floor.id ? 'actived' : ''" @click="changeFloor(floor, $event)">{{ floor.name }}</li>
-                </ul>
-                <!-- 向下翻页 -->
-                <el-button type="text" id="scrollDown" icon="el-icon-caret-bottom"></el-button>
-                <!-- 添加插座 -->
-                <el-tooltip content="点击此按钮后,再点击平面图上要安装的位置添加插座" effect="light" placement="left" enterable>
-                    <el-button type="text" id="addStationBtn" icon="el-icon-add-location" @click="addStation"></el-button>
-                </el-tooltip>
-            </div>
-            
-            <!-- 右侧:插座列表 -->
-            <div id="stationList">
-                <!-- 标题 -->
-                <div id="stationTitle">插座列表</div>
-                <div id="stationBody">
-                    <el-table
-                        @row-click="rowClick"
-                        :data="stationList"
-                        style="width: 100%"
-                        height="450">
-                        <el-table-column
-                            type="index"
-                            label="序号"
-                            align="center"
-                            width="50"
-                        />
-                        <el-table-column
-                            prop="room_no"
-                            label="房间号"
-                            align="center"
-                            width="66">
-                        </el-table-column>
-                        <el-table-column
-                            prop="station_mac"
-                            label="设备MAC"
-                            align="center"
-                            width="133">
-                        </el-table-column>
-                        <el-table-column
-                            prop="online_time"
-                            label="在线时间"
-                            align="center"
-                            sortable
-                            width="133">
-                        </el-table-column>
-                        <el-table-column
-                            fixed="right"
-                            label="操作"
-                            align="center"
-                            width="66">
-                            <template slot-scope="scope">
-                                <el-tooltip content="修改" placement="top" effect="light" enterable>
-                                    <el-button type="text" id="scrollUp" icon="el-icon-edit" @click="editStation(scope.row)"></el-button>
-                                </el-tooltip>
-                                <el-tooltip content="删除" placement="top" effect="light" enterable>
-                                    <el-button type="text" id="scrollUp" icon="el-icon-delete" @click="deleteStation(scope.row.id)"></el-button>
-                                </el-tooltip>
-                            </template>
-                        </el-table-column>
-                    </el-table>
-                </div>
-                <div id="stationFooter">
-                    <!-- <el-pagination
-                        small
-                        layout="prev, pager, next"
-                        :total="50">
-                    </el-pagination> -->
-                </div>
-            </div>
-
-        </div>
-        <el-dialog title="插座信息" :visible.sync="showForm" append-to-body>
-            <el-form :model="formData" status-icon :rules="rules" ref="floorForm" label-width="100px">
-                <el-form-item label="房间号" prop="room_no">
-                    <el-input v-model="formData.room_no" placeholder="请输入设备安装房间号"></el-input>
-                </el-form-item>
-                <el-form-item label="设备MAC" prop="station_mac" required>
-                    <el-input type="text" v-model="formData.station_mac" placeholder="请输入设备MAC编号" ></el-input>
-                </el-form-item>
-                <el-form-item label="设备名称" prop="station_name" required>
-                    <el-input type="text" v-model="formData.station_name" placeholder="请输入设备名称" ></el-input>
-                </el-form-item>
-
-                <el-form-item label="横向坐标" prop="coordinate_x" required>
-                    <el-input v-model="formData.coordinate_x" placeholder="请输入设备在房间的横向坐标位置(取值范围:0~500)"></el-input>
-                </el-form-item>
-                <el-form-item label="纵向坐标" prop="coordinate_y" required>
-                    <el-input v-model="formData.coordinate_y" placeholder="请输入设备在房间的纵向坐标位置(取值范围:-374~0)"></el-input>
-                </el-form-item>
-
-                <el-form-item>
-                    <el-button type="primary" @click="submitForm">提交</el-button>
-                    <el-button @click="cancelSubmit">取消</el-button>
-                </el-form-item>
-            </el-form>
-        </el-dialog>
-    </div>
-</template>
-
-<script>
-import L from "leaflet/dist/leaflet-src.js";
-import "leaflet/dist/leaflet.css";
-import { addClass, removeClass } from "@/utils/index.js"
-
-L.Icon.Default.prototype.options.imagePath = '/icons/';
-
-export default {
-    props: {
-        buildingId: {
-            type: [Number,String],
-            required: true
-        },
-        studentId: {
-            type: [Number,String],
-            // default: 83
-        }
-    },
-    watch: {
-        buildingId: function(val) {
-            this.clearData()
-            
-            this.bid = val
-            this.getFloorList()
-        },
-        studentId: function(val) {
-            this.currentStudentId = val
-        }
-    },
-    data() {
-        return {
-            mapId: 'floorMap' + Math.random(), // 防止id重复
-            bid: this.buildingId, // 建筑id
-            currentStudentId: this.studentId, // 当前学生id
-            studentMarker: null,
-            floorList: [], // 楼层数据
-            stationList: [], // 基站数据
-            currentFloorInfo: {}, // 当前楼层信息
-            currentStudentInfo: {}, // 当前学生信息
-            lmap: null, // leaflet map object
-            markersLayer: null, // 覆盖物群组
-            imageObj: null, // 图片覆盖物对象
-            defaultImageUrl: '/icons/picture-outline.png',
-            studentImageUrl: '/icons/student_alarm.png',
-            toggleIcon: 'left',
-            showForm: false, // 显示添加/修改表单
-            formData: {}, // 表单数据
-            rules: {
-                station_mac: [
-                    { required: true, message: '请输入设备MAC编号', trigger: 'blur' },
-                    { required: true, message: '请输入设备MAC编号', trigger: 'change' },
-                    // { min: 6, max: 20, message: '长度在 6 到 20 个字符', trigger: 'blur' }
-                ],
-                station_name: [
-                    { required: true, message: '请输入设备名称', trigger: 'blur' },
-                    { required: true, message: '请输入设备名称', trigger: 'change' },
-                    { min: 2, max: 50, message: '长度在 2 到 50 个字符', trigger: 'blur' }
-                ],
-                coordinate_x: [
-                    { required: true, message: '请输入设备在房间的横向坐标位置', trigger: 'blur' },
-                    { required: true, message: '请输入设备在房间的横向坐标位置', trigger: 'change' },
-                ],
-            }
-        }
-    },
-    created() {
-        if (this.studentId) {
-            // 学生定位
-            this.initStudentLocation()
-        } else {
-            // 获取楼层数据
-            this.getFloorList()
-        }
-    },
-    mounted() {
-        this.$nextTick(() => {
-            this.initMap()
-        });
-
-        var that = this;
-        // 楼层滚动
-        var scrollUp = document.getElementById('scrollUp')
-        var scrollDown = document.getElementById('scrollDown')
-        var floorUl = document.getElementById('floorUl')
-        scrollUp.onclick = function(e) {
-            floorUl.scrollTop -= 300
-        }
-        scrollDown.onclick = function(e) {
-            floorUl.scrollTop = floorUl.scrollTop + 300
-        }
-        // 显示隐藏插座列表
-        var stationListElem = document.getElementById('stationList')
-        var toggleStationListElem = document.getElementById('toggleStationList')
-        toggleStationListElem.onclick = function(e){
-            if (stationListElem.style.display === 'none' || !stationListElem.style.display) {
-                stationListElem.style.display = 'block';
-                that.toggleIcon = 'right';
-            } else {
-                stationListElem.style.display = 'none'
-                that.toggleIcon = 'left';
-            }
-        }
-    },
-    methods: {
-        /**
-         * 平面图
-         */
-        initMap() {
-            // this.lmap = L.map('floorMap', {
-            this.lmap = L.map(this.mapId, {
-                minZoom: 1,
-                maxZoom: 4,
-                center: [0, 0],
-                zoom: 1,
-                crs: L.CRS.Simple,
-                drawControl: true, // 使用draw
-            });
-            // 隐藏右下角的控制栏
-            this.lmap.attributionControl.remove()
-            // 图片参数
-            var w = 4000,
-                h = 3000,
-                url = this.currentFloorInfo.drawing_path || this.defaultImageUrl;
-            // calculate the edges of the image, in coordinate space
-            var southWest = this.lmap.unproject([0, h], this.lmap.getMaxZoom()-1);
-            var northEast = this.lmap.unproject([w, 0], this.lmap.getMaxZoom()-1);
-            var bounds = new L.LatLngBounds(southWest, northEast);
-            // 添加图片覆盖物
-            this.imageObj = L.imageOverlay(url, bounds);
-            this.imageObj.addTo(this.lmap)
-            // tell leaflet that the map is exactly as big as the image
-            this.lmap.setMaxBounds(bounds);
-            // 初始化覆盖物群组
-            this.markersLayer = L.layerGroup()
-        },
-        // 学生定位
-        initStudentLocation() {
-            // 获取学生室内基站信息
-            this.$http.get('student/getIndoorStationInfo/' + this.currentStudentId)
-                    .then( resp => {
-                        if (resp.code === 10000) {
-                            this.currentStudentInfo = resp.data
-                            // 先获取学生信息再获取楼层信息(需要用到学生最后经过基站的楼层)
-                            this.getFloorList()
-                        }
-                    })
-        },
-        // 添加基站
-        addStation() {
-            if (!this.lmap) {
-                this.$message.warning('图片加载错误,请关闭重新打开')
-                return;
-            }
-            var that = this;
-            // 修改鼠标样式
-            // L.DomUtil.addClass(this.lmap._container,'leaflet-cursor-Crosshair');
-            // 添加点击事件
-            this.lmap.once('click', function(e) {
-                if (!that.currentFloorInfo.drawing_path) {
-                    that.$message.error('请先上传楼层图片')
-                    return;
-                }
-                that.formData = {
-                    coordinate_x: e.latlng.lng,
-                    coordinate_y: e.latlng.lat,
-                    school_id: that.currentFloorInfo.school_id,
-                    building_id: that.currentFloorInfo.building_id,
-                    floor_id: that.currentFloorInfo.id,
-                }
-                that.showForm = true
-            })
-        },
-        // 获取楼层数据
-        getFloorList() {
-            if (!this.bid) {
-                this.$message.warn('获取楼层数据失败')
-                return;
-            }
-            this.$http.get('kqFloor/getBuildingFloorData/'+ this.bid)
-                    .then(resp => {
-                        this.floorList = []
-                        if (resp.code === 10000) {
-                            this.floorList = resp.data
-                            let len = this.floorList.length;
-                            // 无楼层数据
-                            if (!len) {
-                                return;
-                            }
-                            this.currentFloorInfo = null
-                            // 如果有学生信息存在,定位到学生所在楼层
-                            if (this.currentStudentInfo && this.currentStudentInfo.floor_id) {
-                                this.floorList.forEach(item => {
-                                    if (this.currentStudentInfo.floor_id == item.id) {
-                                        this.currentFloorInfo = item
-                                    }
-                                })
-                                if (!this.currentFloorInfo) {
-                                    this.currentFloorInfo = this.floorList[this.floorList.length - 1]
-                                }
-                            
-                            } else { // 默认选择最底层
-                                this.currentFloorInfo = this.floorList[this.floorList.length - 1]
-                            }
-
-                            this.imageObj.setUrl(this.currentFloorInfo.drawing_path || this.defaultImageUrl)
-                            this.getStationList(this.currentFloorInfo.id)
-                            
-                            this.$nextTick(() => {
-                                // 目前容器内只能显示10层,超过10层要将容器的滚动到最底层
-                                let floorUl = document.getElementById('floorUl')
-                                    floorUl.scrollTo(0, floorUl.scrollHeight)
-                            })
-                        }
-
-                    }).catch(()=>{})
-        },
-        // 切换楼层
-        changeFloor(info, event) {
-            this.currentFloorInfo = info
-            // 换底图
-            this.imageObj.setUrl(info.drawing_path || this.defaultImageUrl)
-            // 换插座数据
-            this.getStationList(info.id)
-            // 按钮样式
-            // addClass(event.target, 'actived')
-            // 移除其他同胞元素样式
-            this.removeSiblingsClass(event.target, 'actived')
-        },
-        // 移除同胞元素样式
-        removeSiblingsClass(el, cls) {
-            var _el = el;
-            // 前
-            while (el = el.previousSibling) {
-                removeClass(el, cls)
-            } 
-            // 后
-            var el = _el;
-            while (el = el.nextSibling) {
-                removeClass(el, cls)
-            }
-        },
-        // 获取插座数据
-        getStationList(fid) {
-            if (!fid) {
-                let len = this.floorList.length
-                if (!len) {
-                    this.stationList = [];
-                    return false;
-                }
-                fid = this.floorList[len - 1]; // 默认排序最小层
-            }
-            this.$http.get('station', {params: {floor_id: fid}})
-                    .then(resp => {
-                        this.stationList = []
-                        // 清空地图覆盖物
-                        this.markersLayer.clearLayers();
-                        // 清除学生覆盖物
-                        this.studentMarker && this.studentMarker.remove()
-                        
-                        if (resp.code === 10000) {
-                            this.stationList = resp.data || []
-                            // 添加覆盖物
-                            this.addMultiMarkers()
-                        }
-                    }).catch(()=>{})
-        },
-        // 添加多覆盖物
-        addMultiMarkers() {
-            if (!this.lmap) {
-                this.initMap()
-            }
-            this.stationList.forEach(item => {
-                if (!item.coordinate_x || !item.coordinate_y) {
-                    return false;
-                }
-                let latlng = L.latLng(item.coordinate_y, item.coordinate_x);
-                // 单个添加
-                this.addMarker(latlng, item)
-                // 如果有学生
-                if (this.currentStudentInfo && this.currentStudentInfo.station_mac == item.station_mac) {
-                    let lng = parseFloat(item.coordinate_x) + 1.5,
-                        lat = item.coordinate_y,
-                        stuIcon = L.icon({
-                            iconUrl: '/icons/student_alarm.png',
-                            iconSize: [16, 16],
-                        }),
-                        content = [
-                            '<b>姓名:</b>' + this.currentStudentInfo.student_name,
-                            '<b>性别:</b>' + this.currentStudentInfo.sex,
-                            '<b>年龄:</b>' + this.currentStudentInfo.age,
-                            '<b>电话:</b>' + this.currentStudentInfo.phone,
-                            '<b>在线时间:</b>' + this.currentStudentInfo.online_time,
-                        ]
-                    this.studentMarker = L.marker(L.latLng(lat, lng), {icon: stuIcon}).addTo(this.lmap);
-                    this.studentMarker.bindPopup(content.join('<br/>')).openPopup();
-                }
-            })
-        },
-        // 添加单个覆盖物
-        addMarker(latlng, info) {
-            var myIcon = L.icon({
-                    iconUrl: '/icons/chazuo.png',
-                    iconSize: [24, 24],
-                });
-            var marker = L.marker(latlng, {icon: myIcon, draggable: true, title: info.room_no}).addTo(this.lmap);
-                // 将点信息保存
-                marker._infoData = info;
-                // 信息窗
-                marker.bindPopup(`<b>房间号:</b> ${info.room_no || ''}<br><b>设备名称:</b> ${info.station_name}<br><b>设备MAC:</b> ${info.station_mac}`);
-                // 移动事件
-                marker.on('moveend', (e) => {
-                    this.onMarkerMoved(e.target)
-                })
-                // 存入群组
-                this.markersLayer.addLayer(marker).addTo(this.lmap)
-        },
-        // 移动覆盖物
-        onMarkerMoved(marker) {
-            var info = marker._infoData
-
-            this.$confirm('确定要移动到当前位置吗?', '移动设备位置', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-            }).then(() => {
-                    var data = {
-                        coordinate_x: marker._latlng.lng,
-                        coordinate_y: marker._latlng.lat,
-                    }
-                    this.$http.put('indoorStation/updateLocation/' + info.id, data)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message({
-                                        type: 'success',
-                                        message: resp.message
-                                    });
-                                    // 重新获取基站数据
-                                    this.getStationList(this.currentFloorInfo.id)
-                                }
-                            }).catch(() => {})
-
-            }).catch(() => {
-                marker.setLatLng(L.latLng(info.coordinate_y, info.coordinate_x))
-            })
-        },
-        // 提交表单
-        submitForm() {
-            // 检测
-            this.$refs.floorForm.validate((valid) => {
-                if (!valid) {
-                    return false;
-                }
-                if (this.formData.id) {
-                    // 修改
-                    this.$http.put('indoorStation/'+ this.formData.id, this.formData)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message.success(resp.message)
-                                    this.getStationList(this.currentFloorInfo.id)
-
-                                    this.showForm = false
-                                }
-                            }).catch(() => {})
-                } else {
-                    // 添加
-                    this.$http.post('indoorStation', this.formData)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message.success(resp.message)
-                                    this.getStationList(this.currentFloorInfo.id)
-                                    this.showForm = false
-                                }
-                            }).catch(() => {})
-                }
-            })
-        },
-        // 取消
-        cancelSubmit() {
-            this.showForm = false
-        },
-        // 表格中选中设备时
-        rowClick(row, col, e) {
-            // 显示覆盖物弹窗
-            var layers = this.markersLayer.getLayers();
-            layers.length && layers.forEach(item => {
-                if (!item._infoData) {
-                    return;
-                }
-                if (row.id == item._infoData.id) {
-                    item.openPopup()
-                }
-            })
-        },
-        // 修改基站
-        editStation(info) {
-            console.log('editStation',info);
-            // this.formData = info
-            this.formData = {
-                id: info.id,
-                room_no: info.room_no,
-                station_mac: info.station_mac,
-                station_name: info.station_name,
-                coordinate_x: info.coordinate_x,
-                coordinate_y: info.coordinate_y,
-            }
-            this.showForm = true
-        },
-        // 删除楼层
-        deleteStation(id) {
-            this.$confirm('确定要删除吗?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-            }).then(() => {
-                    this.$http.delete('indoorStation/' + id)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message({
-                                        type: 'success',
-                                        message: '删除成功!'
-                                    });
-                                    // 重新获取基站数据
-                                    this.getStationList(this.currentFloorInfo.id)
-                                }
-                            }).catch(() => {})
-
-            }).catch(() => {});
-        },
-        // 清除数据
-        clearData() {
-            this.floorList = []
-            this.stationList = []
-            this.currentFloorInfo = []
-            this.currentStudentInfo = []
-
-            this.imageObj.setUrl(this.defaultImageUrl)
-            this.markersLayer && this.markersLayer.clearLayers()
-        },
-
-    },
-  }
-</script>
-<style lang="scss" scoped>
-    .app-container {
-        .actived {
-            background-color: #63a8e0;
-            color: #ffffff;
-        }
-
-        ::v-deep .floorMap {
-            width: 100%;
-            min-width: 500px;
-            height: 100%;
-            min-height: 500px;
-            border: 1px solid #bbb;
-        }
-
-        #floorMapPanel {
-            display: flex;
-            position: absolute;
-            top: 100px;
-            right: 45px;
-            background-color: #ffffff;
-            box-shadow: 0 2px 6px 0 rgb(27 142 236 / 50%);
-            z-index: 10000;
-            // width: 440px;
-            height: 500px;
-
-            #floorList {
-                text-align: center;
-                width: 40px;
-                height: 100%;
-                border-right: 1px dashed #9e9e9e;
-                ul {
-                    height: 300px;
-                    list-style: none;
-                    overflow: hidden;
-                    padding: 0;
-                    margin: 0;
-                    li {
-                        width: 40px;
-                        line-height: 30px;
-                        cursor: pointer;
-                    }
-                    li:hover {
-                        background-color: #63a8e0;
-                        color: #ffffff;
-                    }
-                }
-
-                #addStationBtn {
-                    display: block;
-                    text-align: center;
-                    font-size: 20px;
-                    padding: 0;
-                    margin: 0;
-                    width: 100%;
-                }
-            }
-
-            #stationList {
-                display: none;
-                width: 450px;
-                height: 100%;
-                #stationTitle {
-                    line-height: 35px;
-                    font-weight: 500;
-                    font-size: 18px;
-                    text-align: center;
-                    border-bottom: 1px dashed #ccc;
-                }
-                #stationBody {
-                    font-size: 14px;
-                    line-height: 33px;
-                    text-align: center;
-                    height: 433px;
-                }
-                .stationListHead {
-                    background-color: #cfeff8;
-                }
-
-                #stationFooter {
-                    text-align: center;
-                }
-            }
-        }
-    }
-</style>

+ 0 - 247
src/views/wind/wind/form/AddEditWind.vue

@@ -1,247 +0,0 @@
-<template>
-  <div class="drawer-content">
-    <el-form :ref="formName" :rules="rules" :model="form" label-width="150px">
-      <el-form-item label="风场名称" prop="name">
-        <el-input v-model="form.name" :disabled="is_disabled"></el-input>
-      </el-form-item>
-      <el-form-item label="风场编号" required prop="number">
-        <el-input v-model="form.number" :disabled="is_disabled"></el-input>
-      </el-form-item>
-      <el-form-item label="风场类型" required prop="wind_type">
-        <el-select v-model="form.wind_type" filterable placeholder="请选择风场类型">
-          <el-option v-for="item in windTypeData" :key="item.value" :label="item.text" :value="item.value">
-          </el-option>
-        </el-select>
-      </el-form-item>
-      <el-form-item label="所属部门" required prop="department_id">
-        <el-cascader class="filter-item form-search-input fl" placeholder="请选择所属部门" :options="departmentData"
-          v-model="form.department_id" :show-all-levels="false" :props="departProps" filterable clearable></el-cascader>
-      </el-form-item>
-      <el-form-item label="环境类型" required prop="env_type">
-        <el-select v-model="form.env_type" filterable placeholder="请选择环境类型">
-          <el-option v-for="item in EnvTypeData" :key="item.value" :label="item.text" :value="item.value">
-          </el-option>
-        </el-select>
-      </el-form-item>
-      <el-form-item label="所属区域" prop="area_id" placeholder="请选择所属区域">
-        <regionals style="width: 85%" ref="regionals" class="filter-item fl" appendToBody @checked="selectArea"
-          :defaultCheckedKeys="defaultCheckedKeys" />
-      </el-form-item>
-      <el-form-item label="详细地址" prop="address">
-        <el-input v-model="form.address"></el-input>
-      </el-form-item>
-      <el-form-item label="风场边颜色" prop="side_color">
-        <el-color-picker v-model="form.side_color"></el-color-picker>
-      </el-form-item>
-      <el-form-item label="风场内颜色" prop="inside_color">
-        <el-color-picker v-model="form.inside_color"></el-color-picker>
-      </el-form-item>
-      <el-form-item label="海拔高度" prop="altitude">
-        <el-input v-model="form.altitude"></el-input>
-      </el-form-item>
-      <el-form-item label="主机制造商" required prop="env_type">
-        <el-select v-model="form.host_firm" filterable placeholder="主机制造商">
-          <el-option v-for="item in HostTypeData" :key="item.value" :label="item.text" :value="item.value">
-          </el-option>
-        </el-select>
-      </el-form-item>
-      <el-form-item label="备注" prop="remark">
-        <el-input type="textarea" v-model="form.remark"></el-input>
-      </el-form-item>
-    </el-form>
-
-    <div class="drawer-footer">
-      <el-button @click="closeDialog">关闭</el-button>
-      <el-button type="primary" @click="submitForm">提交</el-button>
-    </div>
-  </div>
-</template>
-<script>
-import { deepClone } from "@/utils/index";
-import Regionals from "@/components/Cascader/Regionals";
-export default {
-  name: "AddEditWind",
-  components: { Regionals },
-  props: {
-    formName: {
-      type: String,
-      default: "windForm",
-    },
-
-    formData: {
-      type: Object,
-      default: function () {
-        return {};
-      },
-    },
-  },
-  data: function () {
-    var validQC = (rule, value, callback) => {
-
-      if (value) {
-        if (/[\u4E00-\u9FA5]/g.test(value)) {
-          callback(new Error("不能输入汉字"));
-        } else {
-          // 验证通过
-          callback();
-        }
-        callback();
-      }
-    };
-    return {
-      departmentData: [],
-      departProps: {
-        label: "department_name",
-        value: "id",
-        checkStrictly: true,
-      },
-      is_disabled:false,
-      windTypeData: [],
-      defaultCheckedKeys:[],
-      EnvTypeData:[],
-      HostTypeData:[],
-      rules: {
-        name: [
-          { required: true, message: "请输入风场名称", trigger: "blur" },
-          { required: true, message: "请输入风场名称", trigger: "change" },
-          {
-            min: 2,
-            max: 20,
-            message: "长度在 2 到 20 个字符",
-            trigger: "blur",
-          },
-        ],
-        department_id: [
-          { required: true, message: "请选择所属部门", trigger: "blur" },
-          { required: true, message: "请选择所属部门", trigger: "change" },
-        ],
-        //风场编号
-        number: [
-          { validator: validQC, trigger: 'blur' }
-          
-        ],
-        address: [
-          { required: true, message: "请输入风场地址", trigger: "blur" },
-          { required: true, message: "请输入风场地址", trigger: "change" },
-        ],
-      },
-
-    };
-  },
-  created() {
-   
-    this.getDepartmentData();
-    this.$http.post("sysDictData/getOptions", { type: "WindType" }).then(resp => {
-        this.windTypeData = resp.data
-    });
-    this.$http.post("sysDictData/getOptions", { type: "EnvironmentType" }).then(resp => {
-        this.EnvTypeData = resp.data
-    });
-    this.$http.post("sysDictData/getOptions", { type: "HostManufacturer" }).then(resp => {
-        this.HostTypeData = resp.data
-    });
-    
-    
-  },
-  computed: {
-    form: {
-      get() {
-        if (this.formData.id)
-        {
-          this.is_disabled = true;
-        }
-        return this.formData;
-      },
-      set(val) {
-      },
-    },
-  },
-  watch: {
-    formData(val) {
-      this.form = val;
-    },
-  },
-  methods: {
-    // 获取部门数据
-    getDepartmentData() {
-      this.$http.get("departments").then((resp) => {
-          if (resp.code === 10000) {
-            this.departmentData = resp.data || [];
-          }
-        }).catch(() => {});
-    },
-    submitForm() {
-      console.log(this.defaultCheckedKeys)
-      // 检测
-      this.$refs[this.formName].validate((valid) => {
-        if (!valid) {
-          return false;
-        }
-        if(!this.defaultCheckedKeys){
-          this.$message.error("请选择地区");
-          return false;
-        }
-        if (this.form.id) {
-          //禁止修改风场名称和风场编号
-          // 修改操作
-          var saveData = {
-            name: this.form.name,
-            wind_shape: this.form.wind_shape,
-            wind_info: this.form.wind_info,
-            department_id: this.form.department_id,
-            address: this.form.address,
-            remark: this.form.remark,
-            inside_color: this.form.inside_color,
-            side_color: this.form.side_color,
-            number:this.form.number
-          };
-          this.$http.put("wind/" + this.form.id, saveData).then((resp) => {
-            if (resp.code != 10000) {
-              return false;
-            }
-            this.$message.success("修改成功");
-            // 返回结果
-            this.$emit("result", { success: true, data: this.form });
-          });
-        } else {
-          var addData = deepClone(this.form);
-          // 添加操作
-          this.$http.post("wind", addData).then((resp) => {
-            if (resp.code != 10000) {
-              return false;
-            }
-            this.$message.success("添加成功");
-            this.form.id = resp.data;
-            // 返回结果
-            this.$emit("result", { success: true, data: this.form });
-          });
-        }
-      });
-    },
-    closeDialog() {
-      this.$parent.handleClose();
-    },
-    selectArea(val) {
-      this.defaultCheckedKeys = val.fullKeys
-    },
-  },
-};
-</script>
-<style lang="scss" scoped>
-.el-drawer span:focus {
-  outline: none;
-}
-.drawer-content {
-  form {
-    .el-input,
-    .el-cascader,
-    .el-select {
-      width: 350px;
-    }
-  }
-  .drawer-footer {
-    display: flex;
-    justify-content: flex-end;
-  }
-}
-</style>

+ 0 - 205
src/views/wind/wind/index.scss

@@ -1,205 +0,0 @@
-.app-container {
-    height: calc(100vh - 100px);
-    margin: 5px;
-    padding: 5px;
-    // display: flex;
-    ::v-deep .el-dialog{
-        margin-top:5vh !important;
-    }
-    .bm-view {
-        display: inline-block;
-        width: calc(100% - 500px);
-        // min-width: 600px;
-        height: 100vh;
-
-        ::v-deep .BMap_bubble_content {
-            font-size: 14px;
-        }
-        .autoAddressClass{
-            li {
-              i.el-icon-search {margin-top:11px;}
-              .mgr10 {margin-right: 10px;}
-              .title {
-                text-overflow: ellipsis;
-                overflow: hidden;
-              }
-              .address {
-                line-height: 1;
-                font-size: 12px;
-                color: #b4b4b4;
-                margin-bottom: 5px;
-              }
-            }
-          }
-        
-    }
-
-    .searchType{
-        width:100px;
-    }
-    ::v-deep .searchType .el-input__inner{
-        height: 38px ;
-        border-radius: 0px;
-    }
-    ::v-deep .searchInput .el-input__inner{
-        height: 38px ;
-        border-radius: 0px;
-    }
-    .searchInput{
-        width:370px;
-        border-radius: 0px;
-        
-    }
-    #mapTipsBox{
-        margin-left: 100px;
-        border-radius: 5px;
-        background-color: #fff;
-        line-height: 32px;
-        padding: 5px 10px;
-        font-size: 14px;
-        color:#3895e5;
-    }
-    #rightPanel {
-        display: inline-block;
-        width: 500px;
-        height: 100vh;
-
-        #toggleListBtn {
-            position: absolute;
-            top: calc(50vh - 100px);
-            right: 510px;
-            background-color:#3895e5;
-            color:#fff;
-            height: 60px;
-            width:30px;
-            border-radius: 40px 0px 0px 40px;
-            text-align: left;
-            font-size: 20px;
-        }
-        ::v-deep .el-icon-d-arrow-right{
-            margin-left:-6px;
-        }
-        ::v-deep .el-icon-d-arrow-left{
-            margin-left:-6px;
-        }
-        #DistanceToolBtn{
-            position: absolute;
-            top: 20px;
-            left: 100px;
-            width:50px;
-            height: 22px;
-            line-height: 16px;
-            border: 1px solid #d64635;
-            background: #d64635;
-            color:white;
-            // font-size: 14px;
-            padding: 2px 6px;
-            font: bold 12px / 1.3em arial, sans-serif;
-            text-align: center;
-            white-space: nowrap;
-            border-radius: 3px 3px 3px 3px;
-        }
-        #saveWindBtn {
-            position: absolute;
-            top: 65px;
-            right: 510px;
-        }
-        #clearWindBtn {
-            position: absolute;
-            top: 110px;
-            right: 510px;
-        }
-
-        #tableTabs {
-            width: 100%;
-            height: 100%;
-            min-height: 500px;
-    
-            .el-tabs--border-card {
-                height: 100%;
-                
-                ::v-deep .el-tabs__content {
-                    padding: 0;
-                    height: calc(100% - 40px);
-                    overflow: auto;
-    
-                    .app-container {
-                        height: 100%;
-                    }
-                }
-            }
-    
-            ::v-deep .table-body {
-                width: 100%;
-            }
-        }
-    }
-
-
-    #normalCtrl {
-        // display: flex;
-        // flex-flow: column wrap-reverse;
-        inset: 40px auto auto 60px  !important;
-        #searchbox {width: 464px;position: relative;z-index: 5;display: flex;}
-        box-shadow: 1px 1px 9px 0px #8390bfc9;
-    }
-    #addBtns {
-        display: flex;
-        flex-flow: column;
-        width: 200px;
-        button {
-            margin: 0;
-        }
-        .add-btn-item {
-            display: flex;
-            align-items: center;
-            background-color: #fff;
-            // font-size: 12px !important;
-        }
-    }
-    #checkboxArea {
-        background-color: #fff;
-        line-height: 32px;
-        padding: 0 10px;
-    }
-    ::v-deep .win-btn {
-        margin-top: 20px;
-
-        button {
-            display: inline-block;
-            line-height: 1;
-            white-space: nowrap;
-            cursor: pointer;
-            background: #59b0c3;
-            border: 1px solid #DCDFE6;
-            border-color: #DCDFE6;
-            color: #ffffff;
-            -webkit-appearance: none;
-            text-align: center;
-            -webkit-box-sizing: border-box;
-            box-sizing: border-box;
-            outline: none;
-            margin: 0;
-            -webkit-transition: 0.1s;
-            transition: 0.1s;
-            font-weight: 400;
-            -moz-user-select: none;
-            -webkit-user-select: none;
-            -ms-user-select: none;
-            padding: 10px 20px;
-            font-size: 14px;
-            border-radius: 4px;
-        }
-    }
-
-    ::v-deep .dialog-no-padding .el-dialog__body {
-        padding: 0;
-    }
-
-    ::v-deep .fence-drawer {
-        min-width: 500px;
-    }
-    ::v-deep .el-drawer span:focus {
-        outline: none;
-    }
-}

文件差异内容过多而无法显示
+ 0 - 1046
src/views/wind/wind/index.vue


+ 0 - 233
src/views/wind/wind/table.vue

@@ -1,233 +0,0 @@
-<template>
-    <div class="app-container">
-        <div class="table-header">
-            <div class="tatble-toolbar">
-                <el-row style="float: right;margin: 5px 0;">
-                    <el-button type="primary" icon="el-icon-plus" v-if="showAddBtn" @click="addBuilding">添加建筑</el-button>
-                </el-row>
-            </div>
-        </div>
-        <div class="table-body">
-            <el-table
-                :data="tableData"
-                border
-                fit
-                @row-click="rowClick"
-                style="width: 100%">
-                <el-table-column
-                    fixed
-                    prop="name"
-                    label="建筑名称"
-                    align="center"
-                />
-                <el-table-column
-                    prop="school_name"
-                    label="所属部门"
-                    align="center"
-                />
-                <el-table-column
-                    prop="created_at"
-                    label="添加时间"
-                    align="center"
-                    width="130"
-                />
-                <el-table-column
-                    label="操作"
-                    align="center"
-                    fixed="right"
-                    width="100">
-                    <template slot-scope="scope">
-                        <el-tooltip content="楼层" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-coin" @click.stop="showFloorList(scope.row)"></el-button>
-                        </el-tooltip>
-                        <el-tooltip content="修改" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-edit" @click.stop="updateInfo(scope.row)"></el-button>
-                        </el-tooltip>
-                        <el-tooltip content="删除" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-delete" @click.stop="deleteBuilding(scope.row.id)"></el-button>
-                        </el-tooltip>
-                    </template>
-                </el-table-column>
-            </el-table>
-            <div class="table-pagination">
-                <el-pagination
-                    @size-change="handleSizeChange"
-                    @current-change="handleCurrentChange"
-                    :current-page="paginate.current"
-                    :page-sizes="paginate.sizes"
-                    :page-size="paginate.limit"
-                    layout="total, sizes, prev, pager, next, jumper"
-                    :total="paginate.total">
-                </el-pagination>
-            </div>
-        </div>
-        <div class="table-footer">
-        </div>
-
-        <!-- form 表单 -->
-        <el-dialog title="建筑信息" :visible.sync="showFormDialog" append-to-body destroy-on-close @closed="onFormDialogClosed" width="500px">
-            <el-form ref="floorForm" :rules="rules" :model="formData" label-width="80px">
-                <el-form-item label="建筑名称" required prop="name">
-                    <el-input v-model="formData.name" ></el-input>
-                </el-form-item>
-            </el-form>
-            <div slot="footer" class="dialog-footer">
-                <el-button @click="closeDialog">取 消</el-button>
-                <el-button type="primary" @click="submitForm">确 定</el-button>
-            </div>
-        </el-dialog>
-        <!-- 楼层列表 -->
-        <el-dialog :title="currentBuildingInfo.name" :visible.sync="visibleFloorList" append-to-body destroy-on-close fullscreen :custom-class="'dialog-no-padding'">
-            <floor-table ref="floor_table" :buildingInfo="currentBuildingInfo" />
-        </el-dialog>
-    </div>
-</template>
-
-<script>
-
-import rlListOperate from '@/layout/rl-list-operate/rlListOperate';
-import FloorTable from './floor/index';
-
-export default {
-    mixins: [ rlListOperate ],
-    components: { FloorTable },
-    props: {
-        schoolId: {
-            type: [String, Number],
-            // required: true
-        },
-        showAddBtn: {
-            type: Boolean,
-            default: true,
-        }
-    },
-    watch: {
-        schoolId: function(val) {
-            this.queryParam.school_id = val
-            this.getList({school_id: val})
-        },
-    },
-    data() {
-      return {
-        url: 'kqBuilding',
-        queryParam: {
-            school_id: this.schoolId
-        },
-        tableData: [],
-        showFormDialog: false, // 显示form表单
-        formData: {}, // 
-        rules: {
-            name: [
-                { required: true, message: '请输入楼层名称', trigger: 'blur' },
-                { min: 1, max: 50, message: '长度在 1 到 50 个字符', trigger: 'blur' }
-            ],
-        }, // 验证规则
-        imageUrl: '',
-        currentBuildingInfo: {}, // 当前建筑信息
-        visibleFloorList: false, // 显示楼层列表
-      }
-    },
-    methods: {
-        afterGetList(){
-            this.tableData = this.data
-        },
-        // 添加建筑
-        addBuilding() {
-            this.$router.push('/building/index')
-        },
-        // 提交表单
-        submitForm() {
-            if (this.formData.id) {
-                let saveData = {
-                    id: this.formData.id,
-                    name: this.formData.name,
-                }
-                this.$http.put('kqBuilding/'+ this.formData.id, saveData)
-                        .then(resp => {
-                            if (resp.code === 10000) {
-                                this.$message.success('修改成功')
-                                this.showFormDialog = false
-                                this.$emit('updateInfo', this.formData)
-                            }
-                        })
-            }
-        },
-        // 关闭表单弹窗
-        onFormDialogClosed() {
-            // 关闭弹窗时重置form
-            this.formData = {}
-            // 刷新数据
-            this.getList({school_id: this.queryParam.school_id})
-        },
-        // 修改楼层
-        updateInfo(info) {
-            this.formData = info
-            this.showFormDialog = true
-        },
-        // 删除楼层
-        deleteBuilding(id) {
-            this.$confirm('确定要删除吗?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-            }).then(() => {
-                    this.$http.delete('kqBuilding/' + id)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message({
-                                        type: 'success',
-                                        message: '删除成功!'
-                                    });
-                                    this.getList({school_id: this.queryParam.school_id})
-                                    this.$emit('afterDeleted', id)
-                                }
-                            }).catch(() => {})
-
-            }).catch(() => {});
-        },
-        // 
-        showFloorList(buildingInfo) {
-            this.currentBuildingInfo = buildingInfo
-            this.visibleFloorList = true
-        },
-        rowClick(row, column, event) {
-            this.$emit('rowClick', row)
-        },
-        closeDialog() {
-            this.showFormDialog = false
-        },
-    },
-}
-</script>
-<style lang="scss" scoped>
-    .el-select { width: 100%; }
-
-    .table-pagination {
-        margin-top: 10px;
-        text-align: right;
-    }
-
-    ::v-deep .avatar-uploader .el-upload {
-        border: 1px dashed #d9d9d9;
-        border-radius: 6px;
-        cursor: pointer;
-        position: relative;
-        overflow: hidden;
-    }
-    ::v-deep .avatar-uploader .el-upload:hover {
-        border-color: #409EFF;
-    }
-    ::v-deep .avatar-uploader-icon {
-        font-size: 28px;
-        color: #8c939d;
-        width: 178px;
-        height: 178px;
-        line-height: 178px;
-        text-align: center;
-    }
-    ::v-deep .avatar {
-        width: 178px;
-        height: 178px;
-        display: block;
-    }
-</style>

+ 0 - 170
src/views/wind/wind/table/PumpTable.vue

@@ -1,170 +0,0 @@
-<template>
-    <div class="app-container">
-        <el-input
-            v-model="queryParam.name"
-            placeholder="液压泵名称"
-            clearable
-            class="filter-item form-search-input fl"
-            @keyup.enter.native="handleSearch"
-          />
-          <el-input
-            v-model="queryParam.number"
-            placeholder="液压泵编号"
-            clearable
-            class="filter-item form-search-input fl"
-            @keyup.enter.native="handleSearch"
-          />
-
-          
-     
-        <el-button class="filter-item fl search" icon="el-icon-search" @click="handleSearch">
-            搜索
-        </el-button>
-
-        <div class="table-body">
-            <el-table
-                :data="tableData"
-                border
-                fit
-                @row-click="rowClick"
-                style="width: 100%">
-                 <el-table-column
-                   fixed
-                   label="序号"
-                    type="index"
-                    align="center"
-                    width="45"/>
-                   
-                <el-table-column
-                    fixed
-                    prop="name"
-                    label="液压泵名称"
-                    align="center"
-                />
-                <el-table-column
-                    fixed
-                    prop="number"
-                    label="液压泵编号"
-                    align="center"
-                />
-                <el-table-column
-                    fixed
-                    prop="online_time"
-                    label="在线时间"
-                    align="center"
-                />
-                <el-table-column
-                    label="操作"
-                    align="center"
-                    fixed="right"
-                    width="60">
-                    <template slot-scope="scope">
-                         <el-tooltip content="查看" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-view" @click.stop="showInfo(scope.row)"></el-button>
-                        </el-tooltip>
-
-                    </template>
-                </el-table-column>
-            </el-table>
-            <div class="table-pagination">
-                <el-pagination
-                    @size-change="handleSizeChange"
-                    @current-change="handleCurrentChange"
-                    :current-page="paginate.current"
-                    :page-sizes="paginate.sizes"
-                    :page-size="paginate.limit"
-                    layout="total, sizes, prev, pager, next, jumper"
-                    :total="paginate.total">
-                </el-pagination>
-            </div>
-        </div>
-        <div class="table-footer">
-        </div>
-
-        <!-- form 表单 -->
-
-        <!-- 围栏日志 -->
-        
-        <!-- <el-dialog title="围栏告警记录" :visible.sync="showAlarmDialog" append-to-body fullscreen>
-            <alarm-report-table :fenceId="currentFenceId" />
-        </el-dialog> -->
-
-    </div>
-</template>
-
-<script>
-
-import rlListOperate from '@/layout/rl-list-operate/rlListOperate';
-import FloorTable from '../floor/index';
-// import AlarmReportTable from '@/views/alarm/alarmReport';
-
-export default {
-    name: 'FenceTable',
-    mixins: [ rlListOperate ],
-    components: { 
-            FloorTable,
-            // AlarmReportTable
-         },
-    props: {
-    },
-    data() {
-      return {
-        url: 'hydraulic',
-        // showAlarmDialog: false,
-        // currentFenceId: null,
-        tableData: [],
-      }
-    },
-    methods: {
-        afterGetList(){
-            this.tableData = this.data
-        },
-        // 点击行
-        rowClick(row, column, event) {
-            this.$emit('rowClick', row)
-        },
-        showInfo(info){
-            this.$emit('showPumpDetail', info)
-        },
-        
-
-    },
-}
-</script>
-<style lang="scss" scoped>
-    .el-select { width: 100%; }
-
-    .table-pagination {
-        margin-top: 10px;
-        text-align: right;
-    }
-
-    ::v-deep .avatar-uploader .el-upload {
-        border: 1px dashed #d9d9d9;
-        border-radius: 6px;
-        cursor: pointer;
-        position: relative;
-        overflow: hidden;
-    }
-    ::v-deep .avatar-uploader .el-upload:hover {
-        border-color: #409EFF;
-    }
-    ::v-deep .avatar-uploader-icon {
-        font-size: 28px;
-        color: #8c939d;
-        width: 178px;
-        height: 178px;
-        line-height: 178px;
-        text-align: center;
-    }
-    ::v-deep .avatar {
-        width: 178px;
-        height: 178px;
-        display: block;
-    }
-    .form-search-input{
-        width:40%;
-        margin-right: 8px;
-        margin-bottom: 10px;
-    }
-</style>

+ 0 - 260
src/views/wind/wind/table/WindTable.vue

@@ -1,260 +0,0 @@
-<template>
-    <div class="app-container">
-        <div class="search-item fl">
-            <regionals
-               
-                ref="regionals"
-                style="width:40%;margin-right:10px;"
-                @checked="selectArea"
-                :defaultCheckedKeys="queryParam.citys"
-            />
-            <el-input
-                v-model="queryParam.number"
-                placeholder="风场编号/名称"
-                clearable
-                class="filter-item form-search-input"
-                @keyup.enter.native="handleSearch"
-            />
-            <el-select v-model="queryParam.wind_type"  class="filter-item form-select-input" filterable placeholder="风场类型">
-            <el-option
-                v-for="item in windTypeData"
-                :key="item.value"
-                :label="item.text"
-                :value="item.value">
-            </el-option>
-            </el-select>
-            <el-select v-model="queryParam.env_type"  class="filter-item form-select-input" filterable placeholder="环境类型">
-            <el-option
-                v-for="item in EnvTypeData"
-                :key="item.value"
-                :label="item.text"
-                :value="item.value">
-            </el-option>
-            </el-select>
-        </div>
-        <div class="search-operate-area fl">
-             <el-button class="filter-item search" icon="el-icon-search" @click="handleSearch">
-                搜索
-            </el-button>
-        </div>
-       
-        <div class="table-body">
-            <el-table
-                :data="tableData"
-                border
-                fit
-                @row-click="rowClick"
-                style="width: 100%">
-                 <el-table-column
-                   fixed
-                   label="序号"
-                    type="index"
-                    align="center"
-                    width="45"/>
-                   
-                <el-table-column
-                    fixed
-                    prop="name"
-                    label="风场名称"
-                    align="center"
-                     width="80"
-                />
-                  <el-table-column
-                    fixed
-                    prop="number"
-                    label="风场编号"
-                    align="center"
-                    width="70"
-                />
-                <el-table-column
-                    prop="address"
-                    label="风场地址"
-                    align="center"
-                />
-                <el-table-column
-                    label="操作"
-                    align="center"
-                    fixed="right"
-                    width="110">
-                    <template slot-scope="scope">
-            
-                        <el-tooltip content="修改信息" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-edit" @click.stop="updateInfo(scope.row)"></el-button>
-                        </el-tooltip>
-                         <el-tooltip content="修改区域" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-scissors" @click.stop="updateShapeInfo(scope.row)"></el-button>
-                        </el-tooltip>
-                         <el-tooltip content="查看" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-view" @click.stop="showInfo(scope.row)"></el-button>
-                        </el-tooltip>
-                        <el-tooltip content="删除" placement="top" :enterable="false">
-                            <el-button type="text" size="small" icon="el-icon-delete" @click.stop="deleteItem(scope.row.id)"></el-button>
-                        </el-tooltip>
-                    </template>
-                </el-table-column>
-            </el-table>
-            <div class="table-pagination">
-                <el-pagination
-                    @size-change="handleSizeChange"
-                    @current-change="handleCurrentChange"
-                    :current-page="paginate.current"
-                    :page-sizes="paginate.sizes"
-                    :page-size="paginate.limit"
-                    layout="total, sizes, prev, pager, next, jumper"
-                    :total="paginate.total">
-                </el-pagination>
-            </div>
-        </div>
-        <div class="table-footer">
-        </div>
-
-        <!-- form 表单 -->
-
-        <!-- 围栏日志 -->
-        
-        <!-- <el-dialog title="围栏告警记录" :visible.sync="showAlarmDialog" append-to-body fullscreen>
-            <alarm-report-table :fenceId="currentFenceId" />
-        </el-dialog> -->
-
-    </div>
-</template>
-
-<script>
-
-import rlListOperate from '@/layout/rl-list-operate/rlListOperate';
-import FloorTable from '../floor/index';
-// import AlarmReportTable from '@/views/alarm/alarmReport';
-import Regionals from "@/components/Cascader/Regionals";
-export default {
-    name: 'FenceTable',
-    mixins: [ rlListOperate ],
-    components: { 
-            FloorTable,
-            Regionals
-         },
-    props: {
-    },
-    data() {
-      return {
-        url: 'wind',
-        queryParam:{
-            citys:[],
-            number:'',
-        },
-        // showAlarmDialog: false,
-        // currentFenceId: null,
-        tableData: [],
-        windTypeData: [],
-        EnvTypeData:[],
-      }
-    },
-    mounted() {
-
-        this.$http.post("sysDictData/getOptions", { type: "WindType" }).then(resp => {
-            this.windTypeData = resp.data
-        });
-        this.$http.post("sysDictData/getOptions", { type: "EnvironmentType" }).then(resp => {
-            this.EnvTypeData = resp.data
-        });
-
-        
-        
-    },
-    methods: {
-        afterGetList(){
-            this.tableData = this.data
-        },
-        // 点击行
-        rowClick(row, column, event) {
-            this.$emit('rowClick', row)
-        },
-        // 修改
-        updateInfo(info) {
-            this.$emit('updateInfo', info)
-        },
-        updateShapeInfo(info) {
-            this.$emit('updateShapeInfo', info)
-        },
-        showInfo(info){
-            this.$emit('showWindDetail', info)
-        },
-        // 删除
-        deleteItem(id) {
-            this.$confirm('确定要删除吗?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-            }).then(() => {
-                    this.$http.delete('wind/' + id)
-                            .then(resp => {
-                                if (resp.code === 10000) {
-                                    this.$message({
-                                        type: 'success',
-                                        message: '删除成功!'
-                                    });
-                                    this.getList()
-                                    this.$emit('afterDeleted', id)
-                                }
-                            }).catch(() => {})
-
-            }).catch(() => {});
-        },
-        selectArea(val) {
-            this.queryParam.citys = val.fullKeys;
-        },
-        // alarmTable(id){
-        //     this.showAlarmDialog = true
-        //     this.currentFenceId = id
-        // },
-
-    },
-}
-</script>
-<style lang="scss" scoped>
-    .el-select { width: 100%; }
-
-    .table-pagination {
-        margin-top: 10px;
-        text-align: right;
-    }
-
-    ::v-deep .avatar-uploader .el-upload {
-        border: 1px dashed #d9d9d9;
-        border-radius: 6px;
-        cursor: pointer;
-        position: relative;
-        overflow: hidden;
-    }
-    ::v-deep .avatar-uploader .el-upload:hover {
-        border-color: #409EFF;
-    }
-    ::v-deep .avatar-uploader-icon {
-        font-size: 28px;
-        color: #8c939d;
-        width: 178px;
-        height: 178px;
-        line-height: 178px;
-        text-align: center;
-    }
-    ::v-deep .avatar {
-        width: 178px;
-        height: 178px;
-        display: block;
-    }
-    .search-item{ 
-        width: 80%;
-    }
-    .form-search-input{
-        width:50%;
-        margin-right: 8px;
-        margin-bottom: 10px;
-    }
-    .form-select-input{
-        width:45%;
-        margin-right: 8px;
-        margin-bottom: 10px;
-    }
-    .search-operate-area{
-        width:18%;
-    }
-</style>