liuyg
2021-07-16 f5641fd76ef90a66599e8ce121f3acfd97d779e8
样式
16 files modified
2757 ■■■■■ changed files
src/styles/element-ui.scss 45 ●●●●● patch | view | raw | blame | history
src/styles/ourBackgroundColor.scss 1 ●●●● patch | view | raw | blame | history
src/styles/theme/bule.scss 80 ●●●●● patch | view | raw | blame | history
src/views/animalHeat/animalHeat.vue 220 ●●●●● patch | view | raw | blame | history
src/views/article/article.vue 122 ●●●●● patch | view | raw | blame | history
src/views/attendance/attendance.vue 247 ●●●●● patch | view | raw | blame | history
src/views/clientManagement/clientManagement.vue 391 ●●●● patch | view | raw | blame | history
src/views/feedbackReport/feedbackReport.vue 157 ●●●●● patch | view | raw | blame | history
src/views/healthcode/healthcode.vue 227 ●●●●● patch | view | raw | blame | history
src/views/parcel/parcel.vue 238 ●●●●● patch | view | raw | blame | history
src/views/parcel/parcelKind.vue 225 ●●●●● patch | view | raw | blame | history
src/views/realTimePolice/real.vue 132 ●●●●● patch | view | raw | blame | history
src/views/realTimePolice/realHistory.vue 3 ●●●● patch | view | raw | blame | history
src/views/security/security copy.vue 175 ●●●●● patch | view | raw | blame | history
src/views/security/security.vue 483 ●●●●● patch | view | raw | blame | history
src/views/system/cs.vue 11 ●●●● patch | view | raw | blame | history
src/styles/element-ui.scss
@@ -357,8 +357,53 @@
.el-date-table.is-week-mode .el-date-table__row:hover div {
  background-color: $inputB1 !important;
}
.el-picker-panel__icon-btn {
  color: $fontColor !important;
}
//首页的body不加颜色
#avue-view .el-card__body {
  background-color: transparent !important;
}
//top导航颜色
.avue-header {
  background-color: $mainB !important;
}
//表格斑马线
// .theme-deep-bule .el-card .el-table td {
//   background-color: $mainB !important;
// }
// .theme-deep-bule .el-card .el-table td,
// .theme-deep-bule .el-card .el-table th.is-leaf {
//   border-color: $mainB !important;
// }
// .theme-deep-bule .el-card .el-table td {
//   background-color: $mainB !important;
// }
// .el-table__row:hover {
//   background-color: $mainBhover !important;
// }
//表格右侧白色
.el-table__fixed-right-patch {
  background-color: $mainB !important;
}
.el-table--border th,
.el-table__fixed-right-patch {
  border-bottom: $mainB !important;
}
//子表单
.el-collapse-item__header {
  background-color: $mainB !important;
  color: $fontColor !important;
}
.avue-group__icon,
.avue-group__title {
  color: $fontColor !important;
}
//main背景
.avue-main {
  background-color: $mainBx2 !important;
}
src/styles/ourBackgroundColor.scss
@@ -9,6 +9,7 @@
$mainB2: #0048e5;
$mainB: #004ca7;
$mainBx1: #013e8a;
$mainBx2: #03277c;
$mainBhover: #1d5ce4;
src/styles/theme/bule.scss
@@ -1,5 +1,4 @@
.theme-bule {
  .avue-header,
  .avue-logo {
    background: #004ca7;
@@ -37,16 +36,13 @@
  }
  .avue-top {
    .el-menu-item {
      i,
      span {
        color: #fff;
      }
      &:hover {
        i,
        span {
          color: #fff;
@@ -56,30 +52,28 @@
  }
}
.theme-deep-bule {
  background: #19305C;
  background: #19305c;
  .avue-tags .el-tabs--card>.el-tabs__header .el-tabs__item {
    color: #fff;
  }
  .avue-tags .el-tabs--card>.el-tabs__header .el-tabs__item.is-active {
    color: #409EFF;
    color: #409eff;
  }
  .avue-contail {
    background: #19305C;
    background: #19305c;
  }
  .avue-header,
  .avue-logo {
    background: #19305C;
    background: #19305c;
  }
  .avue-sidebar {
    background: #19305C;
    background: #19305c;
    .el-menu-item.is-active,
    .el-submenu__title.is-active {
@@ -110,16 +104,13 @@
  }
  .avue-top {
    .el-menu-item {
      i,
      span {
        color: #fff;
      }
      &:hover {
        i,
        span {
          color: #fff;
@@ -129,18 +120,17 @@
  }
  .el-select-dropdown {
    background: #0146F0;
    background: #0146f0;
    color: #8ab6ff;
    border: 1px solid #0140D8;
    border: 1px solid #0140d8;
  }
  .el-popper[x-placement^=bottom] .popper__arrow::after {
    border-bottom-color: #0146F0;
  .el-popper[x-placement^="bottom"] .popper__arrow::after {
    border-bottom-color: #0146f0;
  }
  .el-popper[x-placement^=bottom] .popper__arrow {
    border-bottom-color: #0146F0;
  .el-popper[x-placement^="bottom"] .popper__arrow {
    border-bottom-color: #0146f0;
  }
  .el-select-dropdown__item {
@@ -149,14 +139,14 @@
  .el-select-dropdown__item.hover,
  .el-select-dropdown__item:hover {
    background-color: #155CF7;
    background-color: #155cf7;
  }
  .el-button:focus,
  .el-button:hover {
    color: #F0F0F0;
    border-color: #83C1FF;
    background-color: #83C1FF;
    color: #f0f0f0;
    border-color: #83c1ff;
    background-color: #83c1ff;
  }
  .avue-crud__right {
@@ -164,20 +154,19 @@
  }
  .el-button--default {
    background-color: #409EFF;
    border-color: #409EFF;
    color: #FFF9FF;
    background-color: #409eff;
    border-color: #409eff;
    color: #fff9ff;
  }
  .el-card {
    height: 100%;
    background: #19305C;
    background: #19305c;
    color: #fff;
    .el-table,
    .el-table__expanded-cell {
      background-color: #19305C;
      background-color: #19305c;
    }
    .el-table--border::after,
@@ -191,23 +180,22 @@
      background-color: #1a325f;
    }
    .el-loading-mask {
      background-color: #1a325fe1;
    }
    .el-table th {
      background-color: #155CF7;
      background-color: #155cf7;
      color: #fff;
    }
    //表格 行颜色
    .el-table td {
      background: #0142D6;
      background: #004ca7;
      color: #fff;
    }
    .el-table--striped .el-table__body tr.el-table__row--striped td {
      background: #044BE3;
      background: #044be3;
    }
    .el-button--text {
@@ -215,8 +203,7 @@
    }
    .el-collapse-item__wrap {
      background-color: #19305C;
      background-color: #19305c;
    }
    .el-collapse {
@@ -225,11 +212,10 @@
    }
    .avue-crud__menu {
      background-color: #19305C;
      background-color: #19305c;
    }
    .el-form-item__label {
      color: #fff;
    }
@@ -262,12 +248,12 @@
    }
    .el-input__inner {
      background: #0146F0;
      background: #0146f0;
      color: #8ab6ff;
    }
    .el-tooltip input {
      background: #0146F0;
      background: #0146f0;
      color: #8ab6ff;
    }
@@ -277,35 +263,33 @@
    .el-date-editor,
    .el-input input {
      border-color: #0140D8;
      border-color: #0140d8;
    }
    .avue-group .el-collapse,
    .avue-group .el-collapse-item__wrap {
      border-color: #19305C;
      border-color: #19305c;
    }
    .el-pagination.is-background .btn-next,
    .el-pagination.is-background .btn-prev,
    .el-pagination.is-background .el-pager li {
      margin: 0 5px;
      background-color: #409EFF;
      background-color: #409eff;
      color: #fff;
      min-width: 30px;
      border-radius: 2px;
    }
    .el-tag {
      background-color: #409EFF;
      background-color: #409eff;
      color: #fff;
      border-color: #53a7fa;
    }
  }
  #avue-view {
    &>.el-row {
      &>.el-col:first-child {
        padding-right: 2px;
      }
src/views/animalHeat/animalHeat.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page="page"
@@ -20,7 +21,8 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
        <template slot="menuLeft">
          <el-button
            v-bind:class="activeClass == 0 ? 'btn-color' : ''"
@@ -42,17 +44,21 @@
          </el-button>
        </template>
        <template slot="menuLeft">
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-download"
                      @click="handleExport">导出
          @click="handleExport"
          >导出
          </el-button>
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-pie-chart"
                      @click="handleExportStatis">导出报表
          @click="handleExportStatis"
          >导出报表
          </el-button>
        </template>
    </avue-crud>
@@ -63,7 +69,8 @@
              class="img"
              v-if="showViewer"
              :on-close="closeViewer"
              :url-list="[imgUrl]" />
          :url-list="[imgUrl]"
        />
      </div>
    </template>
  </basic-container>
@@ -72,10 +79,10 @@
<script>
  import {getList} from "@/api/animalHeat/animalHeat";
  import {mapGetters} from "vuex";
  import ElImageViewer from 'element-ui/packages/image/src/image-viewer'
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
  export default {
    name:'index',
  name: "index",
    components: { ElImageViewer },
    data() {
      return {
@@ -84,20 +91,20 @@
        search:{},
        showViewer:false,
        activeClass: 0,
        imgUrl:'',
      imgUrl: "",
        loading: true,
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          menu:false,
          height:'auto',
        height: "auto",
          calcHeight: 54,
          border: false,
          stripe:true,
        //stripe:true,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
@@ -106,27 +113,27 @@
          selection: true,
          labelWidth:120,
          dialogClickModal: false,
          headerAlign: 'center',
          align: 'center',
        headerAlign: "center",
        align: "center",
          column: [
            {
              label: '坐标',
              prop: 'test',
            label: "坐标",
            prop: "test",
              hide: true,
              span: 24,
              component: "avueMap",
              clickChild: (obj) => {
                this.form.jd = obj.latitude
                this.form.wd = obj.longitude
              this.form.jd = obj.latitude;
              this.form.wd = obj.longitude;
              },
            },
            {
              label: "检测时间",
              prop: "createTime"
            prop: "createTime",
            },
            {
              label: "体温",
              prop: "tempRed"
            prop: "tempRed",
            },
            // {
            //   label: '图片',
@@ -155,9 +162,9 @@
                {
                  required: true,
                  message: "请输入时间",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "体温状态",
@@ -171,18 +178,17 @@
              dicData: [
                {
                  label: "正常",
                  value: 0
                value: 0,
                },
                {
                  label: "异常",
                  value: 1
                }
              ],
            }
          ]
                value: 1,
        },
        data: []
            ],
          },
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -192,21 +198,20 @@
          addBtn: this.vaildData(null, false),
          viewBtn: this.vaildData(null, false),
          delBtn: this.vaildData(null, false),
          editBtn: this.vaildData(null, false)
        editBtn: this.vaildData(null, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      beforeOpen(done, type) {
      },
    beforeOpen(done, type) {},
      //清空按钮
      searchReset() {
        //清空搜索框中的内容
@@ -243,29 +248,43 @@
        this.onLoad(this.page, this.query);
      },
      getStartTime(){
           if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
             return this.$route.query.startTime
      if (
        this.$route.query.startTime != undefined &&
        this.$route.query.startTime != null &&
        this.$route.query.startTime != ""
      ) {
        return this.$route.query.startTime;
           }
           // 当前时间
          var date = new Date();
          //年
          var Y = date.getFullYear();
          //月
          var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
          //日
          var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
           return Y + "-" + M + "-" + D;
      },
      getEndTime(){
           if (this.$route.query.endTime != undefined && this.$route.query.endTime != null && this.$route.query.endTime != "" ) {
             return this.$route.query.endTime
      if (
        this.$route.query.endTime != undefined &&
        this.$route.query.endTime != null &&
        this.$route.query.endTime != ""
      ) {
        return this.$route.query.endTime;
           }
            // 当前时间
            var date = new Date();
            //年
            var Y = date.getFullYear();
            //月
            var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
            //日
            var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
            return Y + "-" + M + "-" + D;
@@ -281,23 +300,32 @@
        var params ={};
        if(e==0){
          //修改搜索框中的值
          this.search.releaseTimeRange=[this.showToDay(today)+" 00:00:00",this.showToDay(today)+" 23:59:59"]
        this.search.releaseTimeRange = [
          this.showToDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==1){
          //修改搜索框中的值
          this.search.releaseTimeRange=[this.showWeekFirstDay(today)+" 00:00:00",this.showToDay(today)+" 23:59:59"]
        this.search.releaseTimeRange = [
          this.showWeekFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==2){
          //修改搜索框中的值
          this.search.releaseTimeRange=[this.showMonthFirstDay(today)+" 00:00:00",this.showToDay(today)+" 23:59:59"]
        this.search.releaseTimeRange = [
          this.showMonthFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        params = {
          type: e
        type: e,
        };
        if(this.search.status){
          params = {
            ... params,
            status: this.search.status
          status: this.search.status,
          };
        }
        this.query=params;
@@ -333,12 +361,23 @@
      //本月第一天
      showMonthFirstDay(Nowdate){
        var MonthFirstDay=new Date(Nowdate.getFullYear(),Nowdate.getMonth(),1);
      var MonthFirstDay = new Date(
        Nowdate.getFullYear(),
        Nowdate.getMonth(),
        1
      );
        var M=Number(MonthFirstDay.getMonth())+1;
        if(M<10){
          M="0"+M;
        }
        return MonthFirstDay.getFullYear()+"-"+M+"-"+"0"+MonthFirstDay.getDate();
      return (
        MonthFirstDay.getFullYear() +
        "-" +
        M +
        "-" +
        "0" +
        MonthFirstDay.getDate()
      );
      },
      //数据导出
@@ -346,47 +385,69 @@
        this.$confirm("是否导出体温数据?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        }).then(() => {
          let begTime = this.$route.query.startTime==undefined? '':this.$route.query.startTime;
          let endTime = this.$route.query.endTime==undefined? '':this.$route.query.endTime;
          let status = this.$route.query.status==undefined? '':this.$route.query.status;
          let timeDesc = this.$route.query.timeDesc==undefined? '':this.$route.query.timeDesc;
          window.open(`/api/animalHeat/animalHeat/export-animalHeat?begTime=${begTime}&endTime=${endTime}&status=${status}&timeDesc=${timeDesc}`);
        let begTime =
          this.$route.query.startTime == undefined
            ? ""
            : this.$route.query.startTime;
        let endTime =
          this.$route.query.endTime == undefined
            ? ""
            : this.$route.query.endTime;
        let status =
          this.$route.query.status == undefined ? "" : this.$route.query.status;
        let timeDesc =
          this.$route.query.timeDesc == undefined
            ? ""
            : this.$route.query.timeDesc;
        window.open(
          `/api/animalHeat/animalHeat/export-animalHeat?begTime=${begTime}&endTime=${endTime}&status=${status}&timeDesc=${timeDesc}`
        );
        });
      },
      //数据报表导出
      handleExportStatis() {
          let begTime = this.$route.query.startTime==undefined? '':this.$route.query.startTime;
          let endTime = this.$route.query.endTime==undefined? '':this.$route.query.endTime;
          let status = this.$route.query.status==undefined? '':this.$route.query.status;
          let timeDesc = this.$route.query.timeDesc==undefined? '':this.$route.query.timeDesc;
      let begTime =
        this.$route.query.startTime == undefined
          ? ""
          : this.$route.query.startTime;
      let endTime =
        this.$route.query.endTime == undefined ? "" : this.$route.query.endTime;
      let status =
        this.$route.query.status == undefined ? "" : this.$route.query.status;
      let timeDesc =
        this.$route.query.timeDesc == undefined
          ? ""
          : this.$route.query.timeDesc;
          //window.open(`/api/animalHeat/animalHeat/getAnimalHeatStatis?begTime=${begTime}&endTime=${endTime}&status=${status}&timeDesc=${timeDesc}`);
          window.open(`https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-animalHeat.statis.ureport.xml&begTime=${begTime}&endTime=${endTime}&status=${status}&timeDesc=${timeDesc}`);
      window.open(
        `https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-animalHeat.statis.ureport.xml&begTime=${begTime}&endTime=${endTime}&status=${status}&timeDesc=${timeDesc}`
      );
      },
      //修改行颜色
      rowStyle({row, column, rowIndex}){
         if(row.status=="1"){
           return {
             color:"#fe1515"
           }
          color: "#fe1515",
        };
         }
      },
      //图片行点击事件
      rowClick(row){
        var that = this;
        that.imgUrl = row.picture;
        this.showViewer = true
      this.showViewer = true;
      },
      // 关闭查看器
      closeViewer() {
        this.showViewer = false
      this.showViewer = false;
      },
      //体温状态回填
      getAnimalType(){
          if (this.$route.query.status != undefined) {
              return this.$route.query.status
        return this.$route.query.status;
          }
      },
      onLoad(page, params={}) {
@@ -394,17 +455,22 @@
        let values = {
          ...params,
        };
        if (this.$route.query.type!=undefined && this.$route.query != undefined && this.$route.query != null && this.$route.query != "" ) {
      if (
        this.$route.query.type != undefined &&
        this.$route.query != undefined &&
        this.$route.query != null &&
        this.$route.query != ""
      ) {
            if (this.$route.query.status != undefined) {
              this.page.currentPage = 1;
              params = {
                status:this.$route.query.status,
                type:this.$route.query.type
              }
            type: this.$route.query.type,
          };
            } else {
              this.page.currentPage = 1;
              params = {
                type:this.$route.query.type
            type: this.$route.query.type,
              };
            }
            this.activeClass=4;
@@ -412,16 +478,16 @@
            params = {
              status: this.$route.query.status,
              begTime: this.$route.query.startTime,
              endTime: this.$route.query.endTime
            }
          endTime: this.$route.query.endTime,
        };
            this.activeClass=4;
        }
        //初始进入默认展示当天数据
        if(this.activeClass==0 && this.query.dateTime==null){
            params = {
                type:this.activeClass
            }
          type: this.activeClass,
        };
        }
        if (dateTime) {
@@ -449,15 +515,15 @@
        }
        this.loading = true;
        getList(page.currentPage, page.pageSize, values).then(res => {
      getList(page.currentPage, page.pageSize, values).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
<style lang="scss">
src/views/article/article.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page.sync="page"
@@ -17,14 +18,17 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger"
        <el-button
          type="danger"
                   size="small"
                   icon="el-icon-delete"
                   plain
                   v-if="permission.article_delete"
                   @click="handleDelete">删 除
          @click="handleDelete"
          >删 除
        </el-button>
      </template>
    </avue-crud>
@@ -44,19 +48,19 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        datetime:"",
        selectionList: [],
        option: {
          height: 'auto',
        height: "auto",
          calcHeight: 54,
          dialogWidth: 950,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
          border: false,
          stripe:true,
        //stripe:true,
          index: true,
          viewBtn: true,
          selection: true,
@@ -70,23 +74,25 @@
              row: true,
              searchSpan:5,
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入资讯标题",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
            label: "资讯封面",
            prop: "url",
            // align:'center',
            width:80,
            type: 'upload',
            listType: 'picture-img',
            action: '/api/blade-resource/oss/endpoint/put-file',
            type: "upload",
            listType: "picture-img",
            action: "/api/blade-resource/oss/endpoint/put-file",
            propsHttp: {
              res: 'data',
              url: 'link',
              res: "data",
              url: "link",
            },
            // hide: true,
            span: 24,
@@ -97,11 +103,13 @@
              search: true,
              searchSpan:4,
              span: 24,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入资讯类型",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "资讯类型",
@@ -113,15 +121,17 @@
              dicUrl: "/api/blade-system/dict-biz/dictionary?code=articleType",
              props: {
                label: "dictValue",
                value: "dictKey"
              value: "dictKey",
              },
              search:true,
              type:"select",
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择资讯类型",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
            },
            {
              label: "发布时间",
@@ -135,11 +145,13 @@
              editDisplay: false,
              viewDisplay: false,
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择发布时间",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "发布时间",
@@ -149,29 +161,29 @@
              viewDisplay: false,
              type: "date",
              format: "yyyy-MM-dd HH:mm:ss",
              valueFormat: "yyyy-MM-dd HH:mm:ss"
            valueFormat: "yyyy-MM-dd HH:mm:ss",
            },
            {
              label: "资讯内容",
              prop: "content",
              component: 'AvueUeditor',
            component: "AvueUeditor",
              options: {
                action: '/api/blade-resource/oss/endpoint/put-file',
              action: "/api/blade-resource/oss/endpoint/put-file",
                // customConfig: {
                //   lineHeights: ['1', '1.15', '1.6', '2', '2.5', '3']
                // },//wangEditor编辑的配置
                props: {
                  res: "data",
                  url: "link",
                }
              },
              },
              hide: true,
              minRows: 6,
              span: 24,
            }
          ]
        },
        data: []
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -181,49 +193,55 @@
          addBtn: this.vaildData(this.permission.article_add, true),
          viewBtn: this.vaildData(this.permission.article_view, true),
          delBtn: this.vaildData(this.permission.article_delete, true),
          editBtn: this.vaildData(this.permission.article_edit, true)
        editBtn: this.vaildData(this.permission.article_edit, true),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      rowSave(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -232,7 +250,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -261,7 +279,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -270,14 +288,14 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getNotice(this.form.id).then(res => {
        getNotice(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
@@ -302,20 +320,20 @@
            ...params,
            startTime: dateTime[0],
            endTime: dateTime[1],
            ...this.query
          ...this.query,
          };
          values.datetime = null;
        }
        this.loading = true;
        getList(page.currentPage, page.pageSize, values).then(res => {
      getList(page.currentPage, page.pageSize, values).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/attendance/attendance.vue
@@ -4,14 +4,19 @@
    <div class="box">
      <el-scrollbar>
        <basic-container>
          <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick"/>
            <avue-tree
              :option="treeOption"
              :data="treeData"
              @node-click="nodeClick"
            />
        </basic-container>
      </el-scrollbar>
    </div>
  </el-col>
  <el-col>
  <basic-container>
    <avue-crud :option="option"
        <avue-crud
          :option="option"
               :search.sync="search"
               :table-loading="loading"
               :data="data"
@@ -30,31 +35,48 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
          @on-load="onLoad"
        >
      <template slot="menuLeft">
        <el-button type="danger"
            <el-button
              type="danger"
                   size="small"
                   icon="el-icon-delete"
                   plain
                   v-if="permission.attendance_delete"
                   @click="handleDelete">删 除
              @click="handleDelete"
              >删 除
        </el-button>
        <el-button type="warning"
            <el-button
              type="warning"
                   size="small"
                   plain
                   icon="el-icon-download"
                   @click="handleExport">导出
              @click="handleExport"
              >导出
        </el-button>
      </template>
      <template slot-scope="{ row }" slot="clocktype">
        <el-tag>{{
            row.clocktype == "0" ? "上班" : row.clocktype == "1" ? "下班" : "无"
            <el-tag
              >{{
                row.clocktype == "0"
                  ? "上班"
                  : row.clocktype == "1"
                  ? "下班"
                  : "无"
          }}
        </el-tag>
      </template>
      <template slot-scope="{ row }" slot="attendancetype">
        <el-tag>{{
            row.attendancetype == "0" ? "正常" : row.attendancetype == "1" ? "迟到" : row.attendancetype == "2" ? "早退" : "无效"
            <el-tag
              >{{
                row.attendancetype == "0"
                  ? "正常"
                  : row.attendancetype == "1"
                  ? "迟到"
                  : row.attendancetype == "2"
                  ? "早退"
                  : "无效"
          }}
        </el-tag>
      </template>
@@ -65,7 +87,13 @@
</template>
<script>
  import {getList, getDetail, add, update, remove} from "@/api/attendance/attendance";
import {
  getList,
  getDetail,
  add,
  update,
  remove,
} from "@/api/attendance/attendance";
  import {mapGetters} from "vuex";
  import {getDeptLazyTree, getDeptTree} from "@/api/system/dept";
  import website from "@/config/website";
@@ -80,40 +108,42 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        treeDeptId: '',
      treeDeptId: "",
        treeData: [],
        treeOption: {
          nodeKey: 'id',
        nodeKey: "id",
          lazy: true,
          treeLoad: function (node, resolve) {
            const parentId = (node.level === 0) ? 0 : node.data.id;
            getDeptLazyTree(parentId).then(res => {
              resolve(res.data.data.map(item => {
          const parentId = node.level === 0 ? 0 : node.data.id;
          getDeptLazyTree(parentId).then((res) => {
            resolve(
              res.data.data.map((item) => {
                return {
                  ...item,
                  leaf: !item.hasChildren
                }
              }))
                  leaf: !item.hasChildren,
                };
              })
            );
            });
          },
          addBtn: false,
          menu: false,
          size: 'small',
        size: "small",
          props: {
            labelText: '标题',
            label: 'title',
            value: 'value',
            children: 'children'
          }
          labelText: "标题",
          label: "title",
          value: "value",
          children: "children",
        },
        },
        option: {
          height:'auto',
        height: "auto",
          calcHeight: 54,
          border: false,
          stripe:true,
        //stripe:true,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
@@ -122,8 +152,8 @@
          selection: true,
          labelWidth:120,
          dialogClickModal: false,
          headerAlign: 'center',
          align: 'center',
        headerAlign: "center",
        align: "center",
          column: [
            // {
            //   label: "所属租户",
@@ -187,11 +217,13 @@
              editDisplay: false,
              viewDisplay: false,
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入考勤时间",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "考勤时间",
@@ -200,20 +232,24 @@
              width: 200,
              format: "yyyy-MM-dd HH:mm:ss",
              valueFormat: "yyyy-MM-dd HH:mm:ss",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入clocktime",
                trigger: "click"
              }]
                trigger: "click",
              },
            ],
            },
            {
              label: "星期",
              prop: "week",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入星期",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            // {
            //   label: "天气",
@@ -228,21 +264,25 @@
              label: "经度",
              prop: "jd",
              hide: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入经度",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "纬度",
              hide: true,
              prop: "wd",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入纬度",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "打卡类型",
@@ -251,21 +291,23 @@
              width: 120,
              type: "select",
              slot: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入打卡类型",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
              dicData: [
                {
                  label: "上班",
                  value: "0"
                value: "0",
                },
                {
                  label: "下班",
                  value: "1"
                }
              ]
                value: "1",
              },
            ],
            },
            {
              label: "考勤类型",
@@ -274,43 +316,47 @@
              prop: "attendancetype",
              slot: true,
              type: "select",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入考勤类型",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
              dicData: [
                {
                  label: "正常",
                  value: "0"
                value: "0",
                },
                {
                  label: "迟到",
                  value: "1"
                value: "1",
                },
               {
                 label: "早退",
                   value: "2"
                value: "2",
                },
               {
                 label: "无效",
                   value: "4"
               }
              ]
                value: "4",
              },
            ],
            },
            {
              label: "考勤地址",
              prop: "address",
              width: 450,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入地址",
                trigger: "blur"
              }]
                trigger: "blur",
            },
          ]
            ],
        },
        data: []
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -320,16 +366,16 @@
          addBtn: this.vaildData(null, false),
          viewBtn: this.vaildData(this.permission.attendance_view, true),
          delBtn: this.vaildData(this.permission.attendance_delete, true),
          editBtn: this.vaildData(null, false)
        editBtn: this.vaildData(null, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      nodeClick(data) {
@@ -338,42 +384,48 @@
        this.onLoad(this.page);
      },
      rowSave(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          loading();
          window.console.log(error);
        });
        }
      );
      },
      initData(tenantId) {
        getDeptTree(tenantId).then(res => {
      getDeptTree(tenantId).then((res) => {
          const column = this.findObject(this.option.column, "deptId");
          column.dicData = res.data.data;
        });
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          loading();
          console.log(error);
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -382,7 +434,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -394,7 +446,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -403,7 +455,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
@@ -412,7 +464,7 @@
        this.$confirm("是否导出考勤数据?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        }).then(() => {
          window.open(`/api/attendance/export-Attendance?name=${this.search.name}&beginTime=${this.search.releaseTimeRange[0]}
          &endTime=${this.search.releaseTimeRange[1]}&attendancetype=${this.search.attendancetype}`);
@@ -420,7 +472,7 @@
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDetail(this.form.id).then(res => {
        getDetail(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
@@ -428,7 +480,7 @@
      },
      searchReset() {
        this.query = {};
        this.treeDeptId = '';
      this.treeDeptId = "";
        this.onLoad(this.page);
      },
      searchChange(params, done) {
@@ -463,37 +515,38 @@
            ...params,
            beginTime: releaseTimeRange[0],
            endTime: releaseTimeRange[1],
            ...this.query
          ...this.query,
          };
          values.releaseTimeRange = null;
        } else {
          values = {
            ...params,
            ...this.query
          ...this.query,
          };
        }
        this.loading = true;
        getList(page.currentPage, page.pageSize,values,this.treeDeptId).then(res => {
      getList(page.currentPage, page.pageSize, values, this.treeDeptId).then(
        (res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
        }
      );
      },
      rowStyle({row, column, rowIndex}) {
        if (row.attendancetype == 1) {
          return {
            color: "#fe1515"
          }
        }
        else if(row.attendancetype == 2){
          color: "#fe1515",
        };
      } else if (row.attendancetype == 2) {
          return {
            color: "#FFCC33"
          }
          color: "#FFCC33",
        };
        }
      },
    }
  },
  };
</script>
src/views/clientManagement/clientManagement.vue
@@ -2,12 +2,17 @@
  <el-row>
    <el-col :span="3">
      <basic-container>
        <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick"/>
        <avue-tree
          :option="treeOption"
          :data="treeData"
          @node-click="nodeClick"
        />
      </basic-container>
    </el-col>
    <el-col :span="21">
      <basic-container>
        <avue-crud :option="option"
        <avue-crud
          :option="option"
                   :table-loading="loading"
                   :data="data"
                   :page.sync="page"
@@ -29,15 +34,17 @@
                   @size-change="sizeChange"
                   @refresh-change="refreshChange"
                   @on-load="onLoad"
                   @row-click="rowClick">
          @row-click="rowClick"
        >
          <template slot="menuLeft">
            <el-button type="danger"
            <el-button
              type="danger"
                       size="mini"
                       icon="el-icon-delete"
                       plain
                       v-if="permission.clientManagement_delete"
                       @click="handleDelete">删 除
              @click="handleDelete"
              >删 除
            </el-button>
<!--            <span>&lt;!&ndash;图例 components&ndash;&gt;-->
<!--              <Legend :datas="datalistLIU"></Legend>-->
@@ -45,8 +52,13 @@
          </template>
          <template slot-scope="{ row }" slot="devicestate">
            <el-tag>{{
              row.devicestate == "0" ? "撤防" : row.devicestate == "1" ? "布防" : "无"
            <el-tag
              >{{
                row.devicestate == "0"
                  ? "撤防"
                  : row.devicestate == "1"
                  ? "布防"
                  : "无"
              }}
            </el-tag>
          </template>
@@ -70,14 +82,21 @@
          <template class="tdtype" slot-scope="{ row }" slot="dxzt">
            <el-tag class="dtype">
              {{
              row.dxzt == "0" ? "掉线" : row.dxzt == "1" ? "正常" :row.dxzt == "2" ? "预警":row.dxzt == "3" ? "故障":"无"
                row.dxzt == "0"
                  ? "掉线"
                  : row.dxzt == "1"
                  ? "正常"
                  : row.dxzt == "2"
                  ? "预警"
                  : row.dxzt == "3"
                  ? "故障"
                  : "无"
              }}
              <i class="dx" v-if="row.dxzt == '0' "></i>
              <i class="zc" v-if="row.dxzt == '1' "></i>
              <i class="yj" v-if="row.dxzt == '2' "></i>
              <i class="gz" v-if="row.dxzt == '3' "></i>
            </el-tag>
          </template>
          <template slot-scope="{ row }" slot="type">
@@ -95,7 +114,6 @@
            >办结
            </el-button>
          </template>
        </avue-crud>
        <div v-show="menuVisible">
@@ -104,7 +122,6 @@
            <li class="menu_item" @click.stop="handleMap">定位</li>
          </ul>
        </div>
        <el-drawer
          title="电子地图"
@@ -120,12 +137,15 @@
            height="100%"
          ></iframe>
        </el-drawer>
      </basic-container>
    </el-col>
    <el-dialog title="缴费提醒" :visible.sync="dialogTableVisible" top="280px" custom-class="payWin" append-to-body="true">
    <el-dialog
      title="缴费提醒"
      :visible.sync="dialogTableVisible"
      top="280px"
      custom-class="payWin"
      append-to-body="true"
    >
      <el-dialog
        class="real-jf-dialog"
        title="缴费"
@@ -154,58 +174,29 @@
            <el-form-item>
              <el-button type="primary" @click.stop="generate(form)"
              >缴费
              </el-button
              >
              </el-button>
            </el-form-item>
          </el-col>
        </el-form>
      </el-dialog>
      <el-table
        :data="gridData"
        border
        style="width: 100%"
        >
        <el-table-column
          fixed
          prop="xb"
          label="序号"
          width="50">
      <el-table :data="gridData" border style="width: 100%">
        <el-table-column fixed prop="xb" label="序号" width="50">
        </el-table-column>
        <el-table-column
          prop="deviceName"
          label="设备名称"
          width="180">
        <el-table-column prop="deviceName" label="设备名称" width="180">
        </el-table-column>
        <el-table-column
          prop="deviceNumber"
          label="设备编码"
          width="150">
        <el-table-column prop="deviceNumber" label="设备编码" width="150">
        </el-table-column>
        <el-table-column
          prop="ownership"
          label="所属单位"
          width="160">
        <el-table-column prop="ownership" label="所属单位" width="160">
        </el-table-column>
        <el-table-column
          prop="expireTime"
          label="到期时间"
          width="160"
        >
        <el-table-column prop="expireTime" label="到期时间" width="160">
        </el-table-column>
        <el-table-column
          prop="pay"
          label="缴费信息"
        >
        </el-table-column>
        <el-table-column
          fixed="right"
          label="操作"
          width="100">
        <el-table-column prop="pay" label="缴费信息"> </el-table-column>
        <el-table-column fixed="right" label="操作" width="100">
          <template slot-scope="scope">
            <el-button type="text" size="small" @click="handleClick(scope.row)">一键缴费</el-button>
            <el-button type="text" size="small" @click="handleClick(scope.row)"
              >一键缴费</el-button
            >
          </template>
        </el-table-column>
      </el-table>
@@ -214,13 +205,23 @@
</template>
<script>
  import {getList, remove, update, add, getclient, getDeptLazyTree, getAll, updates,getBaTree} from "@/api/client/client";
import {
  getList,
  remove,
  update,
  add,
  getclient,
  getDeptLazyTree,
  getAll,
  updates,
  getBaTree,
} from "@/api/client/client";
  // import {getDeptTree} from "@/api/system/dept";
  import {mapGetters} from "vuex";
  import axios from "axios";
  import Legend from '../../components/liu-legend/Legend'
import Legend from "../../components/liu-legend/Legend";
  import AvueMap from "avue-plugin-map";
  import website from '@/config/website';
import website from "@/config/website";
  export default {
    components:{
@@ -232,26 +233,26 @@
    data() {
      return {
        dataLIU:{
          color:"#DFDFDF"
        color: "#DFDFDF",
        },
        //legend-liu数据
        datalistLIU:[
                {
                    color: "#DFDFDF",
                    text: '掉线'
          text: "掉线",
                },
                {
                    color: "#29C093",
                    text: '正常'
          text: "正常",
                },
                {
                    color: "#F34A4A",
                    text: '预警'
          text: "预警",
                },
                {
                    color: "#F48F57",
                    text: '故障'
                }
          text: "故障",
        },
        ],
        form: {},
        query: {},
@@ -264,43 +265,45 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        dialogTableVisible: false,
        realjf: false,
        gridData: null,
        selectionList: [],
        treeDeptId: '',
      treeDeptId: "",
        treeData: [],
        treeOption: {
          nodeKey: 'id',
        nodeKey: "id",
          lazy: true,
          treeLoad: function (node, resolve) {
            const parentId = (node.level === 0) ? 0 : node.data.id;
            getDeptLazyTree(parentId).then(res => {
              resolve(res.data.data.map(item => {
          const parentId = node.level === 0 ? 0 : node.data.id;
          getDeptLazyTree(parentId).then((res) => {
            resolve(
              res.data.data.map((item) => {
                return {
                  ...item,
                  leaf: !item.hasChildren
                }
              }))
                  leaf: !item.hasChildren,
                };
              })
            );
            });
          },
          addBtn: false,
          menu: false,
          size: 'small',
        size: "small",
          props: {
            labelText: '标题',
            label: 'title',
            value: 'value',
            children: 'children'
          }
          labelText: "标题",
          label: "title",
          value: "value",
          children: "children",
        },
        },
        option: {
          height: 'auto',
          indexLabel: '序号',
        height: "auto",
        indexLabel: "序号",
          calcHeight: 54,
          labelWidth: '125',
        labelWidth: "125",
          dialogWidth: 1150,
          menuWidth: 200,
          align:"center",
@@ -310,7 +313,7 @@
          searchMenuSpan: 4,
          searchSpan: 4,
          border: false,
          stripe:true,
        //stripe:true,
          index: true,
          viewBtn: true,
          selection: true,
@@ -324,13 +327,14 @@
              searchPlaceholder: "设备名称/编号",
              search: true,
              sortable:true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入设备名称",
                trigger: "blur"
              }],
            }
            ,
                trigger: "blur",
              },
            ],
          },
            {
              label: "设备编号",
              prop: "deviceNumber",
@@ -339,14 +343,14 @@
                {
                  required: true,
                  message: "请输入设备编号",
                  trigger: "click"
                }
              ]
                trigger: "click",
              },
            ],
            },
            {
              label: "使用方",
              prop: "deptName",
              display: false
            display: false,
            },
            {
              label: "使用方",
@@ -358,15 +362,15 @@
              checkStrictly:true,
              hide:true,
              props: {
                label: "title"
              label: "title",
              },
              rules: [
                {
                  required: true,
                  message: "请选择使用方",
                  trigger: "click"
                }
              ]
                trigger: "click",
              },
            ],
            },
            // {
            //   label: "使用方",
@@ -398,15 +402,17 @@
              dicUrl: "/api/blade-system/dict-biz/dictionary?code=manufacturers",
              props: {
                label: "dictValue",
                value: "dictKey"
              value: "dictKey",
              },
              search:true,
              type:"select",
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择设备厂商",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
            },
            {
              label: "设备状态",
@@ -415,7 +421,8 @@
              sortable:true,
              addDisplay: false,
              editDisplay: false,
            }, {
          },
          {
              label: "地址",
              prop: "street",
              span:10,
@@ -430,20 +437,20 @@
              hide: true,
              span: 2,
              // display:false,
              component: "AvueMap"
            component: "AvueMap",
            },
            {
              label: "省份",
              prop: "province",
              search: true,
              searchSpan: 2,
              labelWidth: '110',
            labelWidth: "110",
              searchLabelWidth: 45,
              placeholder: "省份",
              type: "select",
              props: {
                label: "name",
                value: "code"
              value: "code",
              },
              cascaderItem: ["city", "district"],
              dicUrl: "/api/blade-system/region/select",
@@ -465,7 +472,7 @@
              search: true,
              props: {
                label: "name",
                value: "code"
              value: "code",
              },
              dicUrl: "/api/blade-system/region/select?code={{key}}",
              span: 2,
@@ -487,7 +494,7 @@
              type: "select",
              props: {
                label: "name",
                value: "code"
              value: "code",
              },
              dicUrl: "/api/blade-system/region/select?code={{key}}",
              span: 2,
@@ -506,7 +513,7 @@
              width:"100",
              labelWidth: "120",
              formatter: (row,value,label,column)=>{
                  return value = value.substring(0,11);
              return (value = value.substring(0, 11));
              },
              span:7,
            },
@@ -516,7 +523,7 @@
              hide: true,
              prop: "wd",
              formatter: (row,value,label,column) => {
                return value = value.substring(0,10);
              return (value = value.substring(0, 10));
              },
              span:5,
            },
@@ -531,11 +538,10 @@
              addDisplay: true,
              editDisplay: true,
              viewDisplay: true,
            }
          ]
        },
        data: []
        ],
      },
      data: [],
      };
    },
    watch: {
@@ -549,10 +555,16 @@
            //地址截取,从县/区开始截取,并且取从县区第一个出现的位置开始
            var address = val.formattedAddress.toString();
            if(address.search("县") != -1){
                this.form.street = address.substring(address.indexOf("县")+1,address.length);
            this.form.street = address.substring(
              address.indexOf("县") + 1,
              address.length
            );
            }
            if(address.search("区") != -1){
              this.form.street = address.substring(address.indexOf("区")+1,address.length);
            this.form.street = address.substring(
              address.indexOf("区") + 1,
              address.length
            );
            }
            // //写入新的省市区
            // that.form.province = val.addressComponent.province;
@@ -570,7 +582,7 @@
        handler(val) {
          var that = this;
          if (val != null && val !=""){
            getBaTree(val).then(res => {
          getBaTree(val).then((res) => {
              if (res) {
                that.form.onePhone = res.data.data.records[0].phone;
                that.form.oneContacts = res.data.data.records[0].name;
@@ -583,7 +595,7 @@
        handler(val) {
          var that = this;
          if (val != null && val !=""){
            getBaTree(val).then(res => {
          getBaTree(val).then((res) => {
              if (res) {
                that.form.twoPhone = res.data.data.records[0].phone;
                that.form.twoContacts = res.data.data.records[0].name;
@@ -596,7 +608,7 @@
        handler(val) {
          var that = this;
          if (val != null && val !=""){
            getBaTree(val).then(res => {
          getBaTree(val).then((res) => {
              if (res) {
                that.form.threePhone = res.data.data.records[0].phone;
                that.form.threeContacts = res.data.data.records[0].name;
@@ -612,7 +624,6 @@
      //     this.initData();
      //   }
      // }
    },
    computed: {
      ...mapGetters(["permission"]),
@@ -621,16 +632,16 @@
          addBtn: this.vaildData(this.permission.clientManagement_add, false),
          viewBtn: this.vaildData(null, false),
          delBtn: this.vaildData(this.permission.clientManagement_delete, false),
          editBtn: this.vaildData(this.permission.clientManagement_edit, false)
        editBtn: this.vaildData(this.permission.clientManagement_edit, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    mounted(){
      // 租户模式默认加载管理组数据
@@ -639,17 +650,20 @@
    },
    methods: {
      generate(row) {
        updates(row.expireTime, row.deviceNumber).then(() => {
      updates(row.expireTime, row.deviceNumber).then(
        () => {
          this.dialogTableVisible = false;
          this.realjf = false;
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "缴费成功!"
            message: "缴费成功!",
          });
        }, error => {
        },
        (error) => {
          window.console.log(error);
        });
        }
      );
      },
      //初始化数据
@@ -673,54 +687,63 @@
      },
      rowSave(row, done, loading) {
        row.deptId = row.deptId.join(",");
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        if(Array.isArray(row.deptId)){
            row.deptId = row.deptId.join(",");
        }
        update(row).then(() => {
      update(row).then(
        () => {
          // this.initFlag = false;
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      updateDtype(row){
        row.dtype = "0";
        update(row).then(() => {
      update(row).then(
        () => {
          // this.initFlag = false;
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          this.onLoad(this.page);
        }, error => {
        },
        (error) => {
          window.console.log(error);
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -729,7 +752,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -739,7 +762,7 @@
        this.onLoad(this.page);
      },
      searchChange(params, done) {
        console.log(params,done)
      console.log(params, done);
        this.query = params;
        this.page.currentPage = 1;
        this.onLoad(this.page, params);
@@ -760,7 +783,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -769,14 +792,14 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getclient(this.form.id).then(res => {
        getclient(this.form.id).then((res) => {
            this.form = res.data.data;
            this.isEdit=true;
          });
@@ -806,13 +829,13 @@
            ...params,
            beginTime: releaseTimeRange[0],
            endTime: releaseTimeRange[1],
            ...this.query
          ...this.query,
          };
          values.releaseTimeRange = null;
        } else {
          values = {
            ...params,
            ...this.query
          ...this.query,
          };
        }
@@ -826,7 +849,8 @@
        }
        this.loading = true;
        getList(page.currentPage, page.pageSize, values, this.treeDeptId).then(res => {
      getList(page.currentPage, page.pageSize, values, this.treeDeptId).then(
        (res) => {
          const data = res.data.data;
          this.page.total = data.total;
@@ -848,8 +872,10 @@
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }, rowStyle({row, column, rowIndex}) {
        }
      );
    },
    rowStyle({ row, column, rowIndex }) {
        // if (row.heartbeat != null && row.heartbeat != "") {
        //   var date = new Date(row.heartbeat).getTime();
        //   var Dqdate = new Date().getTime();
@@ -876,9 +902,9 @@
          //     color: "#29C093"
          //   };
          // }
          if(row.dtype=='2'){
        if (row.dtype == "2") {
            return {
              color: "#F34A4A"
            color: "#F34A4A",
            };
          }
          // if(row.dtype=='3'){
@@ -894,7 +920,7 @@
      },
      payWin() {
        var that = this;
        getAll().then(res => {
      getAll().then((res) => {
          var data = res.data.data;
          var lists = [];
          var xb = 0;
@@ -910,15 +936,14 @@
            that.dialogTableVisible = true;
          }
        });
      }, handleStart(row) {
    },
    handleStart(row) {
        console.log(row,11111111111);
        row = this.selectRow;
        console.log(row,22222222222);
        var arr = [];
        console.log(this.$store.state.tags.tagList,3333333);
        this.$store.state.tags.tagList.forEach(item => {
      this.$store.state.tags.tagList.forEach((item) => {
          if (item.label != "视频") {
            arr.push(item);
          }
@@ -926,45 +951,49 @@
        this.$store.state.tags.tagList = arr;
        console.log(arr,444444444444);
        this.$router.push({
          path: `/real/video/`, query: row
        path: `/real/video/`,
        query: row,
        });
      }, handleMap(row) {
    },
    handleMap(row) {
        row = this.selectRow;
        this.showMap = true;
        this.$nextTick(() => {
          this.$refs.mapDiv.onload = () => {
            window.frames[1].init("equipment", {x: row.jd, y: row.wd});
          };
        })
      },rightClick(row, event) {
      });
    },
    rightClick(row, event) {
        this.selectRow = row;
        this.menuVisible = false; // 先把模态框关死,目的是 第二次或者第n次右键鼠标的时候 它默认的是true
        this.menuVisible = true; // 显示模态窗口,跳出自定义菜单栏
        var menu = document.querySelector('#menu');
      var menu = document.querySelector("#menu");
        this.styleMenu(menu);
      },
      foo() {
        // 取消鼠标监听事件 菜单栏
        this.menuVisible = false;
        document.removeEventListener('click', this.foo); // 要及时关掉监听,不关掉的是一个坑,不信你试试,虽然前台显示的时候没有啥毛病,加一个alert你就知道了
      document.removeEventListener("click", this.foo); // 要及时关掉监听,不关掉的是一个坑,不信你试试,虽然前台显示的时候没有啥毛病,加一个alert你就知道了
      },
      styleMenu(menu) {
        let cha = document.body.clientHeight - event.clientY
      let cha = document.body.clientHeight - event.clientY;
        //console.log(document.body.clientHeight,event.clientY,cha)
        // 防止菜单太靠底,根据可视高度调整菜单出现位置
        if (cha < 150) {
          menu.style.top = event.clientY -120 - (100) + 'px'
        menu.style.top = event.clientY - 120 - 100 + "px";
        } else {
          menu.style.top = event.clientY -10 - (100) + 'px'
        menu.style.top = event.clientY - 10 - 100 + "px";
        }
        menu.style.left = event.clientX + 10 - (60) + 'px'
        document.addEventListener('click', this.foo); // 给整个document新增监听鼠标事件,点击任何位置执行foo方法
      menu.style.left = event.clientX + 10 - 60 + "px";
      document.addEventListener("click", this.foo); // 给整个document新增监听鼠标事件,点击任何位置执行foo方法
      },
      rowClick(val){//行点击事件
    rowClick(val) {
      //行点击事件
      // console.log(val);
      this.$router.push({ path: "/dataL/dataL", query: val });
      }
    }
    },
  },
  };
</script>
@@ -979,7 +1008,6 @@
  .payWin .el-dialog__body {
    padding-top: 0px !important;
  }
  // /*页面样式*/   //丢弃  因为不起作用,样式在cs.vue中  city1,2,3  liuyg改
  // .el-card__body .cityClass1 {
@@ -1080,7 +1108,7 @@
    width: 10px;
    height: 10px;
    border-radius: 30%;
    background: #DFDFDF;
  background: #dfdfdf;
  }
  .zc{
    position: absolute;
@@ -1090,7 +1118,7 @@
    width: 10px;
    height: 10px;
    border-radius: 30%;
    background: #29C093;
  background: #29c093;
  }
  .yj{
    position: absolute;
@@ -1100,7 +1128,7 @@
    width: 10px;
    height: 10px;
    border-radius: 30%;
    background: #F34A4A;
  background: #f34a4a;
  }
  .gz{
    position: absolute;
@@ -1110,7 +1138,7 @@
    width: 10px;
    height: 10px;
    border-radius: 30%;
    background: #F48F57;
  background: #f48f57;
  }
  .tabFontSize{
@@ -1134,11 +1162,11 @@
    /*border: 1px solid #999999;*/
    text-align: center;
    background-color: #fff;
    border-radius: .25rem;
    box-shadow: 0 .5rem 1rem rgba(0,0,0,.15);
  border-radius: 0.25rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  }
  .menu li:hover {
    background-color: rgba(232,237,250,.6);
  background-color: rgba(232, 237, 250, 0.6);
    color: darkslategrey;
  }
  .menu li{
@@ -1153,9 +1181,6 @@
    padding-left: 20px;
    padding-right: 5px;
  }
</style>
@@ -1169,6 +1194,4 @@
    position: relative !important;
    left: -51px !important;
  }
</style>
src/views/feedbackReport/feedbackReport.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page="page"
@@ -17,23 +18,31 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger"
        <el-button
          type="danger"
                   size="small"
                   icon="el-icon-delete"
                   plain
                   v-if="permission.feedback_delete"
                   @click="handleDelete">删 除
          @click="handleDelete"
          >删 除
        </el-button>
      </template>
    </avue-crud>
  </basic-container>
</template>
<script>
  import {getListReport, getDetails, adds, updates, remove} from "@/api/feedback/feedback";
import {
  getListReport,
  getDetails,
  adds,
  updates,
  remove,
} from "@/api/feedback/feedback";
    import {getBaTree} from "@/api/client/client";
  import {mapGetters} from "vuex";
@@ -46,19 +55,19 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          height:'auto',
        height: "auto",
          calcHeight: 54,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
          labelWidth: '125',
        labelWidth: "125",
          dialogWidth: 1150,
          border: false,
          stripe:true,
        //stripe:true,
          index: true,
          viewBtn: true,
          selection: true,
@@ -73,7 +82,7 @@
              searchLabelWidth:100,
              searchSpan:5,
              addDisplay:false,
              editDisplay:false
            editDisplay: false,
            },
            {
              label: "上报人姓名",
@@ -81,36 +90,42 @@
              type: "tree",
              dicUrl: "/api/catalogs/catalogs/getBigTree",
              props: {
                label: "title"
              label: "title",
              },
              width: 72,
              hide: true,
              addDisplay: true,
              editDisplay: true,
              viewDisplay: false,
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择上报人",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
            },
            {
              label: "上报地址",
              prop: "place",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入事发地址",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "备注",
              prop: "result",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入处理结果",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "上报时间",
@@ -133,54 +148,56 @@
              viewDisplay:false,
              editDisplay:false,
              hide:true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择上报时间",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: '图片',
              prop: 'images',
              dataType: 'array',
              type: 'upload',
            label: "图片",
            prop: "images",
            dataType: "array",
            type: "upload",
              span: 24,
              hide:true,
              viewDisplay:true,
              listType: 'picture-card',
            listType: "picture-card",
              action: "/api/blade-resource/oss/endpoint/put-file",
              propsHttp: {
                res: "data",
                url: "link",
              }
            },
            },
             {
              label: '视频',
              prop: 'videos',
              dataType: 'array',
              type: 'upload',
            label: "视频",
            prop: "videos",
            dataType: "array",
            type: "upload",
              accept:"video/mp4",
              hide:true,
              viewDisplay:true,
              editDisabled:true,
              listType: 'picture',
            listType: "picture",
              span: 24,
              action: "http://web.byisf.com:82/blade-jfpts/depl/put-depl",
              propsHttp: {
                res: "data",
                url: "link",
              }
            },
          ]
        },
        data: []
        ],
      },
      data: [],
      };
    },
    watch:{
      handler(val) {
          var that = this;
          if (val != null && val !=""){
            getBaTree(val).then(res => {
        getBaTree(val).then((res) => {
              if (res) {
                that.form.sname = res.data.data.records[0].name;
              }
@@ -195,16 +212,16 @@
          addBtn: this.vaildData(this.permission.feedback_add, false),
          viewBtn: this.vaildData(this.permission.feedback_view, true),
          delBtn: this.vaildData(this.permission.feedback_delete, true),
          editBtn: this.vaildData(this.permission.feedback_edit, true)
        editBtn: this.vaildData(this.permission.feedback_edit, true),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      rowSave(row, done, loading) {
@@ -216,13 +233,13 @@
              snumber: row.snumber,
              stime:row.stime,
              result:row.result,
              place:row.place
          }
        place: row.place,
      };
        if (row.images.length > 0) {
                    var imageArr = row.images;
                    imageArr.forEach( image =>{
        imageArr.forEach((image) => {
              data.tpaddress += image + ",";
          })
        });
                    data.tpaddress = data.tpaddress.substring(0,data.tpaddress.length-1);
                }
                if (row.videos.length > 0) {
@@ -233,17 +250,20 @@
                    //data.spaddress = data.spaddress.substring(0,data.spaddress.length-1);
                    data.spaddress = row.videos;
                }
        adds(data).then(() => {
      adds(data).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          loading();
          window.console.log(error);
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        var data = {
@@ -255,13 +275,13 @@
              snumber: row.snumber,
              stime:row.stime,
              result:row.result,
              place:row.place
          }
        place: row.place,
      };
        if (row.images.length > 0) {
                    var imageArr = row.images;
                    imageArr.forEach( image =>{
        imageArr.forEach((image) => {
              data.tpaddress += image + ",";
          })
        });
                    data.tpaddress = data.tpaddress.substring(0,data.tpaddress.length-1);
                }
                if (row.videos.length > 0) {
@@ -272,23 +292,26 @@
                    //data.spaddress = data.spaddress.substring(0,data.spaddress.length-1);
                    data.spaddress = row.videos;
                }
        updates(data).then(() => {
      updates(data).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          loading();
          console.log(error);
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -297,7 +320,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -309,7 +332,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -318,14 +341,14 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDetails(this.form.id).then(res => {
        getDetails(this.form.id).then((res) => {
            this.form = res.data.data;
            this.images = res.data.data.images;
            this.videos = res.data.data.videos;
@@ -363,7 +386,7 @@
        const { dateTime } = this.query;
        let values = {
          ...params,
          status:1
        status: 1,
        };
        if (dateTime) {
          values = {
@@ -375,15 +398,15 @@
          values.dateTime = null;
        }
        this.loading = true;
        getListReport(page.currentPage, page.pageSize,values).then(res => {
      getListReport(page.currentPage, page.pageSize, values).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/healthcode/healthcode.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page="page"
@@ -19,7 +20,8 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
        <template slot="menuLeft">
          <el-button
            v-bind:class="activeClass == 0 ? 'btn-color' : ''"
@@ -42,20 +44,23 @@
        </template>
        <template slot="menuLeft">
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-download"
                      @click="handleExport">导出
          @click="handleExport"
          >导出
          </el-button>
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-pie-chart"
                      @click="handleExportStatis">导出报表
          @click="handleExportStatis"
          >导出报表
          </el-button>
        </template>
    </avue-crud>
  </basic-container>
</template>
@@ -75,15 +80,15 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          menu:false,
          height:'auto',
        height: "auto",
          calcHeight: 54,
          border: false,
          stripe:true,
        //stripe:true,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
@@ -92,27 +97,27 @@
          selection: true,
          labelWidth:120,
          dialogClickModal: false,
          headerAlign: 'center',
          align: 'center',
        headerAlign: "center",
        align: "center",
          column: [
            {
              label: '坐标',
              prop: 'test',
            label: "坐标",
            prop: "test",
              hide: true,
              span: 24,
              component: "avueMap",
              clickChild: (obj) => {
                this.form.jd = obj.latitude
                this.form.wd = obj.longitude
              this.form.jd = obj.latitude;
              this.form.wd = obj.longitude;
              },
            },
            {
              label: "检测时间",
              prop: "dtime"
            prop: "dtime",
            },
            {
              label: '性别',
              prop: 'sex'
            label: "性别",
            prop: "sex",
            },
            {
              label: "检测时间",
@@ -132,48 +137,48 @@
                {
                  required: true,
                  message: "请输入时间",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: '省份',
              prop: 'province',
            label: "省份",
            prop: "province",
              //search: true,
              searchSpan: 3,
              type: 'select',
            type: "select",
              props: {
                label: 'name',
                value: 'name'
              label: "name",
              value: "name",
              },
              cascaderItem: ['city', 'district'],
              dicUrl: '/api/blade-system/region/select',
            cascaderItem: ["city", "district"],
            dicUrl: "/api/blade-system/region/select",
              span: 6,
            },
            {
              label: '地市',
              prop: 'city',
              type: 'select',
            label: "地市",
            prop: "city",
            type: "select",
              searchSpan: 3,
              //search: true,
              props: {
                label: 'name',
                value: 'name'
              label: "name",
              value: "name",
              },
              dicUrl: '/api/blade-system/region/select?code={{key}}',
            dicUrl: "/api/blade-system/region/select?code={{key}}",
              span: 6,
            },
            {
              label: '区县',
            label: "区县",
              searchSpan: 3,
              //search: true,
              prop: 'district',
              type: 'select',
            prop: "district",
            type: "select",
              props: {
                label: 'name',
                value: 'name'
              label: "name",
              value: "name",
              },
              dicUrl: '/api/blade-system/region/select?code={{key}}',
            dicUrl: "/api/blade-system/region/select?code={{key}}",
              span: 6,
            },
            {
@@ -188,28 +193,26 @@
              dicData: [
                {
                  label: "绿色",
                  value: "1"
                value: "1",
                },
                {
                  label: "黄色",
                  value: "2"
                value: "2",
                },
                {
                  label: "红色",
                  value: "3"
                }
                value: "3",
              },
              ],
            }
          ]
          },
        ],
        },
        data: [],
        isActive: false,
        recorder: null,
      };
    },
    mounted(){
    },
  mounted() {},
    computed: {
      ...mapGetters(["permission"]),
      permissionList() {
@@ -217,20 +220,19 @@
          addBtn: this.vaildData(null, false),
          viewBtn: this.vaildData(null, false),
          delBtn: this.vaildData(null, false),
          editBtn: this.vaildData(null, false)
        editBtn: this.vaildData(null, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      beforeOpen(done, type) {
      },
    beforeOpen(done, type) {},
      searchReset() {
        //清空搜索框中的内容
        this.query = {};
@@ -266,34 +268,48 @@
      rowStyle({row, column, rowIndex}){
         if(row.type=="3"){
           return {
             color:"#fe1515"
           }
          color: "#fe1515",
        };
         }
      },
      getStartTime(){
           if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
             return this.$route.query.startTime
      if (
        this.$route.query.startTime != undefined &&
        this.$route.query.startTime != null &&
        this.$route.query.startTime != ""
      ) {
        return this.$route.query.startTime;
           }
           // 当前时间
          var date = new Date();
          //年
          var Y = date.getFullYear();
          //月
          var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
          //日
          var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
           return Y + "-" + M + "-" + D;
      },
      getEndTime(){
           if (this.$route.query.endTime != undefined && this.$route.query.endTime != null && this.$route.query.endTime != "" ) {
             return this.$route.query.endTime
      if (
        this.$route.query.endTime != undefined &&
        this.$route.query.endTime != null &&
        this.$route.query.endTime != ""
      ) {
        return this.$route.query.endTime;
           }
            // 当前时间
            var date = new Date();
            //年
            var Y = date.getFullYear();
            //月
            var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
            //日
            var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
            return Y + "-" + M + "-" + D;
@@ -315,24 +331,33 @@
        var params ={};
        if(e==0){
          //修改搜索框中的值
          this.search.releaseTimeRange=[this.showToDay(today)+" 00:00:00",this.showToDay(today)+" 23:59:59"]
        this.search.releaseTimeRange = [
          this.showToDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==1){
          //修改搜索框中的值
          this.search.releaseTimeRange=[this.showWeekFirstDay(today)+" 00:00:00",this.showToDay(today)+" 23:59:59"]
        this.search.releaseTimeRange = [
          this.showWeekFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==2){
          //修改搜索框中的值
          this.search.releaseTimeRange=[this.showMonthFirstDay(today)+" 00:00:00",this.showToDay(today)+" 23:59:59"]
        this.search.releaseTimeRange = [
          this.showMonthFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        params = {
          ... params,
          status: e
        status: e,
        };
        if(this.search.type){
          params = {
            ... params,
            type: this.search.type
          type: this.search.type,
          };
        }
        this.query=params;
@@ -368,48 +393,76 @@
      //本月第一天
      showMonthFirstDay(Nowdate){
        var MonthFirstDay=new Date(Nowdate.getFullYear(),Nowdate.getMonth(),1);
      var MonthFirstDay = new Date(
        Nowdate.getFullYear(),
        Nowdate.getMonth(),
        1
      );
        var M=Number(MonthFirstDay.getMonth())+1;
        if(M<10){
          M="0"+M;
        }
        return MonthFirstDay.getFullYear()+"-"+M+"-"+"0"+MonthFirstDay.getDate();
      return (
        MonthFirstDay.getFullYear() +
        "-" +
        M +
        "-" +
        "0" +
        MonthFirstDay.getDate()
      );
      },
      //数据导出
      handleExport() {
        this.$confirm("是否导出健康码数据?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        }).then(() => {
          window.open(`/api/healthcode/healthcode/export-healthcode?begTime=${this.$route.query.startTime}&endTime=${this.$route.query.endTime}&type=${this.$route.query.type}&timeDesc=${this.$route.query.timeDesc}`);
        window.open(
          `/api/healthcode/healthcode/export-healthcode?begTime=${this.$route.query.startTime}&endTime=${this.$route.query.endTime}&type=${this.$route.query.type}&timeDesc=${this.$route.query.timeDesc}`
        );
        });
      },
      //数据报表导出
      handleExportStatis() {
          let begTime = this.$route.query.startTime==undefined? '':this.$route.query.startTime;
          let endTime = this.$route.query.endTime==undefined? '':this.$route.query.endTime;
          let type = this.$route.query.type==undefined? '':this.$route.query.type;
          let timeDesc = this.$route.query.timeDesc==undefined? '':this.$route.query.timeDesc;
      let begTime =
        this.$route.query.startTime == undefined
          ? ""
          : this.$route.query.startTime;
      let endTime =
        this.$route.query.endTime == undefined ? "" : this.$route.query.endTime;
      let type =
        this.$route.query.type == undefined ? "" : this.$route.query.type;
      let timeDesc =
        this.$route.query.timeDesc == undefined
          ? ""
          : this.$route.query.timeDesc;
          //window.open(`http://localhost:8108/ureport/excel?_u=blade-healthcode.statis.xml.ureport.xml&begTime=${begTime}&endTime=${endTime}&type=${type}&timeDesc=${timeDesc}`);
          window.open(`https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-healthcode.statis.xml.ureport.xml&begTime=${begTime}&endTime=${endTime}&type=${type}&timeDesc=${timeDesc}`);
      window.open(
        `https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-healthcode.statis.xml.ureport.xml&begTime=${begTime}&endTime=${endTime}&type=${type}&timeDesc=${timeDesc}`
      );
      },
      onLoad(page, params={}) {
        const { dateTime } = this.query;
        let values = {
          ...params,
        };
        if (this.$route.query.status!=undefined && this.$route.query != undefined && this.$route.query != null && this.$route.query != "" ) {
      if (
        this.$route.query.status != undefined &&
        this.$route.query != undefined &&
        this.$route.query != null &&
        this.$route.query != ""
      ) {
            if (this.$route.query.type != undefined) {
              this.page.currentPage = 1;
              params = {
                status:this.$route.query.status,
                type:this.$route.query.type
              }
            type: this.$route.query.type,
          };
            } else {
              this.page.currentPage = 1;
              params = {
                type:this.$route.query.status
            type: this.$route.query.status,
              };
            }
            this.activeClass =4;
@@ -417,8 +470,8 @@
          params = {
            type: this.$route.query.type,
            begTime: this.$route.query.startTime,
            endTime: this.$route.query.endTime
          }
          endTime: this.$route.query.endTime,
        };
          this.activeClass =4;
        }
        // else{
@@ -431,7 +484,7 @@
        if(this.activeClass == 0 && this.query.dateTime==null){
          params = {
              status:this.activeClass,
          }
        };
        }
        if (dateTime) {
@@ -459,15 +512,15 @@
        }
        this.loading = true;
        getList(page.currentPage, page.pageSize,values).then(res => {
      getList(page.currentPage, page.pageSize, values).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
<style scoped>
src/views/parcel/parcel.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page="page"
@@ -20,8 +21,8 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <!-- <template slot-scope="{ type, size, row }" slot="menu">
        <el-button
@@ -56,21 +57,24 @@
        </template>
      <template slot="menuLeft">
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-download"
                      @click="handleExport">导出
          @click="handleExport"
          >导出
          </el-button>
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-pie-chart"
                      @click="handleExportStatis">导出报表
          @click="handleExportStatis"
          >导出报表
          </el-button>
        </template>
    </avue-crud>
    <template>
      <div>
@@ -78,20 +82,20 @@
              class="img"
              v-if="showViewer"
              :on-close="closeViewer"
              :url-list="['data:image/png;base64,'+imgUrl]" />
          :url-list="['data:image/png;base64,' + imgUrl]"
        />
      </div>
    </template>
  </basic-container>
</template>
<script>
  import {getList,exportParcelStatis, getParcelPic} from "@/api/parcel/parcel";
  import {mapGetters} from "vuex";
  import ElImageViewer from 'element-ui/packages/image/src/image-viewer'
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
  export default {
    name:'index',
  name: "index",
    components: { ElImageViewer },
    data() {
      return {
@@ -100,42 +104,42 @@
        search:{},
        showViewer: false, // 显示查看器
        activeClass: 0,
        imgUrl:'',
      imgUrl: "",
        loading: true,
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          menu:false,
          height:'auto',
        height: "auto",
          calcHeight: 54,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
          border: false,
          stripe:true,
        //stripe:true,
          index: true,
          viewBtn: true,
          selection: true,
          labelWidth:120,
          menuWidth:220,
          dialogClickModal: false,
          headerAlign: 'center',
          align: 'center',
        headerAlign: "center",
        align: "center",
          tree:true,
          column: [
            {
              label: '坐标',
              prop: 'test',
            label: "坐标",
            prop: "test",
              hide: true,
              span: 50,
              component: "avueMap",
              clickChild: (obj) => {
                this.form.jd = obj.latitude
                this.form.wd = obj.longitude
              this.form.jd = obj.latitude;
              this.form.wd = obj.longitude;
              },
            },
            {
@@ -149,7 +153,7 @@
            {
              label: "包裹图片KEY",
              prop: "imgUrl",
              hide:true
            hide: true,
            },
            // {
            //   label: '包裹图片',
@@ -188,9 +192,9 @@
                {
                  required: true,
                  message: "请输入时间",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "是否违禁",
@@ -198,13 +202,13 @@
              dicData: [
                {
                  label: "是",
                  value: 1
                value: 1,
                },
                {
                  label: "否",
                  value: 0
                value: 0,
                },
              ]
            ],
            },
            {
              label: "是否违禁",
@@ -218,21 +222,21 @@
              dicData: [
                {
                  label: "是",
                  value: "contraband"
                value: "contraband",
                },
                {
                  label: "否",
                  value: "normal"
                value: "normal",
                },
              ]
            ],
            },
            {
              label: "违禁包裹物品",
              prop: "decisioDiagramResultDetails",
            }
          ]
        },
        data: []
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -242,16 +246,16 @@
          addBtn: this.vaildData(null, false),
          viewBtn: this.vaildData(null, false),
          delBtn: this.vaildData(null, false),
          editBtn: this.vaildData(null, false)
        editBtn: this.vaildData(null, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      beforeOpen(done, type) {
@@ -275,9 +279,9 @@
      },
      rowClick(row){
        var that=this;
        getParcelPic(row.imgUrl).then(res => {
      getParcelPic(row.imgUrl).then((res) => {
            that.imgUrl = res.data.data.imgBase64;
            this.showViewer = true
        this.showViewer = true;
          });
      },
      selectionChange(list) {
@@ -297,45 +301,64 @@
        this.onLoad(this.page, this.query);
      },
      getStartTime(){
           if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
             return this.$route.query.startTime
      if (
        this.$route.query.startTime != undefined &&
        this.$route.query.startTime != null &&
        this.$route.query.startTime != ""
      ) {
        return this.$route.query.startTime;
           }
           // 当前时间
          var date = new Date();
          //年
          var Y = date.getFullYear();
          //月
          var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
          //日
          var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
           return Y + "-" + M + "-" + D+ " 00:00:00";
      },
      getEndTime(){
           if (this.$route.query.endTime != undefined && this.$route.query.endTime != null && this.$route.query.endTime != "" ) {
             return this.$route.query.endTime
      if (
        this.$route.query.endTime != undefined &&
        this.$route.query.endTime != null &&
        this.$route.query.endTime != ""
      ) {
        return this.$route.query.endTime;
           }
            // 当前时间
            var date = new Date();
            //年
            var Y = date.getFullYear();
            //月
            var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
            //日
            var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
            return Y + "-" + M + "-" + D+ " 23:59:59";
      },
      getIsKindParams(){
        if(this.$route.query.decisioDiagramResult && this.$route.query!='' && this.$route.query!=null && this.$route.query!=undefined){
      if (
        this.$route.query.decisioDiagramResult &&
        this.$route.query != "" &&
        this.$route.query != null &&
        this.$route.query != undefined
      ) {
          //回显
          return this.$route.query.decisioDiagramResult
        return this.$route.query.decisioDiagramResult;
        }
      },
      //给行加颜色
      rowStyle({row, column, rowIndex}){
         if(row.mechineMark==1){
           return {
             color:"#fe1515"
           }
          color: "#fe1515",
        };
         }
      },
      getParcelData(e) {
@@ -349,33 +372,42 @@
        if(e==0){
          params = {
            startTime:this.showToDay(today)+ " 00:00:00",
            endTime:this.showToDay(today)+ " 23:59:59"
          endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.dateTime=[this.showToDay(today)+ " 00:00:00",this.showToDay(today)+ " 23:59:59"]
        this.search.dateTime = [
          this.showToDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==1){
          params = {
            startTime:this.showWeekFirstDay(today)+ " 00:00:00",
            endTime:this.showToDay(today)+ " 23:59:59"
          endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.dateTime=[this.showWeekFirstDay(today)+ " 00:00:00",this.showToDay(today)+ " 23:59:59"]
        this.search.dateTime = [
          this.showWeekFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==2){
          params = {
            startTime:this.showMonthFirstDay(today)+ " 00:00:00",
            endTime:this.showToDay(today)+ " 23:59:59"
          endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.dateTime=[this.showMonthFirstDay(today)+ " 00:00:00",this.showToDay(today)+ " 23:59:59"]
        this.search.dateTime = [
          this.showMonthFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(this.search.decisioDiagramResult){
          params= {
            ... params,
            decisioDiagramResult:this.search.decisioDiagramResult
          }
          decisioDiagramResult: this.search.decisioDiagramResult,
        };
        }
        this.query = params;
        this.page.currentPage = 1;
@@ -410,31 +442,56 @@
      //本月第一天
      showMonthFirstDay(Nowdate){
        var MonthFirstDay=new Date(Nowdate.getFullYear(),Nowdate.getMonth(),1);
      var MonthFirstDay = new Date(
        Nowdate.getFullYear(),
        Nowdate.getMonth(),
        1
      );
        var M=Number(MonthFirstDay.getMonth())+1;
        if(M<10){
          M="0"+M;
        }
        return MonthFirstDay.getFullYear()+"-"+M+"-"+"0"+MonthFirstDay.getDate();
      return (
        MonthFirstDay.getFullYear() +
        "-" +
        M +
        "-" +
        "0" +
        MonthFirstDay.getDate()
      );
      },
      //数据导出
      handleExport() {
        this.$confirm("是否导出包裹数据?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        }).then(() => {
          window.open(`/api/parcel/parcel/export-parcel?startTime=${this.$route.query.startTime}&endTime=${this.$route.query.endTime}&decisioDiagramResult=${this.$route.query.decisioDiagramResult}`);
        window.open(
          `/api/parcel/parcel/export-parcel?startTime=${this.$route.query.startTime}&endTime=${this.$route.query.endTime}&decisioDiagramResult=${this.$route.query.decisioDiagramResult}`
        );
        });
      },
      //数据报表导出
      handleExportStatis() {
          let startTime = this.$route.query.startTime==undefined? '':this.$route.query.startTime;
          let endTime = this.$route.query.endTime==undefined? '':this.$route.query.endTime;
          let decisioDiagramResult = this.$route.query.decisioDiagramResult==undefined? '':this.$route.query.decisioDiagramResult;
          let timeDesc = this.$route.query.timeDesc==undefined? '':this.$route.query.timeDesc;
      let startTime =
        this.$route.query.startTime == undefined
          ? ""
          : this.$route.query.startTime;
      let endTime =
        this.$route.query.endTime == undefined ? "" : this.$route.query.endTime;
      let decisioDiagramResult =
        this.$route.query.decisioDiagramResult == undefined
          ? ""
          : this.$route.query.decisioDiagramResult;
      let timeDesc =
        this.$route.query.timeDesc == undefined
          ? ""
          : this.$route.query.timeDesc;
          //window.open(`http://localhost:8108/ureport/excel?_u=blade-parcel.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`);
          window.open(`https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-parcel.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`);
      window.open(
        `https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-parcel.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`
      );
      },
      onLoad(page, params={}) {
        const { dateTime } = this.query;
@@ -442,28 +499,41 @@
          ...params,
        };
        if (this.$route.query.decisioDiagramResult && this.$route.query!='' && this.$route.query!=null && this.$route.query!=undefined ) {
            if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
      if (
        this.$route.query.decisioDiagramResult &&
        this.$route.query != "" &&
        this.$route.query != null &&
        this.$route.query != undefined
      ) {
        if (
          this.$route.query.startTime != undefined &&
          this.$route.query.startTime != null &&
          this.$route.query.startTime != ""
        ) {
              this.page.currentPage = 1;
              params = {
                startTime:this.$route.query.startTime,
                endTime:this.$route.query.endTime,
                decisioDiagramResult:this.$route.query.decisioDiagramResult
              }
            decisioDiagramResult: this.$route.query.decisioDiagramResult,
          };
            } else {
              this.page.currentPage = 1;
              params = {
                decisioDiagramResult:this.$route.query.decisioDiagramResult
            decisioDiagramResult: this.$route.query.decisioDiagramResult,
              };
            }
            this.activeClass=4;
        }else{
            if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
        if (
          this.$route.query.startTime != undefined &&
          this.$route.query.startTime != null &&
          this.$route.query.startTime != ""
        ) {
              this.page.currentPage = 1;
              params = {
                startTime:this.$route.query.startTime,
                endTime:this.$route.query.endTime
              }
            endTime: this.$route.query.endTime,
          };
              this.activeClass=4;
            }
@@ -474,13 +544,16 @@
              //年
              var Y = date.getFullYear();
              //月
              var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
          var M =
            date.getMonth() + 1 < 10
              ? "0" + (date.getMonth() + 1)
              : date.getMonth() + 1;
              //日
              var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
              params = {
                startTime:Y + "-" + M + "-" + D + " 00:00:00",
                endTime:Y +"-" +M +"-" + D +  " 23:59:59"
              }
            endTime: Y + "-" + M + "-" + D + " 23:59:59",
          };
            }
        }
@@ -497,10 +570,9 @@
            ...params,
            ...this.query,
          };
        }
        this.loading = true;
        getList(page.currentPage, page.pageSize,values).then(res => {
      getList(page.currentPage, page.pageSize, values).then((res) => {
          const data = res.data.data;
          this.page.total = data.totalSize;
          this.data = data.data;
@@ -510,9 +582,9 @@
      },
      // 关闭查看器
      closeViewer() {
        this.showViewer = false
      }
    }
      this.showViewer = false;
    },
  },
  };
</script>
<style lang="scss">
src/views/parcel/parcelKind.vue
@@ -1,6 +1,7 @@
<template>
    <basic-container>
    <avue-crud :option="option"
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page="page"
@@ -20,7 +21,8 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <!-- <template slot-scope="{ type, size, row }" slot="menu">
        <el-button
          v-if="row.imgUrl != null || row.imgUrl != ''"
@@ -53,17 +55,21 @@
        </template>
       <template slot="menuLeft">
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-download"
                      @click="handleExport">导出
          @click="handleExport"
          >导出
          </el-button>
          <el-button type="warning"
        <el-button
          type="warning"
                      size="small"
                      plain
                      icon="el-icon-pie-chart"
                      @click="handleExportStatis">导出报表
          @click="handleExportStatis"
          >导出报表
          </el-button>
        </template>
    </avue-crud>
@@ -73,26 +79,25 @@
                     class="img"
                     v-if="showViewer"
                     :on-close="closeViewer"
                     :url-list="['data:image/png;base64,'+imgUrl]" />
          :url-list="['data:image/png;base64,' + imgUrl]"
        />
      </div>
    </template>
    </basic-container>
</template>
<script>
  import {getKindList, getParcelPic} from "@/api/parcel/parcel";
  import {mapGetters} from "vuex";
  import Vue from 'vue';
  import ElementUI from 'element-ui'
  import 'element-ui/lib/theme-chalk/index.css'
  import ElImageViewer from 'element-ui/packages/image/src/image-viewer'
  Vue.use(ElementUI)
import Vue from "vue";
import ElementUI from "element-ui";
import "element-ui/lib/theme-chalk/index.css";
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
Vue.use(ElementUI);
  export default {
    name:'index',
  name: "index",
    components: { ElImageViewer },
    data() {
      return {
@@ -101,42 +106,42 @@
        search:{},
        showViewer: false, // 显示查看器
        activeClass:0,
        imgUrl:'',
      imgUrl: "",
        loading: true,
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          menu:false,
          height:'auto',
        height: "auto",
          calcHeight: 54,
          tip: false,
          searchShow: true,
          searchMenuSpan: 4,
          menuWidth:150,
          border: false,
          stripe:true,
        //stripe:true,
          index: true,
          viewBtn: true,
          selection: true,
          labelWidth:150,
          dialogClickModal: false,
          headerAlign: 'center',
          align: 'center',
        headerAlign: "center",
        align: "center",
          tree:true,
          column: [
            {
              label: '坐标',
              prop: 'test',
            label: "坐标",
            prop: "test",
              hide: true,
              span: 100,
              component: "avueMap",
              clickChild: (obj) => {
                this.form.jd = obj.latitude
                this.form.wd = obj.longitude
              this.form.jd = obj.latitude;
              this.form.wd = obj.longitude;
              },
            },
            {
@@ -146,7 +151,7 @@
            {
              label: "包裹图片KEY",
              prop: "imgUrl",
              hide:true
            hide: true,
            },
            {
              label: "安检时间",
@@ -170,9 +175,9 @@
                {
                  required: true,
                  message: "请输入时间",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            // {
            //   label: "违禁类型",
@@ -194,27 +199,27 @@
            //   ]
            // },
            {
              label: '违禁品名称',
              prop: 'objName'
            label: "违禁品名称",
            prop: "objName",
            },
            {
              label: '违禁品编号',
              prop: 'objCode'
            label: "违禁品编号",
            prop: "objCode",
            },
            {
              label: '等级',
              prop: 'levName',
              span:120
            label: "等级",
            prop: "levName",
            span: 120,
            },
            {
              label: '坐标',
              prop: 'coords',
              span:500
            }
          ]
            label: "坐标",
            prop: "coords",
            span: 500,
          },
        ],
        },
        data: [],
        flag: false
      flag: false,
      };
    },
    computed: {
@@ -224,20 +229,19 @@
          addBtn: this.vaildData(null, false),
          viewBtn: this.vaildData(null, false),
          delBtn: this.vaildData(null, false),
          editBtn: this.vaildData(null, false)
        editBtn: this.vaildData(null, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      beforeOpen(done, type) {
        done();
      },
      searchReset() {
@@ -265,9 +269,9 @@
      },
      rowClick(row){
        var that=this;
        getParcelPic(row.imgUrl).then(res => {
      getParcelPic(row.imgUrl).then((res) => {
            that.imgUrl = res.data.data.imgBase64;
            this.showViewer = true
        this.showViewer = true;
          });
      },
      currentChange(currentPage){
@@ -280,29 +284,43 @@
        this.onLoad(this.page, this.query);
      },
      getStartTime(){
           if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
             return this.$route.query.startTime
      if (
        this.$route.query.startTime != undefined &&
        this.$route.query.startTime != null &&
        this.$route.query.startTime != ""
      ) {
        return this.$route.query.startTime;
           }
           // 当前时间
          var date = new Date();
          //年
          var Y = date.getFullYear();
          //月
          var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
          //日
          var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
           return Y + "-" + M + "-" + D+ " 00:00:00";
      },
      getEndTime(){
           if (this.$route.query.endTime != undefined && this.$route.query.endTime != null && this.$route.query.endTime != "" ) {
             return this.$route.query.endTime
      if (
        this.$route.query.endTime != undefined &&
        this.$route.query.endTime != null &&
        this.$route.query.endTime != ""
      ) {
        return this.$route.query.endTime;
           }
            // 当前时间
            var date = new Date();
            //年
            var Y = date.getFullYear();
            //月
            var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
      var M =
        date.getMonth() + 1 < 10
          ? "0" + (date.getMonth() + 1)
          : date.getMonth() + 1;
            //日
            var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
            return Y + "-" + M + "-" + D+ " 23:59:59";
@@ -318,26 +336,35 @@
        if(e==0){
          params = {
            startTime:this.showToDay(today)+ " 00:00:00",
            endTime:this.showToDay(today)+ " 23:59:59"
          endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.dateTime=[this.showToDay(today)+ " 00:00:00",this.showToDay(today)+ " 23:59:59"]
        this.search.dateTime = [
          this.showToDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==1){
          params = {
            startTime:this.showWeekFirstDay(today)+ " 00:00:00",
            endTime:this.showToDay(today)+ " 23:59:59"
          endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.dateTime=[this.showWeekFirstDay(today)+ " 00:00:00",this.showToDay(today)+ " 23:59:59"]
        this.search.dateTime = [
          this.showWeekFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if(e==2){
          params = {
            startTime:this.showMonthFirstDay(today)+ " 00:00:00",
            endTime:this.showToDay(today)+ " 23:59:59"
          endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.dateTime=[this.showMonthFirstDay(today)+ " 00:00:00",this.showToDay(today)+ " 23:59:59"]
        this.search.dateTime = [
          this.showMonthFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        this.query = params;
        this.page.currentPage = 1;
@@ -372,38 +399,60 @@
      //本月第一天
      showMonthFirstDay(Nowdate){
        var MonthFirstDay=new Date(Nowdate.getFullYear(),Nowdate.getMonth(),1);
      var MonthFirstDay = new Date(
        Nowdate.getFullYear(),
        Nowdate.getMonth(),
        1
      );
        var M=Number(MonthFirstDay.getMonth())+1;
        if(M<10){
          M="0"+M;
        }
        return MonthFirstDay.getFullYear()+"-"+M+"-"+"0"+MonthFirstDay.getDate();
      return (
        MonthFirstDay.getFullYear() +
        "-" +
        M +
        "-" +
        "0" +
        MonthFirstDay.getDate()
      );
      },
      //给行加颜色
      rowStyle({row, column, rowIndex}){
        return {
          color:"#fe1515"
        }
        color: "#fe1515",
      };
      },
      //数据导出
      handleExport() {
        this.$confirm("是否导出违禁品数据?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        }).then(() => {
          window.open(`/api/parcel/parcel/export-parcelKind?startTime=${this.$route.query.startTime}&endTime=${this.$route.query.endTime}&decisioDiagramResult=${this.$route.query.decisioDiagramResult}&timeDesc=${this.$route.query.timeDesc}`);
        window.open(
          `/api/parcel/parcel/export-parcelKind?startTime=${this.$route.query.startTime}&endTime=${this.$route.query.endTime}&decisioDiagramResult=${this.$route.query.decisioDiagramResult}&timeDesc=${this.$route.query.timeDesc}`
        );
        });
      },
      //数据报表导出
      handleExportStatis() {
          let startTime = this.$route.query.startTime==undefined? '':this.$route.query.startTime;
          let endTime = this.$route.query.endTime==undefined? '':this.$route.query.endTime;
          let decisioDiagramResult = this.$route.query.decisioDiagramResult==undefined? '':this.$route.query.decisioDiagramResult;
      let startTime =
        this.$route.query.startTime == undefined
          ? ""
          : this.$route.query.startTime;
      let endTime =
        this.$route.query.endTime == undefined ? "" : this.$route.query.endTime;
      let decisioDiagramResult =
        this.$route.query.decisioDiagramResult == undefined
          ? ""
          : this.$route.query.decisioDiagramResult;
          let timeDesc = this.$route.query.timeDesc;
          //window.open(`http://localhost:8108/ureport/excel?_u=blade-parcelKind.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`);
          //window.open(`http://localhost:8108/ureport/preview?_u=blade-parcelKind.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`);
          window.open(`https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-parcelKind.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`);
      window.open(
        `https://web.byisf.com/api/blade-report/ureport/preview?_u=blade-parcelKind.statis.ureport.xml&startTime=${startTime}&endTime=${endTime}&decisioDiagramResult=${decisioDiagramResult}&timeDesc=${timeDesc}`
      );
      },
      onLoad(page, params={}) {
        const { dateTime } = this.query;
@@ -411,18 +460,27 @@
          ...params,
        };
        if (this.$route.query.decisioDiagramResult && this.$route.query != undefined && this.$route.query != null && this.$route.query != "" ) {
            if (this.$route.query.startTime != undefined && this.$route.query.startTime != null && this.$route.query.startTime != "" ) {
      if (
        this.$route.query.decisioDiagramResult &&
        this.$route.query != undefined &&
        this.$route.query != null &&
        this.$route.query != ""
      ) {
        if (
          this.$route.query.startTime != undefined &&
          this.$route.query.startTime != null &&
          this.$route.query.startTime != ""
        ) {
              this.page.currentPage = 1;
              params = {
                startTime:this.$route.query.startTime,
                endTime:this.$route.query.endTime,
                decisioDiagramResult:this.$route.query.decisioDiagramResult
              }
            decisioDiagramResult: this.$route.query.decisioDiagramResult,
          };
            } else {
              this.page.currentPage = 1;
              params = {
                decisioDiagramResult:this.$route.query.decisioDiagramResult
            decisioDiagramResult: this.$route.query.decisioDiagramResult,
              };
            }
            this.activeClass=4;
@@ -435,13 +493,16 @@
          //年
          var Y = date.getFullYear();
          //月
          var M = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
        var M =
          date.getMonth() + 1 < 10
            ? "0" + (date.getMonth() + 1)
            : date.getMonth() + 1;
          //日
          var D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
          params = {
            startTime:Y + "-" + M + "-" + D + " 00:00:00",
            endTime:Y +"-" +M +"-" + D +  " 23:59:59"
          }
          endTime: Y + "-" + M + "-" + D + " 23:59:59",
        };
        }
        if (dateTime) {
@@ -468,7 +529,7 @@
        }
        this.loading = true;
        getKindList(page.currentPage, page.pageSize,values).then(res => {
      getKindList(page.currentPage, page.pageSize, values).then((res) => {
          const data = res.data.data;
          this.page.total = data.totalSize;
          this.data = data.data;
@@ -478,9 +539,9 @@
      },
      // 关闭查看器
      closeViewer() {
        this.showViewer = false
      }
    }
      this.showViewer = false;
    },
  },
  };
</script>
<style lang="scss">
src/views/realTimePolice/real.vue
@@ -22,8 +22,8 @@
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @on-load="onLoad"
      @row-click="rowClick">
      @row-click="rowClick"
    >
      <template slot="menuLeft">
        <el-button
          type="danger"
@@ -86,9 +86,15 @@
      <template slot-scope="{ row }" slot="jtype">
        <el-tag
        >{{
          row.jtype == "0" || row.jtype == "" ? "未派发" : row.jtype == "1" && (row.securityId == null || row.securityId
          == "")
          ? "未接收" : row.jtype == "1" && (row.securityId != null || row.securityId != "") ? "已接收" : "已处置"
            row.jtype == "0" || row.jtype == ""
              ? "未派发"
              : row.jtype == "1" &&
                (row.securityId == null || row.securityId == "")
              ? "未接收"
              : row.jtype == "1" &&
                (row.securityId != null || row.securityId != "")
              ? "已接收"
              : "已处置"
          }}
        </el-tag>
      </template>
@@ -155,7 +161,7 @@
          labelWidth: "100",
          size: "mini",
          border: false,
          stripe: true,
        //stripe:true,
          menuWidth: 240,
          dialogWidth: 950,
          tip: false,
@@ -185,16 +191,16 @@
                "/api/blade-system/dict-biz/child-list?parentId=1356523651644043266",
              control:(val,form)=>{
                if (val){
                  debugger
                debugger;
                }
                return {
                  text2:{
                    display:true
                  display: true,
                  },
                  text3:{
                    label:'内容3'
                  }
                }
                  label: "内容3",
                },
              };
              },
            },
            {
@@ -204,11 +210,13 @@
              format: "yyyy-MM-dd HH:mm:ss",
              valueFormat: "yyyy-MM-dd HH:mm:ss",
              prop: "alarmTime",
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择报警时间",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
            },
            {
              label: "报警时间",
@@ -231,7 +239,8 @@
                  trigger: "blur",
                },
              ],
            }, {
          },
          {
              label: "备注",
              prop: "bz",
              span: 24,
@@ -240,11 +249,13 @@
              label: "地址",
              prop: "place",
              span: 10,
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择地址",
                trigger: "blur"
              }],
                trigger: "blur",
              },
            ],
            },
            {
              label: null,
@@ -265,7 +276,7 @@
              width: "100",
              labelWidth: "120",
              formatter: (row, value, label, column) => {
                return value = value.substring(0, 11);
              return (value = value.substring(0, 11));
              },
              span: 7,
            },
@@ -275,7 +286,7 @@
              hide: true,
              prop: "wd",
              formatter: (row, value, label, column) => {
                return value = value.substring(0, 10);
              return (value = value.substring(0, 10));
              },
              span: 5,
            },
@@ -380,7 +391,7 @@
              multiple: true,
              dicUrl: "/api/catalogs/catalogs/getBigTree",
              props: {
                label: "title"
              label: "title",
              },
              width: 72,
              hide: true,
@@ -398,9 +409,9 @@
              filter:false,
              dicUrl: "/api/routeIn/routein/tree",
              props: {
                label: "title"
              label: "title",
              },
            }
          },
          ],
        },
        data: [],
@@ -417,7 +428,7 @@
            //重新加载一次页面详情数据,解决新的省市区无法写入问题
            //判断是新增还是修改
            if (that.isEdit) {
              getclient(this.form.id).then(res => {
            getclient(this.form.id).then((res) => {
                // that.province = res.data.data.province;
                // that.city = res.data.data.city;
                // that.district = res.data.data.district;
@@ -435,10 +446,16 @@
            var address = val.formattedAddress.toString();
            if (address.search("县") != -1) {
              this.form.place = address.substring(address.indexOf("县") + 1, address.length);
            this.form.place = address.substring(
              address.indexOf("县") + 1,
              address.length
            );
            }
            if (address.search("区") != -1) {
              this.form.place = address.substring(address.indexOf("区") + 1, address.length);
            this.form.place = address.substring(
              address.indexOf("区") + 1,
              address.length
            );
            }
            //写入新的省市区
            that.form.province = val.addressComponent.province;
@@ -458,22 +475,24 @@
        },
        immediate: true,
      },
      'form.alarmType':{
    "form.alarmType": {
        handler(val){
          var xllx =this.findObject(this.option.column,'xllx')
        var xllx = this.findObject(this.option.column, "xllx");
          if(val==="巡逻任务"){
            xllx.display=true
            xllx.rules=[{
          xllx.display = true;
          xllx.rules = [
            {
              required: true,
              message: "请选择巡逻路线",
              trigger: "blur"
            }]
              trigger: "blur",
            },
          ];
          }else{
            xllx.display=false
            xllx.rules=[]
          xllx.display = false;
          xllx.rules = [];
          }
        },
        immediate: true
      immediate: true,
      },
    },
    computed: {
@@ -499,7 +518,6 @@
    },
    methods: {
      rowSave(row, done, loading) {
        if (typeof row.securityArr != "string") {
          var security = "";
          row.securityArr.forEach((item) => {
@@ -535,7 +553,6 @@
        );
      },
      rowUpdate(row, index, done, loading) {
        var userId = JSON.parse(
          window.localStorage.getItem("群防群控后台管理系统-userInfo")
        ).content.real_name;
@@ -871,7 +888,10 @@
            endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.releaseTimeRange = [this.showToDay(today) + " 00:00:00", this.showToDay(today) + " 23:59:59"]
        this.search.releaseTimeRange = [
          this.showToDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if (e == 1) {
          params = {
@@ -879,7 +899,10 @@
            endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.releaseTimeRange = [this.showWeekFirstDay(today) + " 00:00:00", this.showToDay(today) + " 23:59:59"]
        this.search.releaseTimeRange = [
          this.showWeekFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        if (e == 2) {
          params = {
@@ -887,7 +910,10 @@
            endTime: this.showToDay(today) + " 23:59:59",
          };
          //修改搜索框中的值
          this.search.releaseTimeRange = [this.showMonthFirstDay(today) + " 00:00:00", this.showToDay(today) + " 23:59:59"]
        this.search.releaseTimeRange = [
          this.showMonthFirstDay(today) + " 00:00:00",
          this.showToDay(today) + " 23:59:59",
        ];
        }
        this.query = params;
        this.page.currentPage = 1;
@@ -922,12 +948,23 @@
      //本月第一天
      showMonthFirstDay(Nowdate) {
        var MonthFirstDay = new Date(Nowdate.getFullYear(), Nowdate.getMonth(), 1);
      var MonthFirstDay = new Date(
        Nowdate.getFullYear(),
        Nowdate.getMonth(),
        1
      );
        var M = Number(MonthFirstDay.getMonth()) + 1;
        if (M < 10) {
          M = "0" + M;
        }
        return MonthFirstDay.getFullYear() + "-" + M + "-" + "0" + MonthFirstDay.getDate();
      return (
        MonthFirstDay.getFullYear() +
        "-" +
        M +
        "-" +
        "0" +
        MonthFirstDay.getDate()
      );
      },
      getBZdata(e) {
        this.activeClass = e;
@@ -999,7 +1036,11 @@
        this.showMap = true;
        this.$nextTick(() => {
          this.$refs.mapDiv.onload = () => {
            window.frames[1].init("ClientManagement", {x: row.jd, y: row.wd, clientID: row.deviceNumber});
          window.frames[1].init("ClientManagement", {
            x: row.jd,
            y: row.wd,
            clientID: row.deviceNumber,
          });
          };
        });
      },
@@ -1125,10 +1166,11 @@
        );
        //window.open(`http://localhost:8108/ureport/excel?_u=blade-alarm.statis.ureport.xml&beginTime=${beginTime}&endTime=${endTime}&waringType=${waringType}&timeDesc=${timeDesc}`);
      },
      rowClick(val) {//行点击事件
    rowClick(val) {
      //行点击事件
        //警情追踪
        this.$router.push({path: "/policeTracking/track", query: val});
      }
    },
    },
  };
</script>
src/views/realTimePolice/realHistory.vue
@@ -117,7 +117,7 @@
        menuWidth: 240,
        size: "mini",
        border: false,
        stripe:true,
        //stripe:true,
        labelWidth: "100",
        dialogWidth: 950,
        tip: false,
@@ -614,7 +614,6 @@
</script>
<style>
.old-video-dialog-box {
  position: absolute !important;
  top: 0px !important;
src/views/security/security copy.vue
@@ -1,24 +1,50 @@
<template>
  <basic-container>
    <avue-crud :option="option" :table-loading="loading" :data="data" :page="page" :permission="permissionList"
               :before-open="beforeOpen" v-model="form" ref="crud" @row-update="rowUpdate" @row-save="rowSave" @row-del="rowDel"
               @search-change="searchChange" @search-reset="searchReset" @selection-change="selectionChange" @current-change="currentChange"
               @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad">
    <avue-crud
      :option="option"
      :table-loading="loading"
      :data="data"
      :page="page"
      :permission="permissionList"
      :before-open="beforeOpen"
      v-model="form"
      ref="crud"
      @row-update="rowUpdate"
      @row-save="rowSave"
      @row-del="rowDel"
      @search-change="searchChange"
      @search-reset="searchReset"
      @selection-change="selectionChange"
      @current-change="currentChange"
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @on-load="onLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger" size="small" icon="el-icon-delete" plain v-if="permission.security_delete" @click="handleDelete">删
          除
        <el-button
          type="danger"
          size="small"
          icon="el-icon-delete"
          plain
          v-if="permission.security_delete"
          @click="handleDelete"
          >删 除
        </el-button>
      </template>
      <template slot-scope="{ row }" slot="jtype">
        <el-tag>{{
          row.jtype == "0" ? "否" : row.jtype == "1" ? "是" : "无"
          }}
        <el-tag
          >{{ row.jtype == "0" ? "否" : row.jtype == "1" ? "是" : "无" }}
        </el-tag>
      </template>
      <template slot-scope="{ type, size, row }" slot="menu">
        <el-button icon="el-icon-location-outline" :size="size" :type="type" @click.stop="handleMap(row)">编辑电子围栏
        <el-button
          icon="el-icon-location-outline"
          :size="size"
          :type="type"
          @click.stop="handleMap(row)"
          >编辑电子围栏
        </el-button>
      </template>
    </avue-crud>
@@ -56,100 +82,114 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        dialogVisible: false,
        selectionList: [],
        option: {
          height: 'auto',
        height: "auto",
          calcHeight: 54,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
          menuWidth:300,
          border: false,
          stripe: true,
        //stripe:true,
          index: true,
          viewBtn: true,
          selection: true,
          dialogClickModal: false,
          column: [{
        column: [
          {
            label: "账号",
            prop: "account",
            rules: [{
            rules: [
              {
              required: true,
              message: "请输入账号",
              trigger: "blur"
            }]
                trigger: "blur",
              },
            ],
          },
            {
              label: "人员编号",
              prop: "code",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入人员编号",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "人员姓名",
              prop: "realName",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入名称",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "所属部门",
              prop: "deptName"
            prop: "deptName",
            },
            {
              label: "性别",
              prop: "sex",
              type: "select",
              dicData: [{
            dicData: [
              {
                label: "男",
                value: 1
                value: 1,
              },
                {
                  label: "女",
                  value: 2
                value: 2,
                },
              ],
            },
            {
              label: "联系电话",
              prop: "phone",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入联系电话",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "邮箱",
              prop: "email",
              rules: [{
            rules: [
              {
                required: false,
                message: "请输入邮箱",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "生日",
              prop: "birthday",
              rules: [{
            rules: [
              {
                required: false,
                message: "请选择",
                trigger: "blur"
              }]
            }
          ]
                trigger: "blur",
        },
        data: []
            ],
          },
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -159,49 +199,55 @@
          addBtn: this.vaildData(this.permission.security_add, true),
          viewBtn: this.vaildData(this.permission.security_view, false),
          delBtn: this.vaildData(this.permission.security_delete, true),
          editBtn: this.vaildData(this.permission.security_edit, true)
        editBtn: this.vaildData(this.permission.security_edit, true),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      rowSave(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          loading();
          window.console.log(error);
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          loading();
          console.log(error);
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -210,7 +256,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -234,20 +280,19 @@
                window.frames[1].init("SecurityMap", {
                                x: rwjd,
                                y: rwwd,
                                code:row.code
                code: row.code,
                            });
              }else{
                window.frames[1].init("SecurityMap", {
                                x: row.jd,
                                y: row.wd,
                                code:row.code
                code: row.code,
                            });
              }
            } else {
              console.log(`没有找到到window.frames[1].init`)
            console.log(`没有找到到window.frames[1].init`);
            }
          }
        };
        });
      },
      handleDelete() {
@@ -258,7 +303,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -267,14 +312,14 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDetail(this.form.id).then(res => {
        getDetail(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
@@ -308,14 +353,18 @@
      },
      onLoad(page, params = {}) {
        this.loading = true;
        getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
      getList(
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query)
      ).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/security/security.vue
@@ -11,7 +11,8 @@
    </el-col> -->
    <el-col>
      <basic-container>
        <avue-crud :option="option"
        <avue-crud
          :option="option"
                   :search.sync="search"
                   :table-loading="loading"
                   :data="data"
@@ -29,85 +30,99 @@
                   @current-change="currentChange"
                   @size-change="sizeChange"
                   @refresh-change="refreshChange"
                   @on-load="onLoad">
          @on-load="onLoad"
        >
          <template slot="menuLeft">
            <el-button type="danger"
            <el-button
              type="danger"
                       size="small"
                       plain
                       icon="el-icon-delete"
                       v-if="permission.user_delete"
                       @click="handleDelete">删 除
              @click="handleDelete"
              >删 除
            </el-button>
            <el-button type="info"
            <el-button
              type="info"
                       size="small"
                       plain
                       v-if="permission.user_reset"
                       icon="el-icon-refresh"
                       @click="handleReset">密码重置
              @click="handleReset"
              >密码重置
            </el-button>
          </template>
          <template slot-scope="{row}"
                    slot="tenantName">
          <template slot-scope="{ row }" slot="tenantName">
            <el-tag>{{row.tenantName}}</el-tag>
          </template>
          <template slot-scope="{row}"
                    slot="roleName">
          <template slot-scope="{ row }" slot="roleName">
            <el-tag>{{row.roleName}}</el-tag>
          </template>
          <template slot-scope="{row}"
                    slot="deptName">
          <template slot-scope="{ row }" slot="deptName">
            <el-tag>{{row.deptName}}</el-tag>
          </template>
          <template slot-scope="{row}"
                    slot="userTypeName">
          <template slot-scope="{ row }" slot="userTypeName">
            <el-tag>{{row.userTypeName}}</el-tag>
          </template>
          <template slot-scope="{ row }" slot="online_status">
            <el-tag
            >{{
              row.online_status == "0" ? "离线" : row.online_status == "1" ? "在线" : "离线"
                row.online_status == "0"
                  ? "离线"
                  : row.online_status == "1"
                  ? "在线"
                  : "离线"
              }}
            </el-tag>
          </template>
          <template slot-scope="{ row }" slot="sex">
            <el-tag
            >{{
              row.sex == 1 ? "男" : "女"
              }}
            </el-tag>
            <el-tag>{{ row.sex == 1 ? "男" : "女" }} </el-tag>
          </template>
          <template slot-scope="{ type, size, row }" slot="menu">
            <el-button icon="el-icon-location-outline" :size="size" :type="type" @click.stop="handleMap(row)">编辑电子围栏
            <el-button
              icon="el-icon-location-outline"
              :size="size"
              :type="type"
              @click.stop="handleMap(row)"
              >编辑电子围栏
          </el-button>
      </template>
        </avue-crud>
        <el-dialog title="用户角色配置"
        <el-dialog
          title="用户角色配置"
                   append-to-body
                   :visible.sync="roleBox"
                   width="345px">
          <el-tree :data="roleGrantList"
          width="345px"
        >
          <el-tree
            :data="roleGrantList"
                   show-checkbox
                   check-strictly
                   default-expand-all
                   node-key="id"
                   ref="treeRole"
                   :default-checked-keys="roleTreeObj"
                   :props="props">
            :props="props"
          >
          </el-tree>
          <span slot="footer" class="dialog-footer">
            <el-button @click="roleBox = false">取 消</el-button>
            <el-button type="primary"
                       @click="submitRole">确 定</el-button>
            <el-button type="primary" @click="submitRole">确 定</el-button>
          </span>
        </el-dialog>
        <el-dialog title="用户数据导入"
        <el-dialog
          title="用户数据导入"
                   append-to-body
                   :visible.sync="excelBox"
                   width="555px">
          <avue-form :option="excelOption" v-model="excelForm" :upload-after="uploadAfter">
          width="555px"
        >
          <avue-form
            :option="excelOption"
            v-model="excelForm"
            :upload-after="uploadAfter"
          >
            <template slot="excelTemplate">
              <el-button type="primary" @click="handleTemplate">
                点击下载<i class="el-icon-download el-icon--right"></i>
@@ -115,10 +130,13 @@
            </template>
          </avue-form>
        </el-dialog>
        <el-dialog title="用户平台配置"
        <el-dialog
          title="用户平台配置"
                   append-to-body
                   :visible.sync="platformBox">
          <avue-crud :option="platformOption"
          :visible.sync="platformBox"
        >
          <avue-crud
            :option="platformOption"
                     :table-loading="platformLoading"
                     :data="platformData"
                     ref="platformCrud"
@@ -133,19 +151,22 @@
                     @current-change="platformCurrentChange"
                     @size-change="platformSizeChange"
                     @refresh-change="platformRefreshChange"
                     @on-load="platformOnLoad">
            <template slot-scope="{row}"
                      slot="tenantName">
            @on-load="platformOnLoad"
          >
            <template slot-scope="{ row }" slot="tenantName">
              <el-tag>{{row.tenantName}}</el-tag>
            </template>
            <template slot-scope="{row}"
                      slot="userTypeName">
            <template slot-scope="{ row }" slot="userTypeName">
              <el-tag>{{row.userTypeName}}</el-tag>
            </template>
          </avue-crud>
        </el-dialog>
        <el-drawer title="电子地图" append-to-body="true" :visible.sync="showMap">
        <el-drawer
          title="电子地图"
          append-to-body="true"
          :visible.sync="showMap"
        >
          <iframe
                    id="securityMap"
                    ref="securityMap"
@@ -170,30 +191,30 @@
    updatePlatform,
    add,
    grant,
    resetPassword
  resetPassword,
  } from "@/api/system/user";
    import {getList} from "@/api/security/security";
  import {getDeptTree, getDeptLazyTree} from "@/api/system/dept";
  import {getRoleTree} from "@/api/system/role";
  import {getPostList} from "@/api/system/post";
  import {mapGetters} from "vuex";
  import website from '@/config/website';
  import {getToken} from '@/util/auth';
import website from "@/config/website";
import { getToken } from "@/util/auth";
  export default {
    data() {
      const validatePass = (rule, value, callback) => {
        if (value === '') {
          callback(new Error('请输入密码'));
      if (value === "") {
        callback(new Error("请输入密码"));
        } else {
          callback();
        }
      };
      const validatePass2 = (rule, value, callback) => {
        if (value === '') {
          callback(new Error('请再次输入密码'));
      if (value === "") {
        callback(new Error("请再次输入密码"));
        } else if (value !== this.form.password) {
          callback(new Error('两次输入密码不一致!'));
        callback(new Error("两次输入密码不一致!"));
        } else {
          callback();
        }
@@ -215,12 +236,12 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        platformPage: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        init: {
          roleTree: [],
@@ -228,44 +249,46 @@
        },
        props: {
          label: "title",
          value: "key"
        value: "key",
        },
        roleGrantList: [],
        roleTreeObj: [],
        treeDeptId: '',
      treeDeptId: "",
        treeData: [],
        treeOption: {
          nodeKey: 'id',
        nodeKey: "id",
          lazy: true,
          treeLoad: function (node, resolve) {
            const parentId = (node.level === 0) ? 0 : node.data.id;
            getDeptLazyTree(parentId).then(res => {
              resolve(res.data.data.map(item => {
          const parentId = node.level === 0 ? 0 : node.data.id;
          getDeptLazyTree(parentId).then((res) => {
            resolve(
              res.data.data.map((item) => {
                return {
                  ...item,
                  leaf: !item.hasChildren
                }
              }))
                  leaf: !item.hasChildren,
                };
              })
            );
            });
          },
          addBtn: false,
          menu: false,
          size: 'small',
        size: "small",
          props: {
            labelText: '标题',
            label: 'title',
            value: 'value',
            children: 'children'
          }
          labelText: "标题",
          label: "title",
          value: "value",
          children: "children",
        },
        },
        option: {
          height: 'auto',
        height: "auto",
          calcHeight: 54,
          tip: false,
          searchShow: true,
          searchMenuSpan: 6,
          border: false,
          stripe: true,
        //stripe:true,
          index: true,
          selection: true,
          viewBtn: true,
@@ -278,68 +301,68 @@
              prop: "account",
              searchSpan:4,
              search: true,
              display: false
            display: false,
            },
            {
              label: "人员编号",
              prop: "code",
              search: true,
              searchSpan:4,
              display: false
            display: false,
            },
            {
              label: "用户姓名",
              prop: "realName",
              search: true,
              searchSpan:4,
              display: false
            display: false,
            },
            {
              label: "所属部门",
              prop: "deptName",
              slot: true,
              display: false,
              width:260
            width: 260,
            },
             {
              label: "在线状态",
              prop: "online_status",
              slot: true,
              display: false
            display: false,
            },
            {
              label: "性别",
              prop: "sex",
              type: "select",
              slot:true,
              display: false
            display: false,
            },
            {
              label: "联系电话",
              prop: "phone",
              display: false
            display: false,
            },
            {
              label: "邮箱",
              prop: "email",
              display: false
            display: false,
            },
            {
              label: "生日",
              prop: "birthday",
              display: false
            display: false,
            },
            {
              label: "创建时间",
              prop: "createTime",
              display: false
            }
            display: false,
          },
          ],
          group: [
            {
              label: '基础信息',
              prop: 'baseInfo',
              icon: 'el-icon-user-solid',
            label: "基础信息",
            prop: "baseInfo",
            icon: "el-icon-user-solid",
              column: [
                {
                  label: "所属客户",
@@ -348,27 +371,31 @@
                  dicUrl: "/api/blade-system/tenant/select",
                  props: {
                    label: "tenantName",
                    value: "tenantId"
                  value: "tenantId",
                  },
                  hide: !website.tenantMode,
                  addDisplay: website.tenantMode,
                  editDisplay: website.tenantMode,
                  viewDisplay: website.tenantMode,
                  rules: [{
                rules: [
                  {
                    required: true,
                    message: "请输入所属租户",
                    trigger: "click"
                  }],
                    trigger: "click",
                  },
                ],
                  span: 24,
                },
                {
                  label: "登录账号",
                  prop: "account",
                  rules: [{
                rules: [
                  {
                    required: true,
                    message: "请输入登录账号",
                    trigger: "blur"
                  }],
                    trigger: "blur",
                  },
                ],
                },
                {
                  label: "用户平台",
@@ -376,73 +403,84 @@
                  dicUrl: "/api/blade-system/dict/dictionary?code=user_type",
                  props: {
                    label: "dictValue",
                    value: "dictKey"
                  value: "dictKey",
                  },
                  dataType: "number",
                  slot: true,
                  prop: "userType",
                  rules: [{
                rules: [
                  {
                    required: true,
                    message: "请选择用户平台",
                    trigger: "blur"
                  }]
                    trigger: "blur",
                  },
                ],
                },
                {
                  label: '密码',
                  prop: 'password',
                label: "密码",
                prop: "password",
                  hide: true,
                  editDisplay: false,
                  viewDisplay: false,
                  rules: [{required: true, validator: validatePass, trigger: 'blur'}]
                rules: [
                  { required: true, validator: validatePass, trigger: "blur" },
                ],
                },
                {
                  label: '确认密码',
                  prop: 'password2',
                label: "确认密码",
                prop: "password2",
                  hide: true,
                  editDisplay: false,
                  viewDisplay: false,
                  rules: [{required: true, validator: validatePass2, trigger: 'blur'}]
                rules: [
                  { required: true, validator: validatePass2, trigger: "blur" },
                ],
                },
              ]
            ],
            },
            {
              label: '详细信息',
              prop: 'detailInfo',
              icon: 'el-icon-s-order',
            label: "详细信息",
            prop: "detailInfo",
            icon: "el-icon-s-order",
              column: [
                {
                  label: "用户昵称",
                  prop: "name",
                  hide: true,
                  rules: [{
                rules: [
                  {
                    required: true,
                    message: "请输入用户昵称",
                    trigger: "blur"
                  }]
                    trigger: "blur",
                  },
                ],
                },
                {
                  label: "用户姓名",
                  prop: "realName",
                  rules: [{
                rules: [
                  {
                    required: true,
                    message: "请输入用户姓名",
                    trigger: "blur"
                  }, {
                    trigger: "blur",
                  },
                  {
                    min: 2,
                    max: 5,
                    message: '姓名长度在2到5个字符'
                  }]
                    message: "姓名长度在2到5个字符",
                  },
                ],
                },
                {
                  label: "手机号码",
                  prop: "phone",
                  overHidden: true
                overHidden: true,
                },
                {
                  label: "电子邮箱",
                  prop: "email",
                  hide: true,
                  overHidden: true
                overHidden: true,
                },
                {
                  label: "用户性别",
@@ -451,18 +489,18 @@
                  dicData: [
                    {
                      label: "男",
                      value: 1
                    value: 1,
                    },
                    {
                      label: "女",
                      value: 2
                    value: 2,
                    },
                    {
                      label: "未知",
                      value: 3
                    }
                    value: 3,
                  },
                  ],
                  hide: true
                hide: true,
                },
                {
                  label: "用户生日",
@@ -470,20 +508,20 @@
                  prop: "birthday",
                  format: "yyyy-MM-dd hh:mm:ss",
                  valueFormat: "yyyy-MM-dd hh:mm:ss",
                  hide: true
                hide: true,
                },
                {
                  label: "账号状态",
                  prop: "statusName",
                  hide: true,
                  display: false
                }
              ]
                display: false,
              },
            ],
            },
            {
              label: '职责信息',
              prop: 'dutyInfo',
              icon: 'el-icon-s-custom',
            label: "职责信息",
            prop: "dutyInfo",
            icon: "el-icon-s-custom",
              column: [
                {
                  label: "用户编号",
@@ -496,7 +534,7 @@
                  type: "tree",
                  dicData: [],
                  props: {
                    label: "title"
                  label: "title",
                  },
                  checkStrictly: true,
                  slot: true,
@@ -516,15 +554,17 @@
                  //multiple: true,
                  dicData: [],
                  props: {
                    label: "title"
                  label: "title",
                  },
                  checkStrictly: true,
                  slot: true,
                  rules: [{
                rules: [
                  {
                    required: true,
                    message: "请选择所属部门",
                    trigger: "click"
                  }]
                    trigger: "click",
                  },
                ],
                },
                {
                  label: "所属岗位",
@@ -534,13 +574,12 @@
                  dicData: [],
                  props: {
                    label: "postName",
                    value: "id"
                  value: "id",
                  },
                },
              ]
            ],
            },
          ]
        ],
        },
        data: [],
        platformQuery: {},
@@ -557,31 +596,31 @@
          viewBtn: true,
          dialogClickModal: false,
          menuWidth: 120,
          editBtnText: '配置',
        editBtnText: "配置",
          column: [
            {
              label: "登录账号",
              prop: "account",
              search: true,
              display: false
            display: false,
            },
            {
              label: "所属租户",
              prop: "tenantName",
              slot: true,
              display: false
            display: false,
            },
            {
              label: "用户姓名",
              prop: "realName",
              search: true,
              display: false
            display: false,
            },
            {
              label: "用户平台",
              prop: "userTypeName",
              slot: true,
              display: false
            display: false,
            },
            {
              label: "用户平台",
@@ -589,18 +628,20 @@
              dicUrl: "/api/blade-system/dict/dictionary?code=user_type",
              props: {
                label: "dictValue",
                value: "dictKey"
              value: "dictKey",
              },
              dataType: "number",
              search: true,
              hide: true,
              display: false,
              prop: "userType",
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择用户平台",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "用户拓展",
@@ -620,17 +661,17 @@
          emptyBtn: false,
          column: [
            {
              label: '模板上传',
              prop: 'excelFile',
              type: 'upload',
            label: "模板上传",
            prop: "excelFile",
            type: "upload",
              drag: true,
              loadText: '模板上传中,请稍等',
            loadText: "模板上传中,请稍等",
              span: 24,
              propsHttp: {
                res: 'data'
              res: "data",
              },
              tip: '请上传 .xls,.xlsx 标准格式文件',
              action: "/api/blade-user/import-user"
            tip: "请上传 .xls,.xlsx 标准格式文件",
            action: "/api/blade-user/import-user",
            },
            {
              label: "数据覆盖",
@@ -641,12 +682,12 @@
              dicData: [
                {
                  label: "否",
                  value: 0
                value: 0,
                },
                {
                  label: "是",
                  value: 1
                }
                value: 1,
              },
              ],
              value: 0,
              slot: true,
@@ -654,32 +695,32 @@
                {
                  required: true,
                  message: "请选择是否覆盖",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: '模板下载',
              prop: 'excelTemplate',
            label: "模板下载",
            prop: "excelTemplate",
              formslot: true,
              span: 24,
            }
          ]
        }
          },
        ],
      },
      };
    },
    watch: {
      'form.tenantId'() {
        if (this.form.tenantId !== '' && this.initFlag) {
    "form.tenantId"() {
      if (this.form.tenantId !== "" && this.initFlag) {
          this.initData(this.form.tenantId);
        }
      },
      'excelForm.isCovered'() {
        if (this.excelForm.isCovered !== '') {
    "excelForm.isCovered"() {
      if (this.excelForm.isCovered !== "") {
          const column = this.findObject(this.excelOption.column, "excelFile");
          column.action = `/api/blade-user/import-user?isCovered=${this.excelForm.isCovered}`;
        }
      }
    },
    },
    computed: {
      ...mapGetters(["userInfo", "permission"]),
@@ -688,7 +729,7 @@
          addBtn: this.vaildData(this.permission.user_add, false),
          viewBtn: this.vaildData(this.permission.user_view, false),
          delBtn: this.vaildData(this.permission.user_delete, false),
          editBtn: this.vaildData(this.permission.user_edit, false)
        editBtn: this.vaildData(this.permission.user_edit, false),
        };
      },
      platformPermissionList() {
@@ -696,12 +737,12 @@
          addBtn: false,
          viewBtn: false,
          delBtn: false,
          editBtn: this.vaildData(this.permission.user_edit, false)
        editBtn: this.vaildData(this.permission.user_edit, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
@@ -720,7 +761,7 @@
        this.onLoad(this.page);
      },
      initData(tenantId) {
        getRoleTree(tenantId).then(res => {
      getRoleTree(tenantId).then((res) => {
          var that = this;
          const column = this.findObject(this.option.group, "roleId");
          column.dicData = res.data.data;
@@ -737,13 +778,13 @@
                that.roleId = item.id;
              }
            }
          })
        });
        getDeptTree(tenantId).then(res => {
      });
      getDeptTree(tenantId).then((res) => {
          const column = this.findObject(this.option.group, "deptId");
          column.dicData = res.data.data;
        });
        getPostList(tenantId).then(res => {
      getPostList(tenantId).then((res) => {
          const column = this.findObject(this.option.group, "postId");
          column.dicData = res.data.data;
        });
@@ -754,7 +795,7 @@
          this.roleBox = false;
          this.$message({
            type: "success",
            message: "操作成功!"
          message: "操作成功!",
          });
          this.onLoad(this.page);
        });
@@ -763,18 +804,21 @@
        row.deptId = row.deptId.join(",");
        row.roleId = this.roleId;
        row.postId = row.postId.join(",");
        add(row).then(() => {
      add(row).then(
        () => {
          this.initFlag = false;
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      //打开地图
      handleMap(row) {
@@ -796,44 +840,46 @@
                window.frames[1].init("SecurityMap", {
                                x: rwjd,
                                y: rwwd,
                                code:row.code
                code: row.code,
                            });
              }else{
                window.frames[1].init("SecurityMap", {
                                x: row.jd,
                                y: row.wd,
                                code:row.code
                code: row.code,
                            });
              }
            } else {
              console.log(`没有找到到window.frames[1].init`)
            console.log(`没有找到到window.frames[1].init`);
            }
          }
        };
        });
      },
      rowUpdate(row, index, done, loading) {
        row.deptId = row.deptId.join(",");
        row.roleId = row.roleId.join(",");
        row.postId = row.postId.join(",");
        update(row).then(() => {
      update(row).then(
        () => {
          this.initFlag = false;
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -842,13 +888,13 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
      searchReset() {
        this.query = {};
        this.treeDeptId = '';
      this.treeDeptId = "";
        this.onLoad(this.page);
      },
      searchChange(params, done) {
@@ -872,7 +918,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -881,7 +927,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
@@ -894,7 +940,7 @@
        this.$confirm("确定将选择账号密码重置为123456?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return resetPassword(this.ids);
@@ -902,7 +948,7 @@
          .then(() => {
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
@@ -916,7 +962,7 @@
        if (this.selectionList.length === 1) {
          this.roleTreeObj = this.selectionList[0].roleId.split(",");
        }
        getRoleTree().then(res => {
      getRoleTree().then((res) => {
          this.roleGrantList = res.data.data;
          this.roleBox = true;
        });
@@ -936,17 +982,27 @@
        this.$confirm("是否导出用户数据?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        }).then(() => {
          window.open(`/api/blade-user/export-user?${this.website.tokenHeader}=${getToken()}&account=${this.search.account}&realName=${this.search.realName}`);
        window.open(
          `/api/blade-user/export-user?${
            this.website.tokenHeader
          }=${getToken()}&account=${this.search.account}&realName=${
            this.search.realName
          }`
        );
        });
      },
      handleTemplate() {
        window.open(`/api/blade-user/export-template?${this.website.tokenHeader}=${getToken()}`);
      window.open(
        `/api/blade-user/export-template?${
          this.website.tokenHeader
        }=${getToken()}`
      );
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getUser(this.form.id).then(res => {
        getUser(this.form.id).then((res) => {
            this.form = res.data.data;
            if (this.form.hasOwnProperty("deptId")) {
              this.form.deptId = this.form.deptId.split(",");
@@ -973,7 +1029,12 @@
      },
      onLoad(page, params = {}) {
        this.loading = true;
        getList(page.currentPage, page.pageSize, Object.assign(params, this.query), this.treeDeptId).then(res => {
      getList(
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query),
        this.treeDeptId
      ).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
@@ -982,21 +1043,24 @@
        });
      },
      platformRowUpdate(row, index, done, loading) {
        updatePlatform(row.id, row.userType, row.userExt).then(() => {
      updatePlatform(row.id, row.userType, row.userExt).then(
        () => {
          this.platformOnLoad(this.platformPage);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      platformBeforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getUserPlatform(this.platformForm.id).then(res => {
        getUserPlatform(this.platformForm.id).then((res) => {
            this.platformForm = res.data.data;
          });
        }
@@ -1030,15 +1094,20 @@
      },
      platformOnLoad(page, params = {}) {
        this.platformLoading = true;
        getList(page.currentPage, page.pageSize, Object.assign(params, this.query), this.treeDeptId).then(res => {
      getList(
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query),
        this.treeDeptId
      ).then((res) => {
          const data = res.data.data;
          this.platformPage.total = data.total;
          this.platformData = data.records;
          this.platformLoading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/system/cs.vue
@@ -197,7 +197,7 @@
          searchSpan: 8,
          searchEnter: true,
          calcHeight: 80,
          stripe: true,
        //stripe:true,
          title: "表格的标题",
          titleSize: "h3",
          titleStyle: {
@@ -268,7 +268,7 @@
          searchShow: true,
          searchMenuSpan: 6,
          border: false,
          stripe: true,
        //stripe:true,
          index: true,
          selection: true,
          viewBtn: true,
@@ -787,10 +787,9 @@
    },
    methods: {
      rowSave(row, done, loading) {
        add(row).then(
          () => {
            debugger
          debugger;
            if (row.type == "0") {
              console.log(123);
              instery(
@@ -835,7 +834,7 @@
        );
      },
      rowUpdate(row, index, done, loading) {
        debugger
      debugger;
        if (row.type == "0") {
          updateInfoy(
            row.dj,
@@ -887,7 +886,7 @@
          type: "warning",
        })
          .then(() => {
            debugger
          debugger;
            if (row.type == "0") {
              deletey(row.tenantName);
            } else if (row.type == "1") {