{"remainingRequest":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/thread-loader/dist/cjs.js!/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/babel-loader/lib/index.js!/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/cache-loader/dist/cjs.js??ref--0-0!/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/vue-loader/lib/index.js??vue-loader-options!/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/src/components/Common/nodeLink_select.vue?vue&type=script&lang=js&","dependencies":[{"path":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/src/components/Common/nodeLink_select.vue","mtime":1701674859499},{"path":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/cache-loader/dist/cjs.js","mtime":1701674874584},{"path":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/thread-loader/dist/cjs.js","mtime":1701674873947},{"path":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/babel-loader/lib/index.js","mtime":1701674874357},{"path":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/cache-loader/dist/cjs.js","mtime":1701674874584},{"path":"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/vue-loader/lib/index.js","mtime":1701674874903}],"contextDependencies":[],"result":["import \"core-js/modules/es7.object.get-own-property-descriptors\";\nimport \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.object.keys\";\nimport \"regenerator-runtime/runtime\";\nimport _asyncToGenerator from \"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/@babel/runtime-corejs2/helpers/esm/asyncToGenerator\";\nimport \"core-js/modules/es6.function.name\";\nimport _defineProperty from \"/data/jenkins/workspace/test-v5in-source-front-01/src/badp-bcxin-5.x/obpm-designer-web/node_modules/@babel/runtime-corejs2/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (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 = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { 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//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 { getModuleFormList } from '@/service/FormApi.js';\nimport { getModuleViewList, reqLinkDetail, reqLinkList, updateLinkDetail, delLinkList, addLinkDetail } from '@/service/ViewApi.js';\nimport { getAllmodules as _getAllmodules } from '@/service/CommonApi.js';\nimport { nameCheck } from '@/utils/utils.js';\nimport { delMsg } from '@/utils/elementui';\nexport default {\n data: function data() {\n return {\n params: {\n appId: '',\n moduleId: '',\n searchword: '',\n type: '',\n viewId: '',\n pageNo: 1,\n linesPerPage: 10,\n name: '',\n description: ''\n },\n linkInline: {\n name: '',\n // 名称\n type: '' // 类型\n\n },\n content: {\n name: '',\n // 名称\n type: '00',\n // 类型\n moduleid: '',\n // 模块\n queryString: '',\n // 参数\n actionForm: '',\n // 作用表单\n actionView: '',\n // 作用视图\n directory: 'portal',\n // 自定义链接\n externalLinks: '',\n // 扩展链接\n tb: [// 参数\n {\n paramKey: '',\n paramValue: ''\n }],\n description: '' // 描述\n\n },\n showLinkType: true,\n contentRules: {\n name: [{\n required: true,\n message: this.$t('placeholder.name'),\n trigger: 'blur'\n }, {\n validator: nameCheck,\n trigger: 'blur'\n }]\n },\n allmodulesData: [],\n // 模块的数据\n moduleFormOptions: [],\n //作用表单\n moduleViewOptions: [],\n // 作用视图\n delCheckBoxData: [],\n // checkbox选中的值\n isEdit: false,\n // 是否为编辑状态\n loading: true,\n nodeLinkData: {},\n // 节点链接列表\n nodeLinkParams: {\n name: '',\n type: '',\n pageNo: 1,\n linesPerPage: 10\n }\n };\n },\n methods: {\n // 弹框关闭回调\n handleClose: function handleClose() {\n this.isEdit = false;\n this.onReset();\n this.logoutLinkType('contentForm');\n this.$emit('closeNodeLink');\n },\n // 表格查询\n onSearch: function onSearch() {\n this.nodeLinkParams = _objectSpread(_objectSpread({}, this.nodeLinkParams), {}, {\n name: this.linkInline.name,\n type: this.linkInline.type\n });\n this.getNodeLinkList();\n },\n // 链接添加\n addNodeLink: function addNodeLink() {\n this.showLinkType = false;\n },\n // 表格和表单重置重置\n onReset: function onReset() {\n this.linkInline.name = '';\n this.linkInline.type = '';\n this.$emit('resetNodeLinkData');\n },\n // 链接编辑\n handleEdit: function handleEdit(index, row) {\n this.getLinkDetail(row.id);\n this.isEdit = true;\n\n var params = _objectSpread(_objectSpread({}, this.params), {}, {\n appId: sessionStorage.getItem('appId'),\n moduleId: row.moduleid,\n searchword: '',\n viewId: '',\n pageNo: 1,\n linesPerPage: 100000,\n id: row.id\n });\n\n this.params = params;\n\n if (row.type == '00') {\n this.getListFrom(params);\n } else if (row.type == '01') {\n this.getListView(params);\n }\n\n this.showLinkType = false;\n },\n // 选中表格前面的那个复选框\n handleSelectionChange: function handleSelectionChange(row) {\n this.delCheckBoxData = row;\n },\n // 批量删除表格选中的数据\n delSelectData: function () {\n var _delSelectData = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {\n var ids, response;\n return regeneratorRuntime.wrap(function _callee$(_context) {\n while (1) {\n switch (_context.prev = _context.next) {\n case 0:\n ids = [];\n this.delCheckBoxData.map(function (item) {\n return ids.push(item.id);\n });\n\n if (!(this.delCheckBoxData.length > 0)) {\n _context.next = 18;\n break;\n }\n\n _context.prev = 3;\n _context.next = 6;\n return delMsg(this.$t('msg.delConfirm'), this.$t('msg.tip'));\n\n case 6:\n _context.next = 8;\n return delLinkList(ids);\n\n case 8:\n response = _context.sent;\n console.log(response, 'response');\n\n if (response.data.errcode == 0) {\n this.$message.success(response.data.data);\n this.getNodeLinkList();\n }\n\n _context.next = 16;\n break;\n\n case 13:\n _context.prev = 13;\n _context.t0 = _context[\"catch\"](3);\n console.log(_context.t0);\n\n case 16:\n _context.next = 19;\n break;\n\n case 18:\n this.$message.error(this.$t('msg.check_data'));\n\n case 19:\n case \"end\":\n return _context.stop();\n }\n }\n }, _callee, this, [[3, 13]]);\n }));\n\n function delSelectData() {\n return _delSelectData.apply(this, arguments);\n }\n\n return delSelectData;\n }(),\n // 清除【清空输入框的值】\n clearSelectData: function clearSelectData() {\n this.$parent.clearLinkName();\n this.handleClose();\n },\n\n /**\n * 切换分页,每页显示多少条\n */\n handleSizeChange: function handleSizeChange(val) {\n this.nodeLinkParams.linesPerPage = val;\n this.getNodeLinkList();\n },\n\n /**\n * 当前页\n */\n handleCurrentChange: function handleCurrentChange(val) {\n this.nodeLinkParams.pageNo = val;\n this.getNodeLinkList();\n },\n // 点击表格字段\n handleClick: function handleClick(row) {\n this.$emit('selectNodeLinkValue', row);\n this.handleClose();\n },\n\n /**\n * 节点链接 查询\n */\n nodeLinkSearch: function nodeLinkSearch(val) {\n this.nodeLinkParams.name = val.name;\n this.nodeLinkParams.type = val.type;\n this.getNodeLinkList();\n },\n\n /**\n * 节点链接 重置\n */\n resetNodeLinkData: function resetNodeLinkData() {\n this.nodeLinkParams = {\n name: '',\n type: '',\n pageNo: 1,\n linesPerPage: 10\n };\n this.getNodeLinkList();\n },\n // 表单保存\n saveLinkType: function saveLinkType() {\n var _this = this;\n\n var actionContent;\n\n if (this.content.type == '00') {\n actionContent = this.content.actionForm;\n } else if (this.content.type == '01') {\n actionContent = this.content.actionView;\n } else if (this.content.type == '05' || this.content.type == '06') {\n actionContent = this.content.externalLinks;\n }\n\n var params = _objectSpread(_objectSpread({}, this.content), {}, {\n actionContent: actionContent,\n queryString: JSON.stringify(this.content.tb),\n applicationid: sessionStorage.getItem('appId'),\n parentId: sessionStorage.getItem('appId')\n }); // 更新\n\n\n if (this.isEdit) {\n params.id = this.params.id;\n updateLinkDetail(params, {\n onSucess: function onSucess(response) {\n if (response.data.errcode == 0) {\n _this.$message.success(_this.$t('msg.update_ss'));\n\n _this.logoutLinkType('contentForm');\n\n _this.$parent.resetNodeLinkData();\n }\n }\n });\n } else {\n // 新建\n addLinkDetail(sessionStorage.getItem('appId'), params, {\n onSucess: function onSucess(response) {\n if (response.data.errcode == 0) {\n _this.$message.success(_this.$t('msg.created_ss'));\n\n _this.logoutLinkType('contentForm');\n\n _this.$parent.resetNodeLinkData();\n }\n }\n });\n }\n\n setTimeout(function () {\n //保证保存成功即时刷新当前弹框界面\n _this.getNodeLinkList();\n }, 200);\n },\n // 表单退出\n logoutLinkType: function logoutLinkType(formName) {\n this.content = {\n name: '',\n // 名称\n type: '00',\n // 类型\n moduleid: '',\n // 模块\n actionForm: '',\n // 作用表单\n actionView: '',\n // 作用视图\n directory: 'portal',\n // 自定义链接\n externalLinks: '',\n // 扩展链接\n queryString: '',\n // 参数\n tb: [// 参数\n {\n paramKey: '',\n paramValue: ''\n }],\n description: '' // 描述\n\n };\n\n if (this.$refs[formName]) {\n this.$refs[formName].resetFields();\n }\n\n this.isEdit = false;\n this.showLinkType = true;\n },\n // 添加表单单行参数\n addTbParamsSystem: function addTbParamsSystem() {\n this.content.tb.push({\n paramKey: '',\n paramValue: ''\n });\n },\n // 删除表单单行参数\n delTbParamsSystem: function delTbParamsSystem(index) {\n this.content.tb.splice(index, 1);\n },\n // 表单类型的改变\n changeContentType: function changeContentType() {\n this.content.moduleid = '';\n this.content.actionForm = '', // 作用表单\n this.content.actionView = ''; // 作用视图\n },\n // 表单模块的改变\n changeModules: function changeModules() {\n this.moduleFormOptions = [];\n this.moduleViewOptions = [];\n\n var params = _objectSpread(_objectSpread({}, this.params), {}, {\n appId: sessionStorage.getItem('appId'),\n moduleId: this.content.moduleid,\n name: '',\n description: '',\n viewId: '',\n pageNo: 1,\n linesPerPage: 100000\n }); // 清空作用表单视图的值\n\n\n this.content.actionForm = '';\n this.content.actionView = '';\n this.content.externalLinks = '';\n\n if (this.content.type == '00') {\n this.getListFrom(params);\n } else if (this.content.type == '01') {\n this.getListView(params);\n }\n },\n\n /**\n * 获取作用表单\n */\n getListFrom: function getListFrom(params) {\n var _this2 = this;\n\n this.loading = true;\n getModuleFormList(params, {\n onSucess: function onSucess(response) {\n _this2.loading = false;\n\n if (response.data.errcode == 0) {\n var data = response.data.data.datas;\n var dataArr = [];\n\n for (var i = 0; i < data.length; i++) {\n if (data[i].type == 1) {\n dataArr.push(data[i]);\n }\n }\n\n _this2.moduleFormOptions = dataArr;\n }\n }\n });\n },\n\n /**\n * 获取作用视图\n */\n getListView: function getListView(params) {\n var _this3 = this;\n\n this.loading = true;\n getModuleViewList(params, {\n onSucess: function onSucess(response) {\n _this3.loading = false;\n\n if (response.data.errcode == 0) {\n _this3.moduleViewOptions = response.data.data.datas;\n }\n }\n });\n },\n\n /**\n * 获取链接详情列表\n */\n getLinkDetail: function getLinkDetail(linkId) {\n var _this4 = this;\n\n this.loading = true;\n reqLinkDetail(linkId, {\n onSucess: function onSucess(response) {\n if (response.data.errcode == 0) {\n _this4.loading = false;\n var data = response.data.data; // console.log(data)\n\n _this4.content = {\n name: data.name,\n // 名称\n type: data.type,\n // 类型\n moduleid: data.moduleid,\n // 模块\n queryString: data.queryString,\n // 参数\n actionForm: data.type == '00' ? data.actionContent : '',\n // 作用表单\n actionView: data.type == '01' ? data.actionContent : '',\n // 作用视图\n directory: data.directory,\n // 自定义链接\n externalLinks: data.type == '05' || data.type == '06' ? data.actionContent : '',\n // 扩展链接\n tb: data.queryString ? eval(data.queryString) : [],\n description: data.description // 描述\n\n };\n }\n }\n });\n },\n\n /**\n * 获取所有模块\n */\n\n /**\n * 获取菜单树形结构所有模块列表\n */\n getAllmodules: function () {\n var _getAllmodules2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2() {\n var appId, currentModuleId, response;\n return regeneratorRuntime.wrap(function _callee2$(_context2) {\n while (1) {\n switch (_context2.prev = _context2.next) {\n case 0:\n appId = sessionStorage.getItem('appId');\n currentModuleId = '';\n this.loading = true;\n _context2.next = 5;\n return _getAllmodules(appId, currentModuleId);\n\n case 5:\n response = _context2.sent;\n\n if (response.data.errcode == 0) {\n this.loading = false;\n this.allmodulesData = response.data.data;\n }\n\n case 7:\n case \"end\":\n return _context2.stop();\n }\n }\n }, _callee2, this);\n }));\n\n function getAllmodules() {\n return _getAllmodules2.apply(this, arguments);\n }\n\n return getAllmodules;\n }(),\n\n /**\n * 获取节点链接的数据\n */\n getNodeLinkList: function getNodeLinkList() {\n var _this5 = this;\n\n var params = _objectSpread(_objectSpread({}, this.nodeLinkParams), {}, {\n appId: sessionStorage.getItem('appId')\n });\n\n reqLinkList(params, {\n onSucess: function onSucess(response) {\n if (response.data.errcode == 0) {\n var data = response.data.data.datas;\n\n for (var i = 0; i < data.length; i++) {\n if (data[i].type == '00') {\n data[i].typeName = _this5.$t('view.form');\n } else if (data[i].type == '01') {\n data[i].typeName = _this5.$t('view.view');\n } else if (data[i].type == '05') {\n data[i].typeName = _this5.$t('label.url_in');\n } else if (data[i].type == '06') {\n data[i].typeName = _this5.$t('label.url_out');\n } else if (data[i].type == '08') {\n data[i].typeName = _this5.$t('label.email_url');\n }\n }\n\n _this5.nodeLinkData = response.data.data;\n }\n }\n });\n }\n },\n created: function created() {\n this.getAllmodules();\n this.getNodeLinkList();\n },\n props: {\n nodeLinkVisiable: {\n type: Boolean\n }\n },\n computed: {\n showModule: function showModule() {\n return this.content.type != '05' && this.content.type != '06';\n }\n }\n};",null]}