export default {
  data (){
    return {
      //分页参数，最终合并提交
      pages:{
        pageNum: 1,
        pageSize: 10,
        total: 0,
      },
      // 遮罩层
      loading: false,
      queryParams:{},
      dateRange:[],
    }
  },
  methods:{
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.page = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.dateRange = [];
      this.resetForm("queryForm");
      this.queryParams.orgId = undefined;
      this.$refs.tree.setCurrentKey(null);
      this.handleQuery();
    },
    getKUploadFileList() {
      //循环获取this.$refs.upload.fileList中的name和url，放到 this.form.fileList中去
      this.form.fileList = this.$refs.upload.fileList.map(file => {
        return JSON.stringify({ name: file.name, url: file.url });
      });
    },
  }
}
