{"remainingRequest":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\xq-web-bpm\\src\\views\\system\\generator\\sysModuleCreate.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\src\\views\\system\\generator\\sysModuleCreate.vue","mtime":1675071993225},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\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//\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//\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//\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//\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//\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//\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//\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//\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//\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//\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 utils from \"@/hotent-ui-util.js\";\nimport req from \"@/request.js\";\n\nvar EipSysTypeSelector = function EipSysTypeSelector() {\n return import(\"@/components/selector/EipSysTypeSelector.vue\");\n};\n\nvar EipFormDialog = function EipFormDialog() {\n return import(\"@/components/dialog/EipFormDialog.vue\");\n};\n\nvar eipFlowDialog = function eipFlowDialog() {\n return import(\"@/components/dialog/EipFlowDialog.vue\");\n};\n\nvar EipChartDialog = function EipChartDialog() {\n return import(\"@/components/dialog/EipChartDialog.vue\");\n};\n\nvar EipDataTemplateDialog = function EipDataTemplateDialog() {\n return import(\"@/components/dialog/EipDataTemplateDialog.vue\");\n};\n\nvar businessObjDialog = function businessObjDialog() {\n return import(\"@/views/form/BusinessObjDialog.vue\");\n};\n\nvar sysModuleAddMenus = function sysModuleAddMenus() {\n return import(\"@/views/system/generator/sysModuleAddMenus.vue\");\n};\n\nexport default {\n name: \"sysModuleCreate\",\n components: {\n EipSysTypeSelector: EipSysTypeSelector,\n EipFormDialog: EipFormDialog,\n eipFlowDialog: eipFlowDialog,\n EipChartDialog: EipChartDialog,\n EipDataTemplateDialog: EipDataTemplateDialog,\n businessObjDialog: businessObjDialog,\n sysModuleAddMenus: sysModuleAddMenus\n },\n props: [\"id\", \"moduleEditorDialogVisible\"],\n data: function data() {\n return {\n ids: this.id,\n isSubmit: false,\n style: {\n overflowY: \"auto\",\n height: \"500px\"\n },\n divStyle: {\n margin: \"0 12%\",\n background: \"rgba(237, 237, 237, 1)\",\n height: \"500px\"\n },\n workspaceList: [],\n chartList: [],\n datalistList: [],\n moduleName: \"\",\n otherTypeArr: [],\n workspaceSelectList: [{\n key: \"todo\",\n value: \"待办事项\"\n }, {\n key: \"done\",\n value: \"已办事项\"\n }, {\n key: \"request\",\n value: \"我的请求\"\n }, {\n key: \"newProcess\",\n value: \"新建流程\"\n }, {\n key: \"todoRead\",\n value: \"待阅事项\"\n }, {\n key: \"doneRead\",\n value: \"已阅事项\"\n }, {\n key: \"myRead\",\n value: \"我传阅的\"\n }, {\n key: \"myDelegate\",\n value: \"我转办的\"\n }],\n active: 1,\n list: [{\n key: \"workspace\",\n value: \"工作空间\"\n }, {\n key: \"datalist\",\n value: \"数据列表\"\n }, {\n key: \"viewlist\",\n value: \"视图列表\"\n }, {\n key: \"chart\",\n value: \"图表\"\n }, {\n key: \"other\",\n value: \"栏目\"\n }],\n data: {\n id: \"\",\n name: \"\",\n relName: \"\",\n relCode: \"\",\n code: \"\",\n menu: \"\",\n reportName: \"\"\n },\n curSelectForm: {},\n moduleTypeCreateTab: {},\n moduleTypeTab: {},\n moduleTypeForm: {},\n moduleTypeFlow: {},\n flowSvg: require(\"@/assets/img/flow.svg\"),\n formSvg: require(\"@/assets/img/form.svg\")\n };\n },\n computed: {\n menuList: function menuList() {\n if (this.data.type == \"flow\") {\n return this.list.filter(function (item) {\n return item.key != \"viewlist\";\n });\n } else if (this.data.type == \"table\") {\n return this.list.filter(function (item) {\n return item.key != \"workspace\" && item.key != \"datalist\";\n });\n } else if (this.data.type != \"table\") {\n return this.list.filter(function (item) {\n return item.key != \"workspace\" && item.key != \"viewlist\";\n });\n }\n\n return this.list;\n }\n },\n watch: {\n id: function id(newV) {\n var _this = this;\n\n if (newV) {\n this.active = 2;\n var url = window.context.portal + \"/sys/sysModule/v1/getJson?id=\" + newV;\n req.get(url).then(function (response) {\n _this.data = response.data;\n\n _this.initList(_this.data);\n });\n }\n }\n },\n mounted: function mounted() {\n var _this2 = this;\n\n var height = window.screen.availHeight * 0.68 - 70 + \"px\";\n this.style.height = height;\n this.divStyle.height = height;\n this.$validator = this.$root.$validator;\n\n if (this.id) {\n this.active = 2;\n var url = window.context.portal + \"/sys/sysModule/v1/getJson?id=\" + this.id;\n req.get(url).then(function (response) {\n _this2.data = response.data;\n\n _this2.initList(_this2.data);\n\n return _this2;\n });\n }\n },\n methods: {\n closeBusinessObjDialog: function closeBusinessObjDialog() {\n this.$emit(\"close-dialog\");\n },\n initList: function initList(data) {\n var _this3 = this;\n\n if (data.moduleDetail && data.moduleDetail.length > 0) {\n var workspaceList = [];\n var datalistList = [];\n var viewlistList = [];\n var chartList = [];\n var otherTypeArr = [];\n var otherTypeMap = {};\n\n for (var i = 0; i < data.moduleDetail.length; i++) {\n var type = data.moduleDetail[i].type;\n\n switch (type) {\n case \"workspace\":\n workspaceList.push(data.moduleDetail[i]);\n break;\n\n case \"datalist\":\n datalistList.push(data.moduleDetail[i]);\n break;\n\n case \"viewlist\":\n viewlistList.push(data.moduleDetail[i]);\n break;\n\n case \"chart\":\n chartList.push(data.moduleDetail[i]);\n break;\n\n case \"other\":\n var item = data.moduleDetail[i];\n\n if (!otherTypeMap[item.columnName]) {\n otherTypeMap[item.columnName] = {\n name: item.columnName,\n otherList: []\n };\n }\n\n otherTypeMap[item.columnName].otherList.push(item);\n break;\n }\n }\n\n this.workspaceList = workspaceList;\n this.datalistList = datalistList;\n this.viewlistList = viewlistList;\n this.chartList = chartList;\n\n if (otherTypeMap) {\n for (var key in otherTypeMap) {\n otherTypeArr.push(otherTypeMap[key]);\n }\n }\n\n this.otherTypeArr = otherTypeArr;\n }\n\n setTimeout(function () {\n _this3.$validator.validate();\n }, 100);\n },\n move: function move(name, ary, item, direct) {\n this[name] = utils.arrayMove(ary, item, direct);\n },\n moveTo: function moveTo(index, ary, item, direct) {\n this.otherTypeArr[index].otherList = utils.arrayMove(ary, item, direct);\n },\n getUrl: function getUrl(code) {\n var item = {};\n\n switch (code) {\n case \"todo\":\n item.url = \"/v-flow/v-todo/\" + this.data.relCode;\n item.name = \"待办事项\";\n break;\n\n case \"done\":\n item.url = \"/v-flow/v-done/\" + this.data.relCode;\n item.name = \"已办事项\";\n break;\n\n case \"request\":\n item.url = \"/v-flow/v-request/\" + this.data.relCode;\n item.name = \"我的请求\";\n break;\n\n case \"todoRead\":\n item.url = \"/v-flow/v-todoRead/\" + this.data.relCode;\n item.name = \"待阅事项\";\n break;\n\n case \"doneRead\":\n item.url = \"/v-flow/v-doneRead/\" + this.data.relCode;\n item.name = \"已阅事项\";\n break;\n\n case \"myRead\":\n item.url = \"/v-flow/v-myRead/\" + this.data.relCode;\n item.name = \"我传阅的\";\n break;\n\n case \"myDelegate\":\n item.url = \"/v-flow/v-myDelegate/\" + this.data.relCode;\n item.name = \"我转办的\";\n break;\n\n case \"newProcess\":\n item.url = \"/agentStartByKey/\" + this.data.relCode;\n item.name = \"发起\" + this.data.relName;\n break;\n }\n\n return item;\n },\n workspaceChangeType: function workspaceChangeType(code, index) {\n var data = this.getUrl(code);\n this.workspaceList[index].url = data.url;\n this.workspaceList[index].name = data.name;\n },\n changeshowType: function changeshowType(value, index) {\n if (value == \"flow\") {\n var data = this.getUrl(this.workspaceList[index].code);\n this.workspaceList[index].url = data.url;\n } else {\n this.workspaceList[index].url = \"/statement/template/preview/\" + this.data.reportAlias + \"/\" + this.workspaceList[index].code + \"/\" + this.data.relCode + \"/\" + true;\n }\n },\n initStyle: function initStyle() {\n this.moduleTypeCreateTab = {};\n this.moduleTypeTab = {};\n this.moduleTypeForm = {};\n this.moduleTypeFlow = {};\n },\n selectModuleType: function selectModuleType(type) {\n this.initStyle();\n\n switch (type) {\n case \"createTable\":\n this.$refs.objDialog.handleOpen();\n break;\n\n case \"table\":\n this.data.menu = \"viewlist,chart,other\";\n break;\n\n case \"form\":\n this.data.menu = \"datalist,chart,other\";\n break;\n\n case \"flow\":\n this.data.menu = \"workspace,chart,other\";\n break;\n }\n\n this.data.type = type;\n this.next();\n },\n next: function next() {\n var _this4 = this;\n\n if (this.active == 1 && this.data.type == undefined) {\n this.$message.error(\"请选择模块类型!\");\n return;\n }\n\n if (this.active === 2) {\n this.$validator.validateAll(\"sysModuleForm\").then(function (result) {\n if (result) {\n _this4.active++;\n } else {\n _this4.$message.error(\"表单未正确填写\");\n }\n });\n } else {\n this.active++;\n }\n },\n step: function step() {\n this.active--;\n },\n selectForm: function selectForm() {\n this.$refs.eipFormDialog.showDialog();\n },\n selectFlow: function selectFlow() {\n this.$refs.eipFlowDialog.showDialog();\n },\n dialogFormConfirm: function dialogFormConfirm(data) {\n var _this5 = this;\n\n if (data && data.length > 0) {\n this.$nextTick(function () {\n _this5.data.relCode = data[0].formKey;\n _this5.data.relName = data[0].name;\n });\n } else {\n this.clearForm();\n }\n },\n dialogFlowConfirm: function dialogFlowConfirm(data) {\n var _this6 = this;\n\n if (data && data.length > 0) {\n this.$nextTick(function () {\n _this6.data.relCode = data[0].defKey;\n _this6.data.relName = data[0].name;\n });\n } else {\n this.clearForm();\n }\n },\n clearForm: function clearForm() {\n var _this7 = this;\n\n this.$nextTick(function () {\n _this7.data.relCode = \"\";\n _this7.data.relName = \"\";\n });\n },\n addWorkspace: function addWorkspace() {\n this.workspaceList.push({\n code: \"\",\n name: \"\",\n url: \"\",\n type: \"workspace\",\n showType: \"flow\"\n });\n },\n showChartDialog: function showChartDialog() {\n this.$refs.chartDialog.showDialog();\n },\n showDataTemplateDialog: function showDataTemplateDialog(type) {\n if (type == \"flow\") {\n this.$refs.dataTemplateDialog.showDialog();\n } else {\n this.$refs.dataReportDialog.showDialog();\n }\n },\n onChartConfirm: function onChartConfirm(selectedNode) {\n var _this8 = this;\n\n if (selectedNode && selectedNode.length > 0) {\n selectedNode.forEach(function (m) {\n _this8.chartList.push({\n name: m.name,\n code: m.alias,\n chartType: m.style + \"\",\n type: \"chart\",\n url: m.id\n });\n });\n }\n\n this.$refs.chartDialog.handleClose();\n },\n onDataReportConfirm: function onDataReportConfirm(selectedNode) {\n var _this9 = this;\n\n if (selectedNode && selectedNode.length > 0) {\n selectedNode.forEach(function (item) {\n var url = \"/statement/template/preview/\" + item.alias + \"/true\";\n var temp = {\n type: \"datalist\",\n name: item.name,\n code: item.alias,\n viewCode: item.boDefAlias,\n chartType: item.typeName,\n url: url\n };\n\n _this9.datalistList.push(temp);\n });\n }\n },\n onDataTemplateConfirm: function onDataTemplateConfirm(selectedNode) {\n var _this10 = this;\n\n if (selectedNode && selectedNode.length > 0) {\n this.$nextTick(function () {\n _this10.data.reportName = selectedNode[0].name;\n _this10.data.reportAlias = selectedNode[0].alias;\n });\n } else {\n if (this.data.type == \"flow\") {\n this.data.reportName = \"\";\n this.data.reportAlias = \"\";\n }\n }\n },\n addOtherType: function addOtherType() {\n this.otherTypeArr.push({\n name: \"\",\n otherList: []\n });\n },\n getDtailList: function getDtailList() {\n var detailList = [];\n\n if (this.workspaceList.length > 0 && this.data.menu.indexOf(\"workspace\") != -1) {\n this.workspaceList.forEach(function (item) {\n detailList.push(item);\n });\n }\n\n if (this.datalistList.length > 0 && this.data.menu.indexOf(\"datalist\") != -1) {\n this.datalistList.forEach(function (item) {\n detailList.push(item);\n });\n }\n\n if (this.chartList.length > 0 && this.data.menu.indexOf(\"chart\") != -1) {\n this.chartList.forEach(function (item) {\n detailList.push(item);\n });\n }\n\n if (this.otherTypeArr.length > 0 && this.data.menu.indexOf(\"other\") != -1) {\n this.otherTypeArr.forEach(function (item) {\n var typeName = item.name;\n var otherList = item.otherList;\n otherList.forEach(function (m) {\n m.columnName = typeName;\n detailList.push(m);\n });\n });\n }\n\n return detailList;\n },\n stepToSave: function stepToSave() {\n var _this11 = this;\n\n this.isSubmit = true;\n var url = window.context.portal + \"/sys/sysModule/v1/saveModule\";\n this.$validator.validateAll(\"modelForm\").then(function (result) {\n if (!result) {\n _this11.$message.error(\"表单未正确填写\");\n\n _this11.isSubmit = false;\n } else {\n //todo 保存表单信息\n _this11.data.moduleDetail = _this11.getDtailList();\n req.post(url, _this11.data).then(function (response) {\n if (response.data.state) {\n _this11.$message.success(response.data.message);\n\n setInterval(function () {\n _this11.$emit(\"close-dialog\");\n }, 2000);\n } else {\n _this11.$message.error(response.data.message);\n }\n });\n }\n });\n },\n modulePush: function modulePush() {\n var _this12 = this;\n\n this.isSubmit = true;\n var url = window.context.portal + \"/sys/sysModule/v1/saveModule\";\n this.$validator.validateAll(\"modelForm\").then(function (result) {\n if (!result) {\n _this12.$message.error(\"表单未正确填写\");\n\n _this12.isSubmit = false;\n } else {\n _this12.data.moduleDetail = _this12.getDtailList();\n req.post(url, _this12.data).then(function (response) {\n if (response.data.state) {\n _this12.isSubmit = false;\n _this12.data.id = response.data.value;\n _this12.moduleName = _this12.data.name;\n\n _this12.$refs.sysModuleAddMenus.showDialog(response.data.value);\n } else {\n _this12.isSubmit = false;\n\n _this12.$message.error(response.data.message);\n }\n });\n }\n });\n },\n addMenusClose: function addMenusClose() {\n var _this13 = this;\n\n setInterval(function () {\n _this13.$emit(\"close-dialog\");\n }, 2000);\n }\n }\n};",null]}