{"remainingRequest":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\reform-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\reform-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\reform-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\reform-fvue\\src\\views\\MajorReformProjects\\ExperPromotion\\components\\ExperPromotionDialog.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\reform-fvue\\src\\views\\MajorReformProjects\\ExperPromotion\\components\\ExperPromotionDialog.vue","mtime":1687328695034},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.regexp.split\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 UploadFile from '@/components/uploadFile/index.vue';\nimport FileList from '@/components/uploadFile/FileList.vue';\nimport req from '@/request.js';\nimport sat from '@/api/satisfaction/satisfaction';\nimport { TableMixin } from '@/mixins/tableMixin';\nvar portal = window.context.portal;\nexport default {\n name: 'ReformPilotManageDialog',\n components: {\n UploadFile: UploadFile,\n FileList: FileList\n },\n mixins: [TableMixin],\n data: function data() {\n return {\n formVisible: false,\n reqLoading: false,\n markLoading: false,\n dialogVisible: false,\n apperLoading: false,\n saveLoading: false,\n fileList: [],\n hisData: null,\n title: '',\n queryParam: {\n pageBean: {\n page: 1,\n pageSize: -1\n }\n },\n rules: {\n promotionContent: [{\n required: true,\n message: '请输入具体情况简介',\n trigger: 'change'\n }],\n promotionType: [{\n required: true,\n message: '请选择推广方式',\n trigger: 'change'\n }],\n promotionDate: [{\n required: true,\n message: '请选择推广日期',\n trigger: 'change'\n }]\n },\n params: {\n pageBean: {\n page: 1,\n pageSize: 20,\n showTotal: true\n },\n params: {},\n querys: [{\n group: 'main',\n operation: 'EQUAL',\n parentGroup: '',\n property: '',\n relation: 'AND',\n value: ''\n }]\n },\n activeCollapse: ['1', '2', '3', '4'],\n specificDetailOptions: [],\n primaryFileList: [],\n tableData: {\n pilotExperiencePushList: [{\n classified: '',\n promotionContent: '',\n promotionType: '',\n promotionDate: '',\n defaultFileList: [],\n fillId: '',\n projectId: ''\n }]\n },\n addFileIndex: 0,\n showDetails: false,\n //详情展示\n showAdd: false,\n //添加展示\n projectInfo: {}\n };\n },\n created: function created() {},\n methods: {\n //\n openForm: function openForm(item, title) {\n var _this = this;\n\n this.projectInfo = item;\n this.title = title;\n\n if (this.title == '详情' || this.title == '编辑') {\n this.reqLoading = true;\n var data = [];\n var list = [];\n this.hisData = {\n pilotExperiencePushList: []\n };\n var param = {\n querys: [],\n pageBean: {\n pageSize: 2\n },\n sorter: [{\n direction: 'DESC',\n property: 'lastTime'\n }]\n };\n param.querys.push({\n group: 'main',\n operation: 'EQUAL',\n parentGroup: '',\n property: 'projectId',\n relation: 'AND',\n value: this.projectInfo.projectId\n }, {\n group: 'main',\n operation: 'EQUAL',\n parentGroup: '',\n property: 'flowType',\n relation: 'AND',\n value: 3\n });\n var url = '/majorProjects/bizPilotExperiencePush/v1/queryHistory';\n req.post(portal + url, param).then(function (res) {\n if (res.data.state) {\n data = res.data.value;\n console.log(data, 'data'); // data.forEach(e => {\n // if (item.status == 5&&data.length>1) {\n // this.tableData = data[0]\n // this.hisData = data[1]\n // return\n // }else if(item.status == 5&&data.length<=1){\n // this.tableData = data[0]\n // this.hisData = {\n // pilotExperiencePushList:[]\n // }\n // }\n // else\n // if((item.status==1||item.status==3)&&data.length>1){\n // this.tableData = data[0]\n // this.hisData = data[1]\n // return\n // }else if((item.status==1||item.status==3)&&data.length<=1){\n // this.tableData = data[0]\n // this.hisData = {\n // pilotExperiencePushList:[]\n // }\n // return\n // }\n // })\n\n _this.tableData = data[0];\n _this.hisData = data[1];\n _this.tableData.approvalCommentsList = _this.tableData.approvalComments ? _this.tableData.approvalComments.split('$_$') : [];\n\n if (_this.hisData && _this.hisData.approvalComments) {\n _this.hisData.approvalCommentsList = _this.hisData.approvalComments ? _this.hisData.approvalComments.split('$_$') : [];\n }\n\n _this.markLoading = false;\n _this.reqLoading = false;\n } else {\n _this.reqLoading = false;\n }\n });\n this.showDetails = true;\n } // if (this.title == '编辑') {\n // this.reqLoading = true\n // let data = []\n // let list = []\n // this.hisData={\n // pilotExperiencePushList:[]\n // }\n // let param = {\n // querys: [],\n // pageBean: {\n // pageSize: 2\n // },\n // sorter: [\n // {\n // direction: 'DESC',\n // property: 'lastTime'\n // }\n // ]\n // }\n // param.querys.push(\n // {\n // group: 'main',\n // operation: 'EQUAL',\n // parentGroup: '',\n // property: 'projectId',\n // relation: 'AND',\n // value: this.projectInfo.projectId\n // },\n // {\n // group: 'main',\n // operation: 'EQUAL',\n // parentGroup: '',\n // property: 'flowType',\n // relation: 'AND',\n // value: 3\n // }\n // )\n // let url = '/majorProjects/bizPilotExperiencePush/v1/queryHistory'\n // req.post(portal + url, param).then(res => {\n // if (res.data.state) {\n // data = res.data.value\n // data.forEach(item => {\n // console.log(item)\n // if (item.status == 5) {\n // return (this.hisData = item)\n // } else {\n // return (this.tableData = item)\n // }\n // })\n // this.tableData.approvalCommentsList = this.tableData.approvalComments\n // ? this.tableData.approvalComments.split('$_$')\n // : []\n // this.hisData.approvalCommentsList = this.hisData.approvalComments\n // ? this.hisData.approvalComments.split('$_$')\n // : []\n // console.log(data, 'data')\n // this.markLoading = false\n // this.reqLoading = false\n // } else {\n // this.reqLoading = false\n // }\n // })\n // }\n\n\n if (this.title == '更新') {\n this.reqLoading = true;\n var _data = [];\n this.hisData = {\n pilotExperiencePushList: []\n };\n var _list = [];\n var _param = {\n querys: [],\n pageBean: {\n pageSize: 2\n },\n sorter: [{\n direction: 'DESC',\n property: 'lastTime'\n }]\n };\n\n _param.querys.push({\n group: 'main',\n operation: 'EQUAL',\n parentGroup: '',\n property: 'projectId',\n relation: 'AND',\n value: this.projectInfo.projectId\n }, {\n group: 'main',\n operation: 'EQUAL',\n parentGroup: '',\n property: 'flowType',\n relation: 'AND',\n value: 3\n });\n\n var _url = '/majorProjects/bizPilotExperiencePush/v1/queryHistory';\n req.post(portal + _url, _param).then(function (res) {\n if (res.data.state) {\n _data = res.data.value;\n console.log(_data);\n\n _data.forEach(function (item) {\n console.log(item);\n\n if (item.status == 5 || item.status == 2 || item.status == 4) {\n _this.hisData = _data[0];\n }\n });\n\n _this.tableData.approvalCommentsList = _this.tableData.approvalComments ? _this.tableData.approvalComments.split('$_$') : [];\n\n if (_this.hisData && _this.hisData.approvalComments) {\n _this.hisData.approvalCommentsList = _this.hisData.approvalComments ? _this.hisData.approvalComments.split('$_$') : [];\n }\n\n _this.markLoading = false;\n _this.reqLoading = false;\n } else {\n _this.reqLoading = false;\n }\n });\n }\n\n if (this.title == '添加') {\n this.hisData = null;\n this.showAdd = true;\n }\n\n this.formVisible = true;\n },\n // 表单提交保存\n submit: function submit(status) {\n var _this2 = this;\n\n this.tableData.status = status;\n this.tableData.pilotExperiencePushList.forEach(function (item) {\n item.projectId = _this2.projectInfo.projectId;\n });\n\n if (status == 0) {\n this.apperLoading = true;\n }\n\n if (status == 1) {\n this.saveLoading = true;\n }\n\n this.$refs.form.validate(function (valid) {\n if (valid) {\n _this2.loading = true;\n var url = null;\n console.log(_this2.tableData, 'tableData');\n url = '/majorProjects/bizPilotExperiencePush/v1/saveDraftOrCommit';\n req.put(portal + url, _this2.tableData).then(function (res) {\n if (res.data.state) {\n _this2.saveLoading = false;\n _this2.apperLoading = false;\n _this2.formVisible = false;\n\n _this2.$parent.loadData(_this2.params);\n\n _this2.$message.success('保存成功');\n } else {\n _this2.saveLoading = false;\n _this2.apperLoading = false;\n\n _this2.$message.error('保存失败');\n }\n\n _this2.loading = false;\n }).catch(function () {\n _this2.loading = false;\n _this2.saveLoading = false;\n _this2.apperLoading = false;\n });\n } else {\n _this2.saveLoading = false;\n _this2.apperLoading = false;\n return false;\n }\n });\n },\n setAipher: function setAipher() {\n this.tableData.pilotExperiencePushList[this.addFileIndex].classified = '文件涉密,已通过内网邮件上传。';\n },\n // 根据项目id查询品牌推进信息\n getformById: function getformById(id) {\n brand.getformById(id, function (res) {\n console.log(res);\n });\n },\n addTableData: function addTableData() {\n var data = {\n classified: '',\n promotionContent: '',\n promotionType: '',\n promotionDate: '',\n defaultFileList: [],\n fillId: '',\n projectId: ''\n };\n this.tableData.pilotExperiencePushList.push(data);\n },\n deleteTableData: function deleteTableData(index) {\n if (this.tableData.pilotExperiencePushList.length > 1) {\n this.tableData.pilotExperiencePushList.splice(index, 1);\n } else {\n // this.$alert('至少保留一条本次状态更新!', '提示!', {\n // confirmButtonText: '确定'\n // })\n this.$confirm('至少保留一条本次状态更新!', this.$t('common.tips'), {\n confirmButtonText: this.$t('common.confirm'),\n cancelButtonText: this.$t('common.cancel'),\n type: 'warning'\n });\n return false;\n }\n },\n // ------------\n // 文件相关\n openUploade: function openUploade(index) {\n this.addFileIndex = index;\n console.log(index);\n this.$refs.uploadFile.open('ProjectExperience');\n },\n setFileList: function setFileList(file) {\n var _this3 = this;\n\n this.tableData.pilotExperiencePushList[this.addFileIndex].defaultFileList = [];\n var data = this.tableData;\n data.pilotExperiencePushList[this.addFileIndex].defaultFileList.push(file);\n data.pilotExperiencePushList.forEach(function (item) {\n _this3.tableData.pilotExperiencePushList.forEach(function (val) {\n item.defaultFileList.forEach(function (e) {\n val.defaultFileList.forEach(function (v) {\n if (e.response.fileId == v.response.fileId) {\n e['id'] = v.response.fileId;\n }\n });\n });\n });\n\n return item;\n });\n this.tableData = data;\n },\n changeFileList: function changeFileList(data, index) {\n this.tableData.pilotExperiencePushList[index].defaultFileList = data;\n },\n // ------------\n handleClose: function handleClose() {\n var _this4 = this;\n\n this.formVisible = false;\n this.showDetails = false;\n this.showAdd = false;\n this.title = '';\n this.tableData = {\n pilotExperiencePushList: [{\n classified: '',\n promotionContent: '',\n promotionType: '',\n promotionDate: '',\n defaultFileList: []\n }]\n };\n this.hisData = null;\n this.$nextTick(function () {\n _this4.$refs.form.clearValidate();\n });\n }\n }\n};",null]}