{"remainingRequest":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\examine-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\examine-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\examine-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\examine-fvue\\src\\views\\mainDataMenu\\components\\relatedJobs.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\examine-fvue\\src\\views\\mainDataMenu\\components\\relatedJobs.vue","mtime":1673848073977},{"path":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.function.name\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nimport { TableMixin } from '@/mixins/tableMixin';\nimport dictUtils from '@/components/dict/DictSelectUtils.js';\nimport userTypeMenu from '@/api/examination/userTypeMenu.js';\nexport default {\n  mixins: [TableMixin],\n  name: 'SelectOrganize',\n  data: function data() {\n    return {\n      querys: [{\n        property: 'ORG_ID_',\n        value: '',\n        group: 'orgTree',\n        relation: 'AND',\n        operation: 'IN'\n      }, {\n        group: 'main',\n        operation: 'RIGHT_LIKE',\n        parentGroup: '',\n        property: 'name',\n        relation: 'AND',\n        value: ''\n      }],\n      search: '',\n      treeData: [],\n      defaultProps: {\n        children: 'children',\n        label: 'name'\n      },\n      visible: false,\n      UserData: [],\n      selectUser: [],\n      selectUserProps: {\n        label: \"positionName\"\n      },\n      userInfoVos: [],\n      nameArr: [],\n      multipleSelection: [],\n      filterText: '',\n      currentKey: null\n    };\n  },\n  created: function created() {},\n  mounted: function mounted() {},\n  watch: {\n    filterText: function filterText(val) {\n      this.$refs.tree.filter(val);\n    },\n    currentKey: {\n      handler: function handler(value) {\n        var _this = this;\n\n        if (value) {\n          this.$nextTick(function () {\n            _this.$refs.tree.setCurrentKey(_this.currentKey);\n          });\n        }\n      },\n      immediate: true,\n      valType: false\n    }\n  },\n  methods: {\n    filterNode: function filterNode(value, data) {\n      if (!value) return true;\n      return data.name.indexOf(value) !== -1;\n    },\n    add: function add(val) {\n      var _this2 = this;\n\n      this.querys[0].value = '';\n\n      if (val.length > 0) {\n        this.userInfoVos = val;\n        this.userlength = this.userInfoVos.length;\n        this.selectUser = JSON.parse(JSON.stringify(val));\n      } else {\n        this.selectUser = [];\n      }\n\n      this.visible = true;\n      this.$nextTick(function () {\n        _this2.$refs.multipleTable.clearSelection();\n      });\n      this.multipleSelection = []; // this.loadData(1)\n\n      this.getTree();\n    },\n    searchName: function searchName() {\n      this.getTree(1);\n    },\n    getTree: function getTree() {\n      var _this3 = this;\n\n      this.currentKey = null;\n      userTypeMenu.getOrgsList({}, function (res) {\n        _this3.treeData = res;\n        _this3.currentKey = res[0].id;\n        _this3.querys[0].value = _this3.currentKey;\n        _this3.parentId = _this3.currentKey;\n\n        _this3.$set(_this3.querys[1]);\n\n        _this3.$set(_this3.treeData);\n\n        _this3.loadData(1);\n      });\n    },\n    handleNodeClick: function handleNodeClick(data) {\n      this.querys[0].value = data.id;\n      this.loadData(1);\n    },\n    // 获取列表\n    loadData: function loadData(page) {\n      var _this4 = this;\n\n      if (page) {\n        this.queryParam.pageBean.page = page;\n      }\n\n      this.UserData = [];\n      this.queryParam.querys = [];\n\n      if (this.querys[0].value) {\n        this.queryParam.querys.push(this.querys[0]);\n      }\n\n      if (this.querys[1].value) {\n        this.queryParam.querys.push(this.querys[1]);\n      }\n\n      userTypeMenu.getOrgPostPage(this.queryParam, function (res) {\n        res.rows.forEach(function (item) {\n          _this4.UserData.push({\n            // orgId: item.orgId,\n            state: true,\n            positionCode: item.groupCode,\n            positionId: item.id,\n            positionName: item.name\n          });\n        });\n\n        _this4.selectUser.forEach(function (s) {\n          _this4.UserData.forEach(function (u) {\n            if (s.positionId == u.positionId) {\n              _this4.$refs.multipleTable.toggleRowSelection(u, true);\n            }\n          });\n        });\n\n        _this4.total = res.total;\n\n        _this4.$set(_this4.UserData);\n      });\n    },\n    // 显示\n    handleShow: function handleShow(val) {\n      console.log(val);\n      this.visible = true;\n      this.selectUser = [];\n      this.multipleSelection = [];\n      this.loadData(1);\n      this.getTree(1);\n    },\n    // 关闭新增人员窗口\n    handleClose: function handleClose() {\n      this.visible = false;\n      this.treeData = [{\n        code: '',\n        id: '0',\n        name: '行政维度',\n        type: 0,\n        children: []\n      }];\n      this.UserData = [];\n      this.selectUser = [];\n    },\n    binRowKey: function binRowKey(row) {\n      return row.positionId;\n    },\n    selectable: function selectable(row) {\n      var _this5 = this;\n\n      var type = true;\n      this.userInfoVos.forEach(function (u, ui) {\n        if (ui <= _this5.userlength) {\n          if (row.positionId == u.positionId) {\n            type = false;\n          }\n        }\n      });\n      return type; // return true\n    },\n    manualSelection: function manualSelection(selection, row) {\n      var _this6 = this;\n\n      //先判断当前操作flag\n      //true勾选还是false取消\n      var flag = selection.some(function (item) {\n        if (item.positionId === row.positionId) return true;\n      });\n\n      if (flag) {\n        this.selectUser.push(row);\n      } else {\n        this.selectUser.forEach(function (s, si) {\n          if (s.positionId == row.positionId) {\n            _this6.selectUser.splice(si, 1);\n          }\n        });\n      }\n\n      console.log(this.selectUser);\n    },\n    // 重置\n    reset: function reset() {\n      this.querys[0].value = \"\";\n      this.querys[1].value = \"\";\n      this.loadData(1);\n    },\n    dialogConfirm: function dialogConfirm() {\n      console.log(this.selectUser);\n      this.$emit('getUser', this.selectUser);\n      this.handleClose();\n    },\n    handleSelectionChange: function handleSelectionChange(val) {\n      var _this7 = this;\n\n      console.log(val);\n      return;\n      this.multipleSelection = val.map(function (item) {\n        return item;\n      });\n      this.selectUser = this.multipleSelection;\n      this.selectUser.forEach(function (item) {\n        _this7.nameArr.push(item.fullname);\n      });\n    },\n    renderContent: function renderContent(h, _ref) {\n      var _this8 = this;\n\n      var node = _ref.node,\n          data = _ref.data,\n          store = _ref.store;\n      return h(\"span\", {\n        \"class\": \"custom-tree-node\",\n        \"on\": {\n          \"mouseover\": function mouseover() {\n            _this8.show = true;\n          },\n          \"mouseout\": function mouseout() {\n            _this8.show = false;\n          }\n        }\n      }, [h(\"span\", [data.positionName]), h(\"span\", [h(\"el-button\", {\n        \"style\": \"width:100%;border:0;margin:0;\",\n        \"attrs\": {\n          \"size\": \"mini\",\n          \"type\": \"text\"\n        },\n        \"on\": {\n          \"click\": function click() {\n            return _this8.remove(data);\n          }\n        }\n      }, [\"\\u5220\\u9664\"])])]);\n    },\n    remove: function remove(val) {\n      var _this9 = this;\n\n      console.log(val);\n      this.selectUser.forEach(function (u, ui) {\n        if (u.positionId == val.positionId) {\n          _this9.selectUser.splice(ui, 1);\n        }\n      });\n      this.userInfoVos = JSON.parse(JSON.stringify(this.selectUser));\n      this.userlength = this.selectUser.length;\n      this.loadData(1);\n    }\n  }\n};",null]}