{"remainingRequest":"D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\xypm-web-prod\\src\\views\\projectManagent\\ProjectFlowChart.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\src\\views\\projectManagent\\ProjectFlowChart.vue","mtime":1667333351399},{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\babel.config.js","mtime":1667333346259},{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web-prod\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/es7.object.get-own-property-descriptors\";\nimport \"core-js/modules/es6.object.keys\";\nimport _toConsumableArray from \"D:/jenkins/workspace/xypm-web-prod/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js\";\nimport \"core-js/modules/web.dom.iterable\";\nimport _defineProperty from \"D:/jenkins/workspace/xypm-web-prod/node_modules/@babel/runtime/helpers/esm/defineProperty.js\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 moduleRouter from '@/module_components.js';\nimport menuApi from '@/api/menu.js';\nexport default {\n name: 'ProjectFlowChart',\n components: _objectSpread({}, moduleRouter),\n data: function data() {\n return {\n isShow: false,\n currentComponent: '',\n menuTabsStyle: null,\n filterText: '',\n //树型搜索内容\n isIeExplorer: false,\n //\n isExpand: false,\n loading: false,\n treeData: [],\n defaultProps: {\n label: 'name',\n code: 'code',\n id: 'id',\n children: 'children',\n isLeaf: 'leaf' // 指定节点是否为叶子节点,仅在指定了 lazy 属性的情况下生效\n\n },\n defaultCheckedKeys: [],\n defaultExpandedKeys: [],\n node: '',\n resolve: '',\n isShowAside: true //左侧菜单默认显示\n\n };\n },\n mounted: function mounted() {\n if (this.$route.params && this.$route.params.alias) {\n this.getInitMenus(this.$route.params);\n } else {\n this.getInitMenus();\n } // this.getInitMenus()\n\n },\n computed: {\n projectId: function projectId() {\n return this.$route.params.id;\n }\n },\n watch: {\n filterText: function filterText(val) {\n this.$refs.tree.filter(val);\n }\n },\n defaultCheckedKeys: function defaultCheckedKeys(val) {\n this.$refs.tree.setCheckedKeys(val);\n },\n methods: {\n //点击节点\n handleNodeClick: function handleNodeClick(data) {\n if (data.alias && data.children.length == 0) {\n // console.log(data)\n this.currentComponent = data.alias;\n sessionStorage.setItem('activeAlias', JSON.stringify(data));\n }\n },\n filterNode: function filterNode(value, data) {\n if (!value) return true;\n return data[this.defaultProps.label].indexOf(value) !== -1;\n },\n loadNode: function loadNode(node, resolve) {},\n // 树状菜单的全部展开和收起\n handleExpandCollapse: function handleExpandCollapse() {\n var elTree = this.$refs.tree;\n\n for (var i = 0; i < elTree.store._getAllNodes().length; i++) {\n elTree.store._getAllNodes()[i].expanded = this.isExpand;\n }\n\n this.isExpand = !this.isExpand;\n },\n //树状刷新\n refresh: function refresh() {\n var _this = this;\n\n this.loading = true;\n this.$emit('refresh', function () {\n _this.loading = false;\n _this.filterText = '';\n\n _this.getInitMenus();\n });\n setTimeout(function () {\n _this.loading = false;\n _this.filterText = '';\n\n _this.getInitMenus();\n }, 2000);\n },\n //初始获取树状的菜单目录\n getInitMenus: function getInitMenus(params) {\n var _this2 = this;\n\n // debugger\n // console.log(params)\n this.$http.post('${cqxy}/biz/projectManagement/projectPersonnelMenu/v1/getCurrentUserMenuByProjectId?projectId=' + this.projectId).then(function (res) {\n if (res.data.state) {\n var _arrPcode$0$children;\n\n // console.log(res.data.value, '555555555555555555')\n // let menus = JSON.parse(sessionStorage.getItem('currentFrontMenus'))\n var menus = res.data.value; //将菜单统计报表下的项目台账隐藏并将统计报表更名为项目台账\n\n menus.forEach(function (item, index) {\n // console.log(item.alias, item.name)\n //隐藏菜单中的项目管理菜单\n if (item.alias == 'projectManagentSub') {\n delete menus[index];\n } //隐藏菜单中的年度计划菜单\n\n\n if (item.alias == 'AnnualPlan' || item.alias == 'planningEIA' || item.alias == 'fileLibrary' || item.alias == 'DirectoryManagement') {\n delete menus[index];\n }\n\n if (item.alias == 'statisticalReport') {\n item.name = '项目台账';\n item.children.splice(0, 1);\n }\n });\n menus.forEach(function (item) {\n if (item.alias == 'statisticalReport') {\n item.children.forEach(function (item1, index) {\n if (item1.alias == 'projectInformationStatistics') {\n item.children.splice(index, 1);\n }\n });\n }\n });\n var tree = menus.filter(function (item) {\n return item.alias !== 'projectManagement';\n });\n var arrPcode = [{\n name: '项目管理',\n code: 'root',\n children: [],\n id: '0',\n isLeaf: true,\n alias: 'root'\n }];\n\n (_arrPcode$0$children = arrPcode[0].children).push.apply(_arrPcode$0$children, _toConsumableArray(tree));\n\n _this2.treeData = arrPcode;\n var defaultKey = _this2.treeData[0].children;\n var cureentAlias = JSON.parse(sessionStorage.getItem('activeAlias'));\n\n if (cureentAlias) {\n _this2.defaultTable(cureentAlias);\n } else if (params) {\n var al = defaultKey.filter(function (item) {\n if (item.children.length > 0) {\n item.children.forEach(function (item2) {\n if (item2.alias == params.alias) {\n return item;\n }\n });\n } else {\n if (item.alias == params.alias) {\n return item;\n }\n }\n });\n\n _this2.defaultTable(al[0]);\n } else {\n for (var i in defaultKey) {\n if (i == 0) {\n if (defaultKey[i].children.length > 0) {\n _this2.defaultTable(defaultKey[i].children[i]);\n } else {\n _this2.defaultTable(defaultKey[i]);\n }\n }\n }\n }\n }\n });\n },\n defaultTable: function defaultTable(data) {\n var _this3 = this;\n\n console.log(data);\n this.defaultCheckedKeys.push(data.id);\n this.defaultExpandedKeys.push(data.id);\n this.currentComponent = data.alias;\n this.$nextTick(function () {\n _this3.$refs.tree.setCurrentKey(data.id);\n });\n },\n //隐藏目录\n handleHideMenu: function handleHideMenu() {\n this.isShowAside = !this.isShowAside;\n }\n },\n destroyed: function destroyed() {\n delete sessionStorage.removeItem('activeAlias');\n }\n};",null]}