{"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\\flow\\WatermarkManager.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\src\\views\\flow\\WatermarkManager.vue","mtime":1675071992835},{"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/es7.object.get-own-property-descriptors\";\nimport \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.object.keys\";\nimport \"core-js/modules/es6.function.name\";\nimport _defineProperty from \"D:/jenkins/workspace/xq-web-bpm/node_modules/@babel/runtime/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//\nimport flow from \"@/api/flow.js\";\nimport uc from \"@/api/uc.js\";\n\nvar watermarkTypeDialog = function watermarkTypeDialog() {\n return import(\"@/components/flow/WatermarkTypeDialog.vue\");\n};\n\nvar watermarkSetProcessDialog = function watermarkSetProcessDialog() {\n return import(\"@/components/flow/WatermarkSetProcessDialog\");\n};\n\nexport default {\n name: \"watermark-manager\",\n components: {\n watermarkTypeDialog: watermarkTypeDialog,\n watermarkSetProcessDialog: watermarkSetProcessDialog\n },\n data: function data() {\n return {\n data: [],\n pageResult: {\n page: 1,\n pageSize: 20,\n total: 0\n },\n deleteUrl: window.context.bpmModel + \"/bpmModel/bpmWatermark/v1/remove\",\n saveUrl: window.context.bpmModel + \"/bpmModel/bpmWatermark/v1/save\",\n dialogVisible: false,\n typeDialogVisible: false,\n title: \"\",\n watermark: {\n name: \"\",\n type: 1,\n content: \"\",\n color: \"rgba(255, 69, 0, 0.68)\"\n },\n typeArray: [{\n text: \"文字\",\n value: 1\n }, {\n text: \"图片\",\n value: 2\n }],\n selectRow: {},\n isSubmit: true\n };\n },\n methods: {\n loadData: function loadData(param, cb) {\n var _this = this;\n\n flow.getWatermarkList(param).then(function (data) {\n _this.data = data.rows;\n _this.pageResult = {\n page: data.page,\n pageSize: data.pageSize,\n total: data.total\n };\n }).finally(function () {\n cb && cb();\n });\n },\n edit: function edit(id) {\n var _this2 = this;\n\n this.dialogVisible = true;\n\n if (id) {\n this.title = \"编辑流程水印\";\n flow.getWatermark(id).then(function (data) {\n _this2.watermark = data;\n });\n } else {\n this.title = \"添加流程水印\";\n this.watermark = {\n name: \"\",\n type: 1,\n content: \"\",\n color: \"rgba(255, 69, 0, 0.68)\"\n };\n }\n },\n handleClose: function handleClose() {\n this.dialogVisible = false;\n this.typeDialogVisible = false;\n },\n beforeSaveData: function beforeSaveData() {\n this.isSubmit = true;\n\n if (this.watermark.type == 2) {\n if (!this.watermark.content || this.watermark.content == undefined) {\n this.$message.error(\"请上传图片\");\n this.isSubmit = false;\n }\n }\n },\n afterSaveData: function afterSaveData() {\n this.dialogVisible = false;\n this.$refs.htTable.load();\n },\n setType: function setType(row) {\n this.selectRow = _objectSpread({}, row);\n this.$refs.watermarkTypeDialog.showDialog();\n },\n setProcess: function setProcess(row) {\n this.selectRow = _objectSpread({}, row);\n this.$refs.watermarkSetProcessDialog.showDialog();\n },\n updateImage: function updateImage(param) {\n var _this3 = this;\n\n var formData = new FormData();\n formData.append(\"files\", param.file);\n uc.fileUpload(formData).then(function (response) {\n _this3.$store.dispatch(\"menu/downloadImg\", response.fileId).then(function (res) {\n if (res != \"\") {\n _this3.$set(_this3.watermark, \"content\", res);\n\n param.onSuccess(); // 上传成功的图片会显示绿色的对勾\n }\n }).catch(function () {\n param.onError();\n });\n }).catch(function () {\n param.onError();\n });\n },\n beforeUpload: function beforeUpload(file) {\n var fileType = file.name.substring(file.name.lastIndexOf('.') + 1);\n\n if (fileType != \"jpg\" && fileType != \"png\") {\n this.$message.warning(\"只能上传jpg/png格式的文件\");\n return false;\n } else {\n return true;\n }\n }\n }\n};",null]}