{"remainingRequest":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\xypm-web\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\xypm-web\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\xypm-web\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\xypm-web\\src\\views\\CompletionAcceptance\\UnitProjectAcceptance.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xypm-web\\src\\views\\CompletionAcceptance\\UnitProjectAcceptance.vue","mtime":1675214577839},{"path":"D:\\jenkins\\workspace\\xypm-web\\babel.config.js","mtime":1675214572901},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\babel-loader\\lib\\index.js","mtime":456789000000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/web.dom.iterable\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 req from '@/request.js';\nimport ProjectInfoDialog from '@/components/dialog/ProjectInfoDialog.vue';\nexport default {\n  name: 'unitProjectAcceptance',\n  components: {\n    ProjectInfoDialog: ProjectInfoDialog\n  },\n  props: {\n    pid: {\n      type: String,\n      default: ''\n    },\n    isShow: {\n      type: Boolean,\n      default: true\n    }\n  },\n  data: function data() {\n    return {\n      importData: {\n        title: '单位工程验收',\n        templateName: '单位工程验收模板.xls',\n        downloadUrl: '/../fvue/static/excel/unitProjectAcceptance.xlsx',\n        importUrl: window.context.cqxy + '/biz/completionAcceptance/unitProjectAcceptance/v1/importExcelData',\n        showProject: true,\n        projectId: ''\n      },\n      projectObj: [],\n      loading: false,\n      searchForm: {\n        projectId: '',\n        completionAcceptanceDate: '',\n        approvalFilingAuthorityDate: '',\n        sketch: ''\n      },\n      //顶部搜索参数\n      data: [],\n      //表格数据\n      pageResult: {\n        page: 1,\n        pageSize: 20,\n        total: 0\n      },\n      form: {},\n      dialogVisible: false,\n      dialogTitle: '添加',\n      indexArr: [],\n      querySearch: [],\n      rules: {\n        'projectInfo.projectName': {\n          required: true,\n          message: '请选择项目名称',\n          trigger: 'blur'\n        },\n        'projectInfo.projectCode': {\n          required: true,\n          message: '请选择项目代码',\n          trigger: 'blur'\n        },\n        handlerName: {\n          required: true,\n          message: '请输入经办人',\n          trigger: 'blur'\n        },\n        handlerUnit: {\n          required: true,\n          message: '请输入参数单位',\n          trigger: 'blur'\n        },\n        acceptanceDate: {\n          required: true,\n          message: '请选择验收时间',\n          trigger: 'blur'\n        },\n        acceptancePlace: {\n          required: true,\n          message: '请输入验收地点',\n          trigger: 'blur'\n        }\n      }\n    };\n  },\n  computed: {\n    deleteUrl: function deleteUrl() {\n      return window.context.cqxy + '/biz/completionAcceptance/unitProjectAcceptance/v1/delete';\n    }\n  },\n  mounted: function mounted() {\n    this.initProjectAll();\n  },\n  methods: {\n    handleReset: function handleReset() {\n      var _this = this;\n      this.searchForm.projectId = '';\n      this.searchForm.acceptanceDate = '';\n      this.searchForm.sketch = '';\n      this.$refs['searchForm'].resetFields();\n      this.pageResult = {\n        page: 1,\n        pageSize: 20,\n        total: 0\n      };\n      this.$nextTick(function () {\n        _this.$refs.AtTable.load();\n      });\n    },\n    //导入后重新加载数据\n    load: function load() {\n      this.$refs.AtTable.load();\n    },\n    //导出\n    handleExport: function handleExport() {\n      var _this2 = this;\n      var query = [];\n      var search = {\n        'pm.ID_': this.searchForm.projectId,\n        sketch_: this.searchForm.sketch,\n        acceptance_date_: this.searchForm.acceptanceDate\n      };\n      if (!this.isShow) {\n        search['pm.ID_'] = this.pid;\n      }\n      for (var i in search) {\n        if (search[i]) {\n          query.push({\n            group: 'advance',\n            operation: 'LIKE',\n            property: i,\n            relation: 'AND',\n            value: search[i]\n          });\n        }\n      }\n      var param = {\n        pageBean: {\n          page: 1,\n          pageSize: -1,\n          showTotal: true\n        },\n        querys: query,\n        sorter: []\n      };\n      req.downloadPostCopy('${cqxy}/biz/completionAcceptance/unitProjectAcceptance/v1/exportDataToExcel', param).then(function (res) {\n        if (res.status === 200) {\n          _this2.$message.success('导出成功');\n        } else {\n          _this2.$message.error('导出失败');\n        }\n      });\n    },\n    handleFile: function handleFile(file) {\n      this.form.accessoryInfo = file;\n    },\n    handleAdd: function handleAdd() {\n      this.dialogTitle = '添加';\n      this.form = {\n        handlerUnit: '西永微电子产业园区开发有限公司',\n        projectId: '',\n        projectInfo: {\n          projectName: '',\n          projectCode: ''\n        },\n        accessoryInfo: []\n      };\n      this.dialogVisible = true;\n      this.form.projectInfo.projectName = this.projectObj.projectName;\n      this.form.projectInfo.projectCode = this.projectObj.projectCode;\n      this.form.handlerName = this.projectObj.projectManager;\n      this.form.projectId = this.projectObj.id;\n    },\n    handleRowDBClick: function handleRowDBClick(data) {\n      this.dialogTitle = '修改';\n      this.form = data;\n      this.dialogVisible = true;\n    },\n    handleFocusProject: function handleFocusProject() {\n      this.$refs.project.open();\n    },\n    openProject: function openProject() {\n      this.$refs.project.open();\n    },\n    handleSelectProject: function handleSelectProject(data) {\n      this.form.projectId = data.id;\n      this.form.projectInfo.projectCode = data.projectCode;\n      this.form.projectInfo.projectName = data.projectName;\n      this.form.handlerName = data.projectManager;\n      this.$refs.form.clearValidate();\n    },\n    handleSelect: function handleSelect(selection) {},\n    handleDialogCancel: function handleDialogCancel() {\n      this.dialogVisible = false;\n    },\n    handleDialogClose: function handleDialogClose() {\n      this.dialogVisible = false;\n    },\n    //初始获取单个项目数据\n    initProjectAll: function initProjectAll() {\n      var _this3 = this;\n      this.$http.post('${cqxy}/biz/projectManagement/pm/v1/detail/' + this.pid).then(function (res) {\n        _this3.projectObj = res.data.value;\n      }, function (error) {\n        reject(error);\n      });\n    },\n    //提交保存\n    handleDialogSubmit: function handleDialogSubmit() {\n      var _this4 = this;\n      this.$refs.form.validate(function (valid) {\n        if (valid) {\n          if (_this4.form.accessoryInfo && _this4.form.accessoryInfo.length > 0) {\n            _this4.form.accessoryInfo.forEach(function (item) {\n              if (item.id) {\n                delete item.id;\n              }\n            });\n          }\n          _this4.loading = true;\n          _this4.$http.post('${cqxy}/biz/completionAcceptance/unitProjectAcceptance/v1/save', _this4.form).then(function (res) {\n            if (res.data.state) {\n              _this4.$refs.form.resetFields();\n              _this4.$message.success(res.data.message);\n              _this4.dialogVisible = false;\n              _this4.$refs.AtTable.load();\n            } else {\n              _this4.$message.error(res.data.message);\n            }\n            _this4.loading = false;\n          });\n        } else {\n          _this4.$message({\n            message: '*号必填项,不能为空!',\n            type: 'warning'\n          });\n          return false;\n        }\n      });\n    },\n    loadData: function loadData(param, cb) {\n      var _this5 = this;\n      var query = [];\n      var search = {\n        project_id_: this.searchForm.projectId,\n        acceptance_date_: this.searchForm.acceptanceDate,\n        sketch_: this.searchForm.sketch\n      };\n      if (!this.isShow) {\n        search['project_id_'] = this.pid;\n        this.importData.projectId = this.pid;\n      }\n      for (var i in search) {\n        if (search[i]) {\n          query.push({\n            group: 'advance',\n            operation: 'LIKE',\n            property: i,\n            relation: 'AND',\n            value: search[i]\n          });\n        }\n      }\n      if (param.querys && param.querys.length) {\n        var _param$querys;\n        (_param$querys = param.querys).push.apply(_param$querys, query);\n      } else {\n        param.querys = query;\n      }\n      this.$http.post('${cqxy}/biz/completionAcceptance/unitProjectAcceptance/v1/page', param).then(function (resp) {\n        console.log(resp);\n        var response = resp.data.value;\n        _this5.data = response.rows;\n        _this5.pageResult = {\n          page: response.page,\n          pageSize: response.pageSize,\n          total: response.total\n        };\n      }, function (error) {\n        reject(error);\n      }).finally(function () {\n        if (cb) {\n          cb();\n        }\n      });\n    },\n    findinfo: function findinfo() {\n      this.$refs.AtTable.load();\n    }\n  }\n};",null]}