{"remainingRequest":"D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\damDance-fvue\\src\\views\\BasicData\\components\\NoiseLevelDialog.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\damDance-fvue\\src\\views\\BasicData\\components\\NoiseLevelDialog.vue","mtime":1698314313125},{"path":"D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\damDance-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 utils from '@/utils.js';\nimport NoiseLevel from '@/api/basicConfiguration/NoiseLevel';\nimport NoiseClassify from '@/api/basicConfiguration/NoiseClassify';\nimport dictUtils from '@/components/dict/DictSelectUtils.js';\nexport default {\n props: {},\n name: 'NoiseLevelDialog',\n data: function data() {\n return {\n visible: false,\n loading: false,\n type: '新增',\n rules: {\n noiseTypeId: [{\n required: true,\n message: '请选择噪音分类',\n trigger: 'change'\n }],\n level: [{\n required: true,\n message: '请选择分类级别',\n trigger: 'change'\n }],\n code: [{\n required: true,\n message: '请输入分级编码',\n trigger: 'blur'\n }],\n daytimeNoiseLevel: [{\n required: true,\n message: '请输入白天分贝',\n trigger: 'blur'\n }],\n nightNoiseLevel: [{\n required: true,\n message: '请输入夜晚分贝',\n trigger: 'blur'\n }]\n },\n formData: {},\n sortList: [],\n //分类\n btnLoading: false\n };\n },\n created: function created() {\n this.fljbList = dictUtils.getDictItemsFromCache('fljb');\n this.getSortData();\n },\n methods: {\n getSortData: function getSortData() {\n var _this = this;\n\n NoiseClassify.dataQuery({\n pageBean: {\n page: 1,\n pageSize: -1\n }\n }, function (res) {\n _this.sortList = res.rows;\n });\n },\n open: function open(data) {\n this.formData = {};\n this.visible = true;\n this.type = '新增';\n\n if (this.fljbList.length > 0) {\n this.formData.level = this.fljbList[0].value;\n }\n\n if (this.sortList.length > 0) {\n this.formData.noiseTypeId = this.sortList[0].id;\n }\n },\n handleClose: function handleClose() {\n this.visible = false;\n },\n //编辑\n edit: function edit(id) {\n var _this2 = this;\n\n this.formData = {};\n this.visible = true;\n this.type = '编辑';\n NoiseLevel.detailId(id, function (res) {\n _this2.formData = res;\n });\n },\n //保存\n handleSave: function handleSave() {\n var _this3 = this;\n\n this.$refs.form.validate(function (valid) {\n if (valid) {\n _this3.btnLoading = true;\n var method;\n\n if (_this3.type === '新增') {\n method = NoiseLevel.addSave;\n } else {\n method = NoiseLevel.upData;\n }\n\n method(_this3.formData, function (response) {\n if (response.state) {\n _this3.$notify({\n type: 'success',\n message: _this3.type + '成功',\n duration: 2000\n });\n\n _this3.handleClose();\n\n _this3.$emit('getData');\n } else {\n _this3.$message.warning(response.message);\n }\n\n _this3.btnLoading = false;\n });\n } else {\n _this3.$notify({\n type: 'warning',\n message: '请完善表单信息!',\n duration: 2000\n });\n }\n });\n }\n }\n};",null]}