{"remainingRequest":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\infoManagement\\components\\form-dialog.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\infoManagement\\components\\form-dialog.vue","mtime":1684458239152},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/es6.regexp.to-string\";\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//\nimport basin from '@/api/basin.js';\nimport req from '@/request.js';\nimport latitude from '@/mixins/latitude';\nexport default {\n name: 'FormDialog',\n props: {\n showFormDia: {\n type: Boolean,\n default: false\n },\n title: {\n type: String,\n default: ''\n },\n pId: {\n type: String,\n default: ''\n }\n },\n data: function data() {\n return {\n params: {\n basName: null,\n //流域名称\n basGrad: null,\n //流域级别\n crOverType: null,\n //跨界类型\n lowLeftLong: null,\n //左下角经度\n lowLeftLat: null,\n //左下角维度\n note: null,\n //备注\n basCode: null,\n //流域代码\n basAdCode: null,\n //流域所属行政区\n upRightLong: null,\n upRightLat: null,\n basArea: null,\n //流域面积\n basAdName: ''\n },\n crOverTypes: [],\n //跨界类型字典数组\n basGrads: [],\n //流域级别字典类型\n basAdNames: [],\n //行政下拉\n AdName: null,\n //接受每次选中的值\n setKesLabel: {\n value: 'code',\n label: 'name',\n children: 'children'\n },\n rules: {\n basName: [{\n required: true,\n message: '请输入流域名称',\n trigger: 'blur'\n }],\n basCode: [{\n required: true,\n message: '请输入流域代码',\n trigger: 'blur'\n }]\n }\n };\n },\n created: function created() {\n var _this = this;\n\n this.getDetailInfo();\n this.getSysDict(); // 行政区查询\n\n basin.getbasAdName({}, function (res) {\n _this.basAdNames = res.value;\n });\n },\n methods: {\n deadLevs: function deadLevs(val) {\n switch (val) {\n case '1':\n this.params.lowLeftLat = latitude.TreeFour(this.params.lowLeftLat);\n break;\n\n case '2':\n this.params.lowLeftLong = latitude.TreeFour(this.params.lowLeftLong);\n break;\n\n case '3':\n this.params.upRightLat = latitude.TreeFour(this.params.upRightLat);\n break;\n\n case '4':\n this.params.upRightLong = latitude.TreeFour(this.params.upRightLong);\n break;\n\n default:\n this.params.basArea = latitude.ElghtTwo(this.params.basArea);\n }\n },\n // 根据ID查询\n getDetailInfo: function getDetailInfo() {\n var _this2 = this;\n\n if (this.title === '修改') {\n basin.getbasAdName({}, function (res) {\n _this2.basAdNames = res.value;\n });\n this.getSysDict();\n this.$set(this.crOverTypes, this.crOverTypes);\n this.$set(this.basAdNames, this.basAdNames);\n this.$set(this.basGrads, this.basGrads);\n basin.detailId(this.pId, function (res) {\n _this2.params = res;\n _this2.params.basAdCode = _this2.params.basAdCode.split(',');\n\n _this2.$set(_this2.params);\n });\n }\n },\n onhouChange: function onhouChange(val) {\n this.AdName = val;\n this.params.basAdCode = val.toString();\n var arr = this.basAdNames.filter(function (ite) {\n return ite.code === val[0];\n });\n this.calleArr(arr, val[val.length - 1]);\n },\n calleArr: function calleArr(array, val) {\n for (var i in array) {\n var item = array[i];\n\n if (item.children) {\n this.calleArr(item.children, val); //自己调用自己\n } else {\n if (item.code === val) {\n this.params.basAdName = item.fullName;\n }\n }\n }\n },\n handleClose: function handleClose() {\n this.params = {\n basName: null,\n //流域名称\n basGrad: null,\n //流域级别\n crOverType: null,\n //跨界类型\n lowLeftLong: null,\n //左下角经度\n lowLeftLat: null,\n //左下角维度\n note: null,\n //备注\n basCode: null,\n //流域代码\n basAdCode: null,\n //流域所属行政区\n upRightLong: null,\n upRightLat: null\n };\n this.$emit('closeFormDiao');\n },\n goInfo: function goInfo(e) {\n var _this3 = this;\n\n this.$refs.formInfo.validate(function (valid) {\n if (valid) {\n if (_this3.title === '新增') {\n basin.addSave(_this3.params, function (response) {\n if (response.state) {\n _this3.$notify({\n type: 'success',\n message: '新增成功',\n duration: 2000 // offset: 80\n\n });\n\n _this3.$emit('closeFormDiao');\n\n _this3.$emit('refList');\n } else {}\n });\n }\n\n if (_this3.title === '修改') {\n var params = JSON.parse(JSON.stringify(_this3.params));\n params.basAdCode = params.basAdCode.toString();\n basin.upData(params, function (response) {\n if (response.state) {\n _this3.$notify({\n type: 'success',\n message: '修改成功',\n duration: 2000 // offset: 80\n\n });\n\n _this3.$emit('closeFormDiao');\n\n _this3.$emit('refList'); // this.$message.success(response.message)\n\n } else {// this.$message.success(response.message)\n } // this.$emit('closeFormDiao')\n // this.$router.go(-1)\n\n });\n }\n } else {\n return false;\n }\n });\n },\n //获取字典数据\n getSysDict: function getSysDict() {\n var _this4 = this;\n\n var portal = window.context.portal;\n return new Promise(function (resolve, reject) {\n req.post(portal + '/sys/sysDictionary/v1/queryAllDictItems').then(function (response) {\n resolve(response.data);\n _this4.crOverTypes = response.data.kjlx;\n _this4.basGrads = response.data.lyjb;\n\n _this4.$set(_this4.crOverTypes, _this4.crOverTypes);\n\n _this4.$set(_this4.basGrads, _this4.basGrads);\n }, function (error) {\n reject(error);\n });\n });\n },\n changebasAdName: function changebasAdName(val) {\n if (val) {\n this.params.basAdCode = val.toString();\n } else {\n this.params.basAdCode = null;\n }\n },\n changeArea: function changeArea(val) {\n if (val) {\n this.params.basArea = val;\n } else {\n this.params.basArea = null;\n }\n },\n changecrOverType: function changecrOverType(val) {\n if (val) {\n this.params.crOverType = val;\n } else {\n this.params.crOverType = null;\n }\n },\n changebasGrad: function changebasGrad(val) {\n if (val) {\n this.params.basGrad = val;\n } else {\n this.params.basGrad = null;\n }\n }\n }\n};",null]}