{"remainingRequest":"D:\\jenkins\\workspace\\yhxt-web\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\yhxt-web\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\yhxt-web\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\yhxt-web\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\yhxt-web\\src\\views\\dailyMaintenance\\MaintenanceAssessment.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\yhxt-web\\src\\views\\dailyMaintenance\\MaintenanceAssessment.vue","mtime":1718734388417},{"path":"D:\\jenkins\\workspace\\yhxt-web\\babel.config.js","mtime":1667326389982},{"path":"D:\\jenkins\\workspace\\yhxt-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\yhxt-web\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\yhxt-web\\node_modules\\babel-loader\\lib\\index.js","mtime":456789000000},{"path":"D:\\jenkins\\workspace\\yhxt-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\yhxt-web\\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 _typeof from \"D:/jenkins/workspace/yhxt-web/node_modules/@babel/runtime/helpers/esm/typeof.js\";\nimport _defineProperty from \"D:/jenkins/workspace/yhxt-web/node_modules/@babel/runtime/helpers/esm/defineProperty.js\";\nimport \"core-js/modules/es6.string.iterator\";\nimport \"core-js/modules/es6.map\";\nimport \"core-js/modules/es6.function.name\";\nimport \"core-js/modules/es6.number.constructor\";\nimport \"core-js/modules/web.dom.iterable\";\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; }\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//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 { mapState } from 'vuex';\nimport basicData from '@/api/basicData.js';\nimport sctionInfoSelector from '@/components/selector/sctionInfoSelector.vue';\nimport companyInfoSelector from '@/components/selector/companyInfoSelector.vue';\nimport Dict from '@/components/dict/DictSelectUtils.js';\nimport req from '@/request.js';\nimport CascaderCompany from '@/components/selector/CascaderCompany.vue';\nexport default {\n components: {\n // sctionInfoSelector,\n // companyInfoSelector,\n CascaderCompany: CascaderCompany\n },\n data: function data() {\n return {\n dadToSon: {\n bizPath: 'contract',\n fileList: []\n },\n roadData: [],\n companyOptions: [],\n searchForm: {},\n options: [],\n dialogVisibleEnclosure: false,\n form: {\n roadSegmentName: '',\n isTemporary: 0\n },\n dialogVisible: false,\n title: '',\n data: [],\n pageResult: {\n page: 1,\n pageSize: 20,\n total: 0\n },\n rules: {\n roadName: [{\n required: true,\n message: '请选择所属路段',\n trigger: 'blur'\n }],\n itemName: [{\n required: true,\n message: '请输入合同名称',\n trigger: 'blur'\n }],\n assessmentQuarter: [{\n required: true,\n message: '请选择考核季度',\n trigger: 'blur'\n }],\n startDate: [{\n required: true,\n message: '请选择开始时间',\n trigger: 'blur'\n }],\n endDate: [{\n required: true,\n message: '请选择结束时间',\n trigger: 'blur'\n }]\n },\n accessories: [],\n isShowDate: false,\n //是否填写开始时间和结束时间\n activeName: 'first',\n tableData: [],\n checkDetailArr: [],\n //检查明细\n contract: [],\n //合同信息\n dictSelection: [],\n //勾选复选框\n loading: false,\n //加载\n roadName_: '',\n itemName_: '',\n lock: true,\n //判断是否是在修改,true是修改时改变了表单的值\n tableDataLoading: false\n };\n },\n created: function created() {\n this.roadData = this.getroad();\n this.company = this.getCompany();\n this.contract = this.getContract();\n // this.getCheckDetail() //获取检查明细列表\n },\n\n methods: {\n //导出\n handelExport: function handelExport() {\n var _this = this;\n if (!this.dictSelection.length) {\n this.$message.warning(\"\\u8BF7\\u9009\\u62E9\\u8981\\u5BFC\\u51FA\\u7684\\u6570\\u636E\");\n return;\n } else {\n var msg = \"\\u786E\\u5B9A\\u5BFC\\u51FA\\u9009\\u4E2D\\u6570\\u636E\\u5417?\";\n this.$confirm(msg, '提示', {\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n type: 'warning'\n }).then(function () {\n var ids = [];\n _this.dictSelection.forEach(function (item) {\n ids.push(item.curingAssessment.id);\n });\n var param = _this.qs.stringify({\n ids: ids.join(',')\n });\n // 调用接口 提交数据\n var url = window.context.yhxt + '/assessment/curingAssessment/v1/exportCuringAssessment?' + param;\n req.downloadGet(url);\n _this.dictSelection = [];\n // this.$http.get(\n // '${yhxt}/assessment/curingAssessment/v1/exportCuringAssessment?' +\n // param\n // )(res => {\n // this.dictSelection = []\n // this.$refs.htTable.load()\n // })\n }).catch(function () {\n _this.$message({\n type: 'info',\n message: \"\\u5DF2\\u5BFC\\u51FA\\u9009\\u4E2D\\u7684\\u6570\\u636E\"\n });\n _this.$refs.htTable.load(); //重新获取数据\n });\n }\n },\n handleSelect: function handleSelect(selection) {\n this.dictSelection = selection;\n },\n handleDelete: function handleDelete() {\n var _this2 = this;\n if (!this.dictSelection.length) {\n this.$message.warning(\"\\u8BF7\\u9009\\u62E9\\u8981\\u5220\\u9664\\u7684\\u6570\\u636E\");\n return;\n } else {\n var msg = \"\\u786E\\u5B9A\\u5220\\u9664\\u9009\\u4E2D\\u6570\\u636E\\u5417?\";\n this.$confirm(msg, '提示', {\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n type: 'warning'\n }).then(function () {\n var ids = [];\n _this2.dictSelection.forEach(function (item) {\n ids.push(item.curingAssessment.id);\n });\n var param = _this2.qs.stringify({\n ids: ids.join(',')\n });\n // 调用接口 提交数据\n _this2.$http.remove('${yhxt}/assessment/curingAssessment/v1/?' + param)(function (res) {\n _this2.dictSelection = [];\n _this2.$refs.htTable.load();\n });\n }).catch(function () {\n _this2.$message({\n type: 'info',\n message: \"\\u5DF2\\u5220\\u9664\\u9009\\u4E2D\\u7684\\u6570\\u636E\"\n });\n _this2.$refs.htTable.load(); //重新获取数据\n });\n }\n },\n //计算得分\n handleScorechange: function handleScorechange() {\n var sumScore = 0;\n this.tableData.forEach(function (item) {\n sumScore += Number(item.score);\n });\n if (isNaN(sumScore)) {\n sumScore = 0;\n }\n //解决实时更新数据\n this.$set(this.form, 'score', sumScore);\n },\n //获取合同信息\n getContract: function getContract() {\n var arr = [];\n this.$http.post('${yhxt}/contract/v1/getJson').then(function (res) {\n // console.log(res, 'ddddd')\n res.data.rows.forEach(function (item) {\n arr.push({\n itemName: item.name,\n itemId: item.id,\n itemNomber: item.contractNumber\n });\n });\n });\n return arr;\n },\n //获取检查明细\n getCheckDetail: function getCheckDetail() {\n var _this3 = this;\n var params = {\n pageBean: {\n page: 1,\n pageSize: -1,\n showTotal: true\n },\n querys: [{\n group: 'advance',\n operation: 'EQUAL',\n property: 'ROAD_ID_',\n relation: 'AND',\n value: this.form.roadId\n }]\n };\n this.tableDataLoading = true;\n this.$http.post('${yhxt}/assessment/curingAssessmentItem/v1/query', params).then(function (res) {\n _this3.tableDataLoading = false;\n var data = res.data.rows;\n data.forEach(function (item) {\n item.checkSituation = '';\n item.score = '';\n item.remarks = '';\n });\n // this.checkDetailArr = data\n _this3.tableData = data;\n });\n },\n handleClick: function handleClick(tab, event) {\n console.log(tab, event);\n },\n sonToDad: function sonToDad(data) {\n console.log(data);\n this.accessories = data;\n },\n //路段信息赋值\n changed: function changed(obj) {\n this.form.roadSegmentName = obj.name;\n this.form.roadSegmentId = obj.id;\n },\n handleSelectionChangeEnclosure: function handleSelectionChangeEnclosure(rows) {\n var _this4 = this;\n rows.forEach(function (item) {\n _this4.ids.push(item.id);\n });\n },\n // handleClick(tab, event) {\n // console.log(tab, event)\n // },\n beforeCloseDialog: function beforeCloseDialog() {\n this.dialogVisible = false;\n },\n uniqueFunc: function uniqueFunc(arr, uniId) {\n var res = new Map();\n return arr.filter(function (item) {\n return !res.has(item[uniId]) && res.set(item[uniId], 1);\n });\n },\n handleReset: function handleReset() {\n this.searchForm = _objectSpread(_objectSpread({}, this.searchForm), {}, {\n companyId: ['1419863231459102720'],\n roadName: '',\n itemName: '',\n assessmentQuarter: '',\n startDate: '',\n endDate: ''\n });\n this.findinfo();\n },\n findinfo: function findinfo() {\n var _this5 = this;\n typeof this.$refs.filterTable !== 'undefined' && this.$refs.filterTable.clearFilter();\n var query = [];\n var search = {\n company_id_: this.searchForm.companyIds,\n road_id_: this.searchForm.roadName,\n item_name_: this.searchForm.itemName,\n assessment_quarter_: this.searchForm.assessmentQuarter,\n start_date_: this.searchForm.startDate,\n end_date_: this.searchForm.endDate\n };\n for (var i in search) {\n if (search[i]) {\n if (i == 'company_id_') {\n query.push({\n group: 'companyIds',\n operation: 'IN',\n parentGroup: '',\n property: 'COMPANY_ID_',\n relation: 'AND',\n value: search[i]\n });\n } else if (i == 'road_id_') {\n query.push({\n group: 'main',\n operation: 'EQUAL',\n parentGroup: '',\n property: 'road_id_',\n relation: 'AND',\n value: search[i]\n });\n } else if (i == 'start_date_') {\n query.push({\n group: 'main',\n operation: 'GREAT_EQUAL',\n parentGroup: '',\n property: 'start_date_',\n relation: 'AND',\n value: search[i]\n });\n } else if (i == 'end_date_') {\n query.push({\n group: 'main',\n operation: 'LESS_EQUAL',\n parentGroup: '',\n property: 'end_date_',\n relation: 'AND',\n value: search[i]\n });\n } else {\n query.push({\n group: 'advance',\n operation: 'LIKE',\n property: i,\n relation: 'AND',\n value: search[i]\n });\n }\n }\n }\n query = this.uniqueFunc(query, 'property');\n var data = {\n pageBean: {\n page: 1,\n pageSize: 20,\n showTotal: true\n },\n querys: query\n };\n this.topQuery = query;\n this.$http.post('${yhxt}/assessment/curingAssessment/v1/getJson', data).then(function (res) {\n console.log(res, '11');\n _this5.data = res.data.rows;\n _this5.pageResult = {\n page: res.data.page,\n pageSize: res.data.pageSize,\n total: res.data.total\n };\n });\n },\n getroad: function getroad() {\n var arr = [];\n basicData.getRoadManagement().then(function (res) {\n res.rows.forEach(function (item) {\n arr.push({\n roadName: item.name,\n roadId: item.id,\n companyId: item.companyId,\n companyName: item.companyName\n });\n });\n console.log(arr, '12');\n });\n return arr;\n },\n loadData: function loadData(param, cb) {\n var _this6 = this;\n if (typeof this.topQuery !== 'undefined' && this.topQuery.length !== 0) {\n param.querys = typeof param.querys !== 'undefined' ? param.querys : [];\n this.topQuery.forEach(function (item) {\n param.querys.push(item);\n });\n param.querys = this.uniqueFunc(param.querys, 'property');\n }\n this.$http.post('${yhxt}/assessment/curingAssessment/v1/getJson', param).then(function (resp) {\n var response = resp.data;\n _this6.data = response.rows;\n _this6.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 delpaymentList: function delpaymentList(key) {\n // console.log(key)\n this.paymentList = this.paymentList.filter(function (item) {\n return item.key !== key;\n });\n },\n handleEdit: function handleEdit(data) {\n // console.log(data)\n // let obj = data.curingAssessment\n // this.roadName_ = obj.roadName //暂存数值\n // this.itemName_ = obj.itemName\n this.form = data.curingAssessment;\n // this.form.roadName = {\n // value: obj.roadId,\n // label: obj.roadName,\n // companyIds: obj.companyIds,\n // companyName: obj.companyName\n // }\n // this.form.itemName = {\n // value: obj.itemId,\n // label: obj.itemName,\n // number: obj.itemNomber\n // }\n this.tableData = data.curingAssessmentDetailedList;\n this.title = '【养护考核】';\n this.dialogVisible = true;\n },\n calculation: function calculation(row) {\n console.log(row);\n // this.YStable[row.key].totalPrice=row.quantities*row.unitPrice\n this.itemList.forEach(function (item) {\n if (item.price != null && item.amount != null) {\n item.monty = item.price * item.amount;\n }\n });\n var sum = 0;\n this.itemList.forEach(function (item) {\n if (item.totalPrice) {\n sum += item.totalPrice;\n }\n });\n },\n afterDelete: function afterDelete() {\n // this.$refs.htTable.load()\n },\n showDialog: function showDialog() {\n this.form = {\n startDate: '',\n endDate: ''\n }; //添加的时候将表单置空\n this.tableData.forEach(function (item) {\n item.checkSituation = '';\n item.score = '';\n item.remarks = '';\n });\n // this.tableData = this.checkDetailArr\n this.title = '【养护考核】';\n this.dialogVisible = true;\n },\n handleCloseEnclosure: function handleCloseEnclosure(done) {\n this.enclosureData = [];\n done();\n },\n handleChange: function handleChange(file, fileList) {\n console.log(file, fileList, 'dddd');\n },\n handleCancel: function handleCancel() {\n // this.$refs.htTable.load()\n this.dialogVisible = false;\n },\n changeSatrt: function changeSatrt(val) {\n var _this7 = this;\n this.$nextTick(function () {\n var field = 'startDate'; // 替换为要清除校验的字段名\n var rules = _this7.$refs.ruleForm.rules;\n if (rules && rules[field]) {\n _this7.$refs.ruleForm.clearValidate(field);\n }\n });\n },\n changeEnd: function changeEnd() {\n var _this8 = this;\n this.$nextTick(function () {\n var field = 'endDate'; // 替换为要清除校验的字段名\n var rules = _this8.$refs.ruleForm.rules;\n if (rules && rules[field]) {\n _this8.$refs.ruleForm.clearValidate(field);\n }\n });\n },\n handleSubmit: function handleSubmit() {\n var _this9 = this;\n this.rules.startDate[0].validator = function (rule, value, callback) {\n callback();\n };\n this.rules.endDate[0].validator = function (rule, value, callback) {\n callback();\n };\n //验证表单是否填写完\n this.$refs['ruleForm'].validate(function (valid) {\n if (valid) {\n // this.form.roadName = this.roadName_\n // this.form.itemName = this.itemName_\n _this9.loading = true;\n //请求保存提交\n var data = {\n curingAssessment: _this9.form,\n curingAssessmentDetailedList: _this9.tableData\n };\n console.log(data);\n _this9.$http.post('${yhxt}/assessment/curingAssessment/v1/saveCuringAssessment', data).then(function (res) {\n _this9.loading = false;\n _this9.$message.success(res.data.message);\n if (res.data.state) {\n _this9.dialogVisible = false;\n }\n _this9.$refs.htTable.load(); //重新获取数据\n });\n }\n });\n },\n getCompany: function getCompany() {\n var _this10 = this;\n this.$http.post('${yhxt}/Company/v1/getCompany').then(function (res) {\n res.data.forEach(function (item) {\n _this10.companyOptions.push({\n id: item.id,\n name: item.name\n });\n });\n });\n },\n //深层拷贝回去公司名称\n deepClone: function deepClone(obj) {\n var objClone = Array.isArray(obj) ? [] : {};\n if (obj && _typeof(obj) === 'object') {\n for (var key in obj) {\n if (obj.hasOwnProperty(key)) {\n //判断ojb子元素是否为对象,如果是,递归复制\n if (obj[key] && _typeof(obj[key]) === 'object') {\n objClone[key] = this.deepClone(obj[key]);\n } else {\n if (obj[key] == obj.name) {\n this.companyOptions.push({\n id: obj.id,\n name: obj.name\n });\n } //如果不是,简单复制\n objClone[key] = obj[key];\n }\n }\n }\n }\n },\n handleCommand: function handleCommand(params) {\n var _this11 = this;\n if (params.command == 'processRecord') {\n // console.log(params, 'dddddd')\n var data = {\n pageBean: {\n page: 1,\n pageSize: -1,\n showTotal: false\n },\n params: {\n startDate: params.row.curingAssessment.startDate,\n endDate: params.row.curingAssessment.endDate\n }\n };\n req.downloadPostCopy(window.context.portal + '/assessment/curingAssessment/v1/exportCuringOrder', data).then(function (res) {\n _this11.$message.success('下载成功');\n });\n // this.$http.post(\n // '${yhxt}/assessment/curingAssessment/v1/exportCuringOrder',data\n // ).then()\n } else {\n // this.$message.info('功能建设中...')\n this.$router.push({\n name: 'MainAssessment',\n params: params\n });\n }\n },\n handleRoadNameChange: function handleRoadNameChange(roadId) {\n var data = this.roadData;\n var result = data.filter(function (item) {\n return item.roadId === roadId;\n });\n this.form = _objectSpread(_objectSpread({}, this.form), result[0]);\n this.getCheckDetail();\n // this.lock = false\n // this.form.roadName = data.label\n // this.form.roadId = data.value\n // this.form.companyId = data.companyId\n // this.form.companyName = data.companyName\n },\n handleItemNameChange: function handleItemNameChange(itemId) {\n var data = this.contract;\n var result = data.filter(function (item) {\n return item.itemId === itemId;\n });\n this.form = _objectSpread(_objectSpread({}, this.form), result[0]);\n // this.lock = false\n // this.form.itemName = data.label\n // this.form.itemId = data.value\n // this.form.itemNomber = data.number\n },\n //字典回调\n handleDict: function handleDict(val, obj, str) {\n if (str === 'khjdlx') {\n this.form.assessmentContent = obj.name;\n if (val == 5) {\n this.isShowDate = true;\n } else {\n this.isShowDate = false;\n }\n }\n }\n }\n};",null]}