{"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\\stManager\\components\\ecologForm-dialog.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\stManager\\components\\ecologForm-dialog.vue","mtime":1684458239637},{"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.function.name\";\nimport \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.regexp.split\";\nimport \"core-js/modules/es6.regexp.replace\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 syqStation from '@/api/stManager/syqStation.js';\nimport stStbprpResFroms from \"./components/stStbprpResFrom.vue\"; // import DateMonthDay from './components/dataMoutnDay.vue'\n\nimport dictUtils from '@/components/dict/DictSelectUtils.js';\nimport latitude from '@/mixins/latitude';\nimport req from '@/request.js';\nexport default {\n name: 'syqStationFromdialog',\n components: {\n stStbprpResFroms: stStbprpResFroms // DateMonthDay,\n\n },\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 popList: [],\n stStbprpResFrom: false,\n activeName: 'form',\n fstps: [],\n //汛期类别字典\n orgIds: [],\n //组织下拉\n personIds: [],\n //组织人员下拉\n isHeads: [{\n name: '是',\n value: '1'\n }, {\n name: '否',\n value: '0'\n }],\n //是否负责人\n tableData: [],\n sttps: [],\n //测站类型\n stStbprpRe: {\n stnm: null\n },\n params: {\n // fsrList: [], //汛限水位\n persons: [],\n //责任人\n stStbprpRe: {\n name: ''\n },\n //测站关联对象相关信息\n addvcd: null,\n //水库代码\n admauth: null,\n //水库名称\n appType: null,\n //测站类型\n atcunit: null,\n //行政区\n bgfrym: null,\n //主管部门电话\n bscd: null,\n //建成年月\n bsnm: null,\n //所在流域代码\n comments: null,\n //备注\n drna: null,\n //坝顶高程\n dstrvm: null,\n //设计洪水位\n dtmel: null,\n //水面基准\n dtmnm: null,\n //水库位置坐标_东经\n dtpr: null,\n //防洪库容\n isImportant: '1',\n //重点关注\n isElevation: '0',\n //高程计算\n esstym: null,\n hnnm: null,\n lgtd: null,\n locality: null,\n lttd: null,\n phcd: null,\n rvcd: null,\n rvnm: null,\n stazt: null,\n stbk: null,\n stcd: null,\n stlc: null,\n stnm: null,\n sttp: null,\n sstp: null,\n admaur: null,\n //设备管理人员\n admaurtel: null,\n //设备管理人员电话\n matenur: null,\n //设备维护人员\n matenurtel: null //设备维护人员电话\n\n },\n rsr: [],\n rvcds: [],\n //下拉\n ctcds: [],\n //下拉\n count: 0,\n appTypes: [],\n //设备应用分类\n stbks: [{\n name: '左岸',\n value: '0'\n }, {\n name: '右岸',\n value: '1'\n }],\n //测站岸别\n dtpls: [],\n //水面基准\n listPop: [],\n // multipleSelection: [],\n multipleSelections: [],\n cmdps: [],\n //管理单位数组\n accound: 0,\n basGrads: [],\n //流域级别字典类型\n basAdNames: [],\n //行政下拉\n AdName: null,\n //接受每次选中的值\n bscds: [],\n counts: 0,\n sstpList: [],\n rules: {\n stnm: [{\n required: true,\n message: '请输入测站名称',\n trigger: 'blur'\n }],\n sttp: [{\n required: true,\n message: '请选择测站类型',\n trigger: 'blur'\n }],\n stcd: [{\n required: true,\n message: '请输入测站编码',\n trigger: 'blur'\n }],\n sstp: [{\n required: true,\n message: '请选择生态流量类型',\n trigger: 'blur'\n }],\n addvcd: [{\n required: true,\n message: '请选择所在行政区划',\n trigger: 'blur'\n }]\n }\n };\n },\n created: function created() {\n var _this = this;\n\n this.sstpList = dictUtils.getDictItemsFromCache('czlb-stzlx');\n this.getDetailInfo();\n this.getSysDict();\n this.getTreets();\n syqStation.getList({}, function (res) {\n _this.popList = res.value;\n });\n },\n methods: {\n deadLevs: function deadLevs(val) {\n switch (val) {\n case '1':\n this.params.lgtd = latitude.TreeFour(this.params.lgtd);\n break;\n\n case '3':\n this.params.drna = latitude.SixTwo(this.params.drna);\n break;\n\n default:\n this.params.lttd = latitude.TreeFour(this.params.lttd);\n }\n },\n getClickData: function getClickData(data) {\n //获取子组件传的值\n this.params.stStbprpRe = data;\n },\n openFormDiao: function openFormDiao() {\n // this.title = '新增';\n this.stStbprpResFrom = true;\n },\n closestStbprpResFrom: function closestStbprpResFrom() {\n this.stStbprpResFrom = false;\n },\n rvcdChange: function rvcdChange(val) {\n if (val) {\n this.params.rvcd = val[val.length - 1];\n }\n },\n onhouChange: function onhouChange(val) {\n if (val) {\n this.params.addvcd = val[val.length - 1];\n }\n },\n getTreets: function getTreets() {\n var _this2 = this;\n\n syqStation.getRvcds({}, function (res) {\n _this2.rvcds = res.value; //河流下拉\n });\n syqStation.getCtcds({}, function (res) {\n _this2.bscds = res.value; //流域下拉\n }); // 行政区查询\n\n syqStation.getbasAdName({}, function (res) {\n _this2.basAdNames = res.value;\n }); // 管理树\n\n syqStation.getrgTree({}, function (res) {\n _this2.cmdps = res.value;\n }); //组织树\n\n syqStation.getorgId({}, function (res) {\n _this2.orgIds = res.value;\n });\n },\n changeOrgIds: function changeOrgIds(val) {\n var _this3 = this;\n\n if (val.orgId) {\n val.personId = null;\n val.orgId = val.orgId;\n syqStation.getpersonId({\n val: val\n }, function (res) {\n _this3.personIds = res.value;\n\n _this3.$set(_this3.personIds);\n });\n } else {\n this.personIds = [];\n val.orgId = '';\n this.$set(this.personIds);\n }\n },\n changePid: function changePid(val) {\n if (val.personId) {\n val.personId = val.personId;\n } else {\n val.personId = '';\n }\n },\n handleClick: function handleClick(tab, event) {\n console.log(tab);\n },\n // handleSelectionChange(val) {\n // this.multipleSelection = val.map((item, index) => {\n // return item\n // })\n // },\n handleChanges: function handleChanges(val) {\n this.multipleSelections = val.map(function (item, index) {\n return item;\n });\n },\n //指定一个key标识这一行的数据\n getRowKey: function getRowKey(row) {\n return row.id;\n },\n dmcrels: function dmcrels() {\n this.params.phcd = this.SixTwo(this.params.phcd);\n },\n SixTwo: function SixTwo(value) {\n value = value.replace(/^0*(0\\.|[1-3])/, '$1');\n value = value.replace(/[^\\d.]/g, ''); //清除\"数字\"和\".\"以外的字符\n\n value = value.replace(/^\\./g, ''); //验证第一个字符是数字而不是字符\n\n value = value.replace(/\\.{1,}/g, '.'); //只保留第一个.清除多余的\n\n value = value.replace('.', '$#$').replace(/\\./g, '').replace('$#$', '.');\n value = value.replace(/^(\\-)*(\\d*)\\.(\\d\\d).*$/, '$1$2.$3'); //只能输入两个小数\n\n value = value.indexOf('.') > 0 ? value.split('.')[0].substring(0, 4) + '.' + value.split('.')[1] : value.substring(0, 4);\n return value;\n },\n // addAcount() {\n // const num = this.count++\n // this.params.fsrList.push({\n // ident: num,\n // bgmd: '',\n // edmd: '',\n // fsltdw: '',\n // fsltdz: '',\n // fstp: '', //汛期类别(字典)\n // })\n // },\n // deletAcount() {\n // if (this.multipleSelection.length != 0) {\n // const list = this.arrayRepeat(\n // this.multipleSelection,\n // this.params.fsrList\n // )\n // this.params.fsrList = JSON.parse(JSON.stringify(list))\n // this.$refs.multipleSelection.clearSelection()\n // }\n // },\n addAcounts: function addAcounts() {\n var num = this.counts++;\n this.params.persons.push({\n ident: num,\n personId: '',\n orgId: '',\n isHead: '0'\n });\n },\n arrayRepeat: function arrayRepeat(array1, array2) {\n var result = [];\n\n for (var i = 0; i < array2.length; i++) {\n var obj = array2[i];\n var num = obj.ident;\n var isExist = false;\n\n for (var j = 0; j < array1.length; j++) {\n var aj = array1[j];\n var n = aj.ident;\n\n if (n === num) {\n isExist = true;\n break;\n }\n }\n\n if (!isExist) {\n result.push(obj);\n }\n }\n\n return result;\n },\n deletAcounts: function deletAcounts() {\n if (this.multipleSelections.length != 0) {\n var list = this.arrayRepeat(this.multipleSelections, this.params.persons);\n this.params.persons = JSON.parse(JSON.stringify(list));\n this.$refs.multipleSelections.clearSelection();\n }\n },\n // 根据ID查询\n getDetailInfo: function getDetailInfo() {\n var _this4 = this;\n\n if (this.title === '修改') {\n syqStation.detailId(this.pId, function (res) {\n _this4.params = res.value;\n\n if (res.value.sstp) {\n _this4.params.sstp = String(res.value.sstp);\n }\n\n if (!res.value.stStbprpRe) {\n _this4.params.stStbprpRe = {\n name: ''\n };\n } else {// this.params.stStbprpRe.name = res.value.stStbprpRe.stnm\n }\n\n if (_this4.params.stStbprpRe.reType) {\n syqStation.getList({}, function (res) {\n _this4.popList = res.value;\n\n _this4.popList.forEach(function (e) {\n if (_this4.params.stStbprpRe.reType == e.reType) {\n e.children.forEach(function (s) {\n if (_this4.params.stStbprpRe.reCode == s.reCode) {\n _this4.params.stStbprpRe.name = s.name;\n\n _this4.$set(_this4.params, 'stStbprpR', _this4.params.stStbprpRe);\n }\n });\n }\n });\n });\n } else {\n _this4.params.stStbprpRe.name = '';\n }\n });\n }\n },\n handleClose: function handleClose() {\n this.params = {\n // fsrList: [], //汛限水位\n persons: [],\n //责任人\n stStbprpRe: {},\n //测站关联对象相关信息\n addvcd: null,\n //水库代码\n admauth: null,\n //水库名称\n appType: null,\n //测站类型\n atcunit: null,\n //行政区\n bgfrym: null,\n //主管部门电话\n bscd: null,\n //建成年月\n bsnm: null,\n //所在流域代码\n comments: null,\n //备注\n drna: null,\n //坝顶高程\n dstrvm: null,\n //设计洪水位\n dtmel: null,\n //水面基准\n dtmnm: null,\n //水库位置坐标_东经\n dtpr: null,\n //防洪库容\n esstym: null,\n hnnm: null,\n lgtd: null,\n locality: null,\n lttd: null,\n phcd: null,\n rvcd: null,\n rvnm: null,\n stazt: null,\n stbk: null,\n stcd: null,\n stlc: null,\n stnm: null,\n sttp: null,\n admaur: null,\n //设备管理人员\n admaurtel: null,\n //设备管理人员电话\n matenur: null,\n //设备维护人员\n matenurtel: null //设备维护人员电话\n\n };\n this.$emit('closeFormDiao');\n },\n goInfo: function goInfo(e) {\n var _this5 = this;\n\n this.$refs.formInfo.validate(function (valid) {\n if (valid) {\n if (_this5.title === '新增') {\n var canAdd = true;\n\n if (canAdd) {\n syqStation.addSave(_this5.params, function (response) {\n if (response.state) {\n _this5.$notify({\n type: 'success',\n message: '新增成功',\n duration: 2000 // offset: 80\n\n });\n\n _this5.$emit('closeFormDiao');\n\n _this5.$emit('refList');\n } else {} // this.$emit('closeFormDiao')\n\n });\n }\n }\n\n if (_this5.title === '修改') {\n // this.params.stStbprpRe为空的时候就删除该对象\n if (_this5.params.stStbprpRe === \"\") {\n delete _this5.params.stStbprpRe;\n }\n\n syqStation.upData(_this5.params, function (response) {\n if (response.state) {\n _this5.$notify({\n type: 'success',\n message: '修改成功',\n duration: 2000 // offset: 80\n\n });\n\n _this5.$emit('closeFormDiao');\n\n _this5.$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 _this6 = 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 _this6.fstps = response.data.xqlb;\n _this6.appTypes = response.data.czyyfl;\n _this6.sttps = response.data.czzl;\n\n if (_this6.title == '新增') {\n _this6.params.sttp = _this6.sttps[4].value;\n } // this.prgrs = response.data.gcdb;\n // this.prscs = response.data.gcgm;\n // this.basGrads = response.data.lyjb;\n // this.dtpls = response.data.szjm;\n // this.rsrs = response.data.skgn;\n // this.params.resType=this.resTypes[0].value;\n\n }, function (error) {\n reject(error);\n });\n });\n }\n }\n};",null]}