{"remainingRequest":"D:\\jenkins\\workspace\\examine-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\examine-fvue\\src\\views\\mainDataMenu\\components\\ndpdMenuDialog.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\examine-fvue\\src\\views\\mainDataMenu\\components\\ndpdMenuDialog.vue","mtime":1705466684661},{"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":["//\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 {\n\tTableMixin\n} from '@/mixins/tableMixin'\nimport equSysMenu from '@/api/examination/equSysMenu.js'\nimport moment from 'moment';\nimport userTypeMenu from '@/api/examination/userTypeMenu.js'\nimport ndpdMenu from '@/api/examination/ndpdMenu.js'\nimport dictUtils from '@/components/dict/DictSelectUtils.js'\nimport questionListMenu from '@/api/examination/questionListMenu.js'\nexport default {\n\tcomponents: {},\n\tname: 'ndpdMenuDialog',\n\tdata() {\n\t\treturn {\n\t\t\tvisible: false,\n\t\t\tquerys: [{\n\t\t\t\t\tgroup: 'main',\n\t\t\t\t\toperation: 'LIKE',\n\t\t\t\t\tparentGroup: '',\n\t\t\t\t\tproperty: 'po.position_id_',\n\t\t\t\t\trelation: 'AND',\n\t\t\t\t\tvalue: ''\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tgroup: 'main',\n\t\t\t\t\toperation: 'RIGHT_LIKE',\n\t\t\t\t\tparentGroup: '',\n\t\t\t\t\tproperty: 'name',\n\t\t\t\t\trelation: 'AND',\n\t\t\t\t\tvalue: ''\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tgroup: 'main',\n\t\t\t\t\toperation: 'RIGHT_LIKE',\n\t\t\t\t\tparentGroup: '',\n\t\t\t\t\tproperty: 'name',\n\t\t\t\t\trelation: 'AND',\n\t\t\t\t\tvalue: ''\n\t\t\t\t},\n\n\t\t\t],\n\t\t\tparameter: {\n\t\t\t\tyear: moment().format('YYYY'),\n\t\t\t\tpositionId: null,\n\t\t\t\tsubjectInfoList: []\n\t\t\t},\n\t\t\t//已选\n\t\t\tselectUser: [],\n\t\t\tselectUserProps: {\n\t\t\t\tlabel: \"name\"\n\t\t\t},\n\t\t\tUserData: [],\n\t\t\tqueryParam: {\n\t\t\t\tpageBean: {\n\t\t\t\t\tpageSize: 20,\n\t\t\t\t\tpage: 1\n\t\t\t\t},\n\t\t\t},\n\t\t\ttotal: null,\n\n\n\t\t}\n\t},\n\tcreated() {\n\n\t},\n\tmounted() {},\n\tmethods: {\n\t\tadd(val, parentId) {\n\t\t\tthis.title = '新增'\n\t\t\tthis.querys[0].value = parentId\n\t\t\tthis.parameter.positionId = parentId\n\t\t\tthis.trainTypeList = dictUtils.getDictItemsFromCache('xllb')\n\t\t\tthis.visible = true\n\t\t\tthis.loadData(1)\n\t\t\tthis.getSelectUser()\n\t\t},\n\t\tedit(val) {\n\t\t\tthis.title = '修改'\n\t\t\tthis.visible = true\n\t\t},\n\n\t\t// 关闭\n\t\thandleClose() {\n\t\t\tthis.visible = false\n\t\t\tthis.$emit('reload')\n\n\t\t},\n\t\tgetSelectUser() {\n\t\t\tthis.selectUser = []\n\t\t\tlet parma = {\n\t\t\t\tpageBean: {\n\t\t\t\t\tpageSize: -1,\n\t\t\t\t\tpage: 1\n\t\t\t\t},\n\t\t\t\tquerys: [{\n\t\t\t\t\tgroup: 'main',\n\t\t\t\t\toperation: 'LIKE',\n\t\t\t\t\tparentGroup: '',\n\t\t\t\t\tproperty: 'po.position_id_',\n\t\t\t\t\trelation: 'AND',\n\t\t\t\t\tvalue: this.querys[0].value\n\t\t\t\t}, {\n\t\t\t\t\tgroup: 'main',\n\t\t\t\t\toperation: 'LIKE',\n\t\t\t\t\tparentGroup: '',\n\t\t\t\t\tproperty: 'year',\n\t\t\t\t\trelation: 'AND',\n\t\t\t\t\tvalue: this.parameter.year\n\t\t\t\t}]\n\t\t\t}\n\t\t\tndpdMenu.queryAssess(parma, res => {\n\t\t\t\tthis.total = res.total\n\t\t\t\tthis.selectUser = res.rows\n\t\t\t\tthis.$refs.multipleTable.clearSelection()\n\t\t\t\tres.rows.forEach(s=>{\n\t\t\t\t\tthis.UserData.forEach(u=>{\n\t\t\t\t\t\tif(s.name==u.name){\n\t\t\t\t\t\t\tthis.$refs.multipleTable.toggleRowSelection(u, true)\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t})\n\t\t},\n\t\t// 获取列表\n\t\tloadData(page) {\n\t\t\tthis.$nextTick(() => {\n\t\t\t\tthis.$refs.multipleTable.clearSelection()\n\t\t\t})\n\t\t\tif (page) {\n\t\t\t\tthis.queryParam.pageBean.page = page\n\t\t\t}\n\t\t\tthis.UserData = []\n\t\t\tthis.queryParam.querys = []\n\t\t\tif (this.querys[0].value) {\n\t\t\t\tthis.queryParam.querys.push(this.querys[0])\n\t\t\t}\n\t\t\tif (this.querys[1].value) {\n\t\t\t\tthis.queryParam.querys.push(this.querys[1])\n\t\t\t}\n\t\t\tquestionListMenu.findByMajorIds(this.queryParam, res => {\n\t\t\t\tthis.total = res.total\n\t\t\t\tthis.UserData = res.rows\n\t\t\t\tthis.UserData.forEach(u => {\n\t\t\t\t\tthis.trainTypeList.forEach(e => {\n\t\t\t\t\t\tif (u.trainType == e.value) {\n\t\t\t\t\t\t\tu.trainTypeName = e.name\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t\tthis.selectUser.forEach(s=>{\n\t\t\t\t\tthis.UserData.forEach(u=>{\n\t\t\t\t\t\tconsole.log(s.name==u.name);\n\t\t\t\t\t\tif(s.name==u.name){\n\t\t\t\t\t\t\tconsole.log(s.name);\n\t\t\t\t\t\t\tthis.$refs.multipleTable.toggleRowSelection(u, true)\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t})\n\n\t\t\t})\n\t\t\tthis.$set(this.UserData)\n\t\t},\n\t\t// 保存\n\t\thandleSave() {\n\n\t\t\t// console.log(this.parameter);\n\t\t\t// this.parameter.subjectIds = this.subject.toString()\n\n\t\t\tthis.parameter.subjectInfoList = this.selectUser\n\n\t\t\tlet method\n\t\t\tif (this.title === '新增') {\n\t\t\t\tmethod = ndpdMenu.addAssess\n\t\t\t}\n\t\t\tif (this.title === '修改') {\n\t\t\t\tmethod = ndpdMenu.editAssess\n\t\t\t}\n\t\t\tmethod(this.parameter, response => {\n\t\t\t\tif (response.state) {\n\t\t\t\t\tthis.$notify({\n\t\t\t\t\t\ttype: 'success',\n\t\t\t\t\t\tmessage: this.title + '成功',\n\t\t\t\t\t\tduration: 2000\n\t\t\t\t\t})\n\t\t\t\t\tthis.handleClose()\n\t\t\t\t\tthis.$emit('reload')\n\t\t\t\t} else {\n\t\t\t\t\tthis.$message.warning(response.message)\n\t\t\t\t}\n\t\t\t})\n\n\t\t},\n\t\tbinRowKey(row) {\n\t\t\treturn row.id\n\t\t},\n\t\t//搜索\n\t\tsearchEnterFun() {\n\n\t\t},\n\t\thandleCurrentChange() {\n\n\t\t},\n\t\thandleSizeChange() {\n\n\t\t},\n\t\tmanualSelection(selection, row) {\n\t\t\tlet flag = selection.some((item) => {\n\t\t\t\tif (item.id === row.id) return true;\n\t\t\t})\n\t\t\tif (flag) {\n\t\t\t\tthis.selectUser.push(row)\n\t\t\t\tlet params = {\n\t\t\t\t\tyear: this.parameter.year,\n\t\t\t\t\tpositionId: this.parameter.positionId,\n\t\t\t\t\tsubjectInfoList: [row]\n\t\t\t\t}\n\t\t\t\tndpdMenu.addAssess(params, res => {\n\t\t\t\t\tif (res.state) {\n\t\t\t\t\t\tthis.getSelectUser()\n\t\t\t\t\t\t\n\t\t\t\t\t\tthis.$notify({\n\t\t\t\t\t\t\ttype: 'success',\n\t\t\t\t\t\t\tmessage: this.title + '成功',\n\t\t\t\t\t\t\tduration: 2000\n\t\t\t\t\t\t})\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t} else {\n\t\t\t\tthis.selectUser.forEach((s, si) => {\n\t\t\t\t\tif (s.name == row.name) {\n\t\t\t\t\t\tlet params={\n\t\t\t\t\t\t\tyear: this.parameter.year? this.parameter.year:'',\n\t\t\t\t\t\t\tsubjectIds:row.id?row.id:'',\n\t\t\t\t\t\t\tpositionId:this.parameter.positionId ? this.parameter.positionId :''\n\t\t\t\t\t\t}\n\t\t\t\t\t\tthis.$http.post(window.context.portal +\"/exam/year/assessmentSub/deleteSub\", params, ).then(res => {\n\t\t\t\t\t\t\tif (res.data.state) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tthis.getSelectUser()\n\t\t\t\t\t\t\t\t// this.selectUser.splice(si, 1)\n\t\t\t\t\t\t\t\tthis.$notify({\n\t\t\t\t\t\t\t\t\ttype: 'success',\n\t\t\t\t\t\t\t\t\tmessage: '删除成功',\n\t\t\t\t\t\t\t\t\tduration: 2000\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t}\n\t\t},\n\t\tremove(val){\n\t\t\tndpdMenu.remove(val.id,res=>{\n\t\t\t\t// this.selectUser.splice(si, 1)\n\t\t\t\tif(res.state){\n\t\t\t\t\tthis.getSelectUser()\n\t\t\t\t\tthis.$notify({\n\t\t\t\t\t\ttype: 'success',\n\t\t\t\t\t\tmessage: '删除成功',\n\t\t\t\t\t\tduration: 2000\n\t\t\t\t\t})\n\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t})\n\t\t\t// this.$http.delete(window.context.portal +\"/exam/year/assessmentSub/\"+val.id, ).then(res => {\n\t\t\t// \tif (res.data.state) {\n\t\t\t// \t\tthis.selectUser.splice(si, 1)\n\t\t\t// \t\tthis.$notify({\n\t\t\t// \t\t\ttype: 'success',\n\t\t\t// \t\t\tmessage: '删除成功',\n\t\t\t// \t\t\tduration: 2000\n\t\t\t// \t\t})\n\t\t\t// \t}\n\t\t\t// })\n\t\t\t\n\t\t},\n\t\trenderContent(h, { node, data, store }) {\n\t\t return (\n\t\t {\n\t\t this.show = true\n\t\t }}\n\t\t on-mouseout={() => {\n\t\t this.show = false\n\t\t }}\n\t\t >\n\t\t {data.name}\n\t\t \n\t\t this.remove(data)}\n\t\t >\n\t\t 删除\n\t\t \n\t\t \n\t\t \n\t\t )\n\t\t},\n\t\t\n\t}\n}\n",null]}