liuyg
2021-10-27 71891f73bdab2d994fe6d8f4ed4078e9972a28d9
src/views/onSiteInspection/securityStaff.vue
@@ -323,34 +323,43 @@
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning",
      }).then(() => {
        //获取查询条件
        // console.log(this.userInfo, 456);
        // return;
        var data = {
          startTime: this.query.startTime,
          endTime: this.query.endTime,
          realName: this.query.realName,
          securityName: this.query.securityName,
          jurisdiction: this.userInfo.jurisdiction,
        };
        //导出
        // if (
        //   this.userInfo.role_name == "保安公司管理员" ||
        //   this.userInfo.role_name == "保安"
        // ) {
        //   //如果是保安公司管理员
        //   data["deptId"] = this.userInfo.dept_id;
        // }
        // if (this.userInfo.role_name == "培训公司管理员") {
        //   //如果是培训公司管理员
        //   data["trainUnitId"] = this.userInfo.dept_id;
        // }
        // data["examType"] = 2;
        //序列号url形式,用&拼接
        data = Qs.stringify(data);
        window.open(`/api/seinspect/export-seinspect?` + data);
      });
      })
        .then(() => {
          //获取查询条件
          // console.log(this.userInfo, 456);
          // return;
          var data = {
            startTime: this.query.startTime,
            endTime: this.query.endTime,
            realName: this.query.realName,
            securityName: this.query.securityName,
            jurisdiction: this.userInfo.jurisdiction,
          };
          //导出
          // if (
          //   this.userInfo.role_name == "保安公司管理员" ||
          //   this.userInfo.role_name == "保安"
          // ) {
          //   //如果是保安公司管理员
          //   data["deptId"] = this.userInfo.dept_id;
          // }
          // if (this.userInfo.role_name == "培训公司管理员") {
          //   //如果是培训公司管理员
          //   data["trainUnitId"] = this.userInfo.dept_id;
          // }
          // data["examType"] = 2;
          //序列号url形式,用&拼接
          data = Qs.stringify(data);
          window.open(`/api/seinspect/export-seinspect?` + data);
        })
        .catch((action) => {
          // this.$message({
          //   type: 'info',
          //   message: action === 'cancel'
          //     ? '放弃保存并离开页面'
          //     : '停留在当前页面'
          // })
        });
    },
    getStartTime() {
      if (