{"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\\frontScreens\\DigitalStructure.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\frontScreens\\DigitalStructure.vue","mtime":1684458238481},{"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 _toConsumableArray from \"D:/jenkins/workspace/bbsl-fvue/node_modules/@babel/runtime/helpers/esm/toConsumableArray\";\nimport \"core-js/modules/es6.regexp.split\";\nimport \"core-js/modules/es6.regexp.replace\";\nimport \"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//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n// import videoPlayer from './components/videoPlayer.vue'\nimport videoPlayPlugin from \"./components/videoPlayPlugin.vue\";\nimport VueSeamlessScroll from 'vue-seamless-scroll';\nimport * as echarts from 'echarts';\nimport stationsModel from \"./components/stationsModel.vue\";\nimport historyModel from \"./components/historyModel.vue\";\nimport SafeModel from \"./components/SafeModel.vue\";\nimport DSModel from \"./components/DSModel.vue\";\nimport PDFModel from \"./components/PDFModel.vue\";\nimport digitalReservoir from '@/api/frontScreen/digitalReservoir.js';\nimport dictUtils from '@/components/dict/DictSelectUtils.js';\nexport default {\n name: 'digitalReservoir',\n components: {\n videoPlayPlugin: videoPlayPlugin,\n VueSeamlessScroll: VueSeamlessScroll,\n stationsModel: stationsModel,\n historyModel: historyModel,\n SafeModel: SafeModel,\n PDFModel: PDFModel,\n DSModel: DSModel\n },\n computed: {\n optionSingleHeightTime: function optionSingleHeightTime() {\n return {\n singleHeight: 29,\n waitTime: 2500\n };\n }\n },\n data: function data() {\n return {\n showWord: false,\n word: '',\n title_style: {\n color: ''\n },\n firstShow: false,\n options: {\n layout: '1x1',\n showToolbar: 1,\n simpleTips: true,\n mountedInit: true\n },\n list: null,\n //上级传参\n message: '',\n // 要发送的消息\n title: '',\n capacity: 86.49,\n storage: 71.28,\n params: {\n rscd: '',\n time: '',\n waterId: '',\n year: 0\n },\n //水库概况\n monitoringList1: [],\n //测站下拉列表\n monitoringList2: [],\n //测站下拉列表\n monitoringList3: [],\n //测站下拉列表\n generalSituation: '',\n dammvLists: [],\n //位移曲线数据\n damspprLists: [],\n //渗压曲线数据\n damspgLists: [],\n //渗流曲线数据\n rsvrLatestLists: [],\n //水情监测\n pptnLatestLists: [],\n //雨情监测\n rsvrAndPptnValues: {},\n //当日水位雨情情况\n // 安全责任人\n responsible1: [],\n // 防汛责任人\n responsible2: [],\n safeMaintain: [{\n name: '安全鉴定',\n num: 3,\n key: 1\n }, {\n name: '除险加固',\n num: 65,\n key: 2\n }, {\n name: '保养维护',\n num: 65,\n key: 3\n }],\n siteOption: [// {\n // \tname: '视频监测点A',\n // \tcode: '1234567891',\n // },\n // {\n // \tname: '视频监测点B',\n // \tcode: '1234567892',\n // },\n // {\n // \tname: '视频监测点C',\n // \tcode: '1234567893',\n // },\n // {\n // \tname: '视频监测点D',\n // \tcode: '1234567894',\n // },\n // {\n // \tname: '视频监测点E',\n // \tcode: '1234567895',\n // },\n ],\n rainAlarm: [{\n name: '水位报警',\n count: 0,\n list: []\n }, {\n name: '雨量报警',\n count: 0,\n list: []\n }, {\n name: '工情报警',\n count: 0,\n list: []\n }],\n stationData: [{\n sttp: '雨量站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-yuliang'\n }, {\n sttp: '水库水位站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shuiwen'\n }, {\n sttp: '生态流量站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shenliu'\n }, {\n sttp: '渗压点',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shenya'\n }, {\n sttp: '位移点',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-weiyi'\n }, {\n sttp: '视频站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shipin'\n }],\n inspectionHeader: [{\n key: 'order',\n width: '14px',\n name: ''\n }, {\n key: 'structure',\n width: '23%',\n name: '巡检部位'\n }, {\n key: 'isNormal',\n width: '15%',\n name: '是否正常'\n }, {\n key: 'createTime',\n width: 'calc(33% - 14px)',\n name: '时间'\n }, {\n key: 'conclusion',\n width: '20%',\n name: '处理结论'\n } // {\n // key: 'isNormal',\n // width: '10%',\n // name: '状态',\n // },\n ],\n inspectionData: [],\n rainChart: null,\n //雨情监测\n waterChart: null,\n //水情监测\n seepageChart: null,\n //渗流监测\n pressureChart: null,\n //渗压监测\n shiftChart: null,\n //位移监测\n stationKey1: '',\n options1: [],\n stationKey2: '',\n stationKey3: '',\n options3: [],\n reservoirList: [],\n //水库下拉列表\n currentSite: ''\n };\n },\n created: function created() {\n if (window.localStorage.getItem('rscd')) {\n this.params.rscd = window.localStorage.getItem('rscd');\n this.title = window.localStorage.getItem('title');\n } else {\n this.params.rscd = this.$route.query.rscd;\n this.title = this.$route.query.rsnm;\n } // if (window.performance.navigation.type === 1) {\n // console.log('页面被刷新')\n // } else {\n // console.log('页面首次被加载')\n // this.params.rscd = this.$route.query.rscd\n // }\n\n\n this.getFindAll();\n this.getRsvrAndPptnValue(); //当日水位雨情情况\n\n this.getResDetail(); //水库详情\n\n this.getWarnInfo(); //根据水库编码获取预警信息\n\n this.getStationSituation(); //测站概况\n\n this.getPersonList(); //责任人列表\n\n this.getLatestIns(); //最新巡检\n\n this.getRsvrLatestList(); //水情监测\n\n this.getPptnLatestList(); //雨情监测\n\n this.getMonitoring(); //测站下拉列表\n\n this.getVideoList();\n },\n mounted: function mounted() {\n var _this = this;\n\n window.addEventListener('popstate', this.removeCache, false);\n this.initCharts();\n this.$root.$on('resize', function () {\n _this.resize(500);\n }); // this.title = this.list.rsnm\n },\n methods: {\n /**\r\n * 详情点击事件\r\n * */\n // 位移\n searchDisplacement: function searchDisplacement() {\n console.log(this.params.rscd, '位移');\n var sqID = this.params.rscd;\n window.sessionStorage.setItem('StationId', sqID);\n var routeData = this.$router.resolve({\n path: '/bizPlat/monitor/gqMonitor/wyQuery'\n });\n window.open(routeData.href, '_blank');\n },\n // 水情\n searchRsvrLatest: function searchRsvrLatest() {\n console.log('水情');\n var sqID = this.params.rscd;\n window.sessionStorage.setItem('StationId', sqID);\n var routeData = this.$router.resolve({\n path: '/bizPlat/monitor/sqMonitor/resWaterLatest'\n });\n window.open(routeData.href, '_blank');\n },\n // 雨情\n searchRain: function searchRain() {\n console.log('雨情');\n var rainStcd = '';\n this.pptnLatestLists.forEach(function (res) {\n rainStcd = res.stcd;\n });\n console.log(rainStcd);\n window.sessionStorage.setItem('StationId', rainStcd);\n var routeData = this.$router.resolve({\n path: '/bizPlat/monitor/resMonitor/ylStQuery'\n });\n window.open(routeData.href, '_blank');\n },\n // 测压管\n searchManometry: function searchManometry() {\n console.log('测压管');\n var sqID = this.params.rscd;\n window.sessionStorage.setItem('rscdId', sqID);\n var routeData = this.$router.resolve({\n path: '/bizPlat/monitor/gqMonitor/sygQuery'\n });\n window.open(routeData.href, '_blank');\n },\n // 安全、除险、维护弹窗\n openList: function openList(value, id) {\n var _this2 = this;\n\n this.$nextTick(function () {\n var sqID = id;\n window.sessionStorage.setItem('rscdId', sqID);\n\n _this2.$refs.SafeModel.open(value, id);\n });\n },\n // 设置水位数据颜色\n setCorlor: function setCorlor() {\n if (this.rsvrAndPptnValues.rz < this.generalSituation.w) {\n this.title_style.color = 'rgb(6, 194, 6) !important';\n }\n\n if (this.rsvrAndPptnValues.rz >= this.generalSituation.w) {\n this.title_style.color = 'yellow !important';\n }\n\n if (this.rsvrAndPptnValues.rz >= this.generalSituation.dsfllv) {\n this.title_style.color = 'orange !important';\n }\n\n if (this.rsvrAndPptnValues.rz >= this.generalSituation.chfllv) {\n this.title_style.color = 'red !important';\n }\n },\n handleCommand: function handleCommand(command) {\n this.word = '';\n this.showWord = false;\n this.title = command.rsnm;\n this.params.rscd = command.rscd;\n window.localStorage.setItem('rscd', command.rscd);\n window.localStorage.setItem('title', command.rsnm);\n this.getResDetail(); //水库详情\n\n this.getWarnInfo(); //根据水库编码获取预警信息\n\n this.getStationSituation(); //测站概况\n\n this.getPersonList(); //责任人列表\n\n this.getLatestIns(); //最新巡检\n\n this.getRsvrLatestList(); //水情监测\n\n this.getPptnLatestList(); //雨情监测\n\n this.getMonitoring(); //测站下拉列表\n\n this.getRsvrAndPptnValue(); //当日水位雨情情况\n\n this.getVideoList();\n this.setCorlor();\n },\n //打开报警弹框\n handlePopup: function handlePopup(title, type, data, logo) {\n var _this3 = this;\n\n this.$nextTick(function () {\n _this3.$refs.DSModel.open(title, type, data, logo);\n });\n },\n //获取水库下拉列表\n getFindAll: function getFindAll() {\n var _this4 = this;\n\n digitalReservoir.findAll({}, function (res) {\n if (res.state) {\n _this4.reservoirList = res.value;\n }\n });\n },\n cutWindowSelect: function cutWindowSelect(size) {\n var _this5 = this;\n\n this.$nextTick(function () {\n var widthV = _this5.$refs.videoIframe.$el.clientWidth;\n var heightV = _this5.$refs.videoIframe.$el.clientHeight;\n var iLeft,\n iTop = 0,\n iWidth,\n iHeight;\n iLeft = widthV - size.width;\n iWidth = size.width + 2;\n iHeight = size.height >= heightV ? heightV : size.height + 1;\n\n _this5.$refs.videoIframe.cutWindow(iLeft, iTop, iWidth, iHeight + 12);\n });\n },\n visibleChange: function visibleChange(flag) {\n var _this6 = this;\n\n this.$nextTick(function () {\n if (flag) {\n setTimeout(function () {\n var size = _this6.$refs.select.$el.children[1].getBoundingClientRect();\n\n _this6.cutWindowSelect(size);\n }, 500);\n } else {\n _this6.$refs.videoIframe.repairWindow();\n }\n });\n },\n // 根据监控点获取视频流地址\n getSiteVideoURL: function getSiteVideoURL(cameraIndexCode) {\n var _this7 = this;\n\n var query = {\n cameraIndexCode: cameraIndexCode // 监控点编码\n\n };\n this.$http.post('${portal}/biz/catalog/base/previewURLs', query).then(function (res) {\n if (res.data.state && res.data.value) {\n var data = res.data.value;\n\n _this7.$nextTick(function () {\n _this7.$refs.videoIframe.useVideoURL(data);\n });\n } else {\n _this7.$message.warning('获取监控点资源失败!');\n }\n });\n },\n ready: function ready() {\n this.$refs.videoIframe.play(this.currentSite);\n },\n //关联监控点列表\n getVideoList: function getVideoList() {\n var _this8 = this;\n\n this.siteOption = this.$options.data().siteOption;\n this.currentSite = this.$options.data().currentSite;\n var param = {\n insStatus: 0,\n rscd: this.params.rscd,\n time: '',\n waterId: '',\n year: 0\n };\n digitalReservoir.videoList(param, function (res) {\n if (res.state) {\n _this8.siteOption = res.value;\n\n if (_this8.siteOption.length) {\n _this8.currentSite = _this8.siteOption[0].code;\n\n if (_this8.currentSite) {\n _this8.$refs.videoIframe.play(_this8.currentSite); // this.getSiteVideoURL(this.currentSite)\n\n }\n } else {\n _this8.$refs.videoIframe.play(' ');\n }\n }\n });\n },\n // 切换监控点\n changeSite: function changeSite(val) {\n this.currentSite = val;\n this.$refs.videoIframe.play(this.currentSite);\n },\n //水库详情\n getResDetail: function getResDetail() {\n var _this9 = this;\n\n var param = {\n appTypeList: [],\n endTime: '',\n id: '',\n mpcd: '',\n periodTime: '',\n rscd: this.params.rscd,\n startTime: '',\n stcd: '',\n stlc: '',\n stnm: '',\n sttp: '',\n sttpList: [],\n usfl: ''\n };\n this.generalSituation = this.$options.data().generalSituation;\n this.rsvrAndPptnValues = this.$options.data().rsvrAndPptnValues;\n digitalReservoir.resDetail(this.params, function (res) {\n if (res.state) {\n _this9.generalSituation = res.value; // 数据对比使用\n\n digitalReservoir.rsvrAndPptnValue(param, function (res) {\n if (res.state) {\n _this9.rsvrAndPptnValues = res.value;\n\n if (_this9.rsvrAndPptnValues.rstpc == -1) {\n _this9.rsvrAndPptnValues.rstpc = 0;\n }\n\n if (_this9.rsvrAndPptnValues.rstpc > 0 && _this9.rsvrAndPptnValues.isMatched == 'f') {\n _this9.word = '约';\n _this9.showWord = true;\n }\n\n _this9.setCorlor();\n }\n });\n }\n });\n },\n //根据水库编码获取预警信息\n getWarnInfo: function getWarnInfo() {\n var _this10 = this;\n\n this.rainAlarm = this.$options.data().rainAlarm;\n digitalReservoir.getWarnInfo(this.params.rscd, function (res) {\n if (res.state) {\n res.value.forEach(function (e, ex) {\n _this10.rainAlarm[ex].count = e.count;\n _this10.rainAlarm[ex].list = e.list;\n });\n } else {}\n });\n },\n //当日水位雨情情况\n getRsvrAndPptnValue: function getRsvrAndPptnValue() {\n var _this11 = this;\n\n this.rsvrAndPptnValues = this.$options.data().rsvrAndPptnValues;\n var param = {\n appTypeList: [],\n endTime: '',\n id: '',\n mpcd: '',\n periodTime: '',\n rscd: this.params.rscd,\n startTime: '',\n stcd: '',\n stlc: '',\n stnm: '',\n sttp: '',\n sttpList: [],\n usfl: ''\n };\n digitalReservoir.rsvrAndPptnValue(param, function (res) {\n if (res.state) {\n _this11.rsvrAndPptnValues = res.value;\n }\n });\n },\n //测站概况\n getStationSituation: function getStationSituation() {\n var _this12 = this;\n\n this.stationData = [{\n sttp: '雨量站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-yuliang'\n }, {\n sttp: '水库水位站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shuiwen'\n }, {\n sttp: '生态流量站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shenliu'\n }, {\n sttp: '渗压点',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shenya'\n }, {\n sttp: '位移点',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-weiyi'\n }, {\n sttp: '视频站',\n count: 0,\n normalCount: 0,\n faultCount: 0,\n icon: 'bbsl-shipin'\n }];\n digitalReservoir.stationSituation(this.params, function (res) {\n if (res.state) {\n console.log(res);\n res.value.forEach(function (e) {\n _this12.stationData.forEach(function (s) {\n if (e.sttp == s.sttp) {\n s.count = e.count;\n s.normalCount = e.normalCount;\n s.faultCount = e.faultCount;\n }\n });\n });\n }\n });\n },\n //责任人列表\n getPersonList: function getPersonList() {\n var _this13 = this;\n\n this.responsible1 = this.$options.data().responsible1;\n this.responsible2 = this.$options.data().responsible2;\n digitalReservoir.personList(this.params.rscd, function (res) {\n if (res.state && res.value) {\n for (var i in res.value) {\n if (i <= 3) {\n _this13.responsible2.push(res.value[i][0]);\n } else if (i > 3) {\n _this13.responsible1.push(res.value[i][0]);\n }\n }\n }\n });\n },\n //最新巡检\n getLatestIns: function getLatestIns() {\n var _this14 = this;\n\n this.inspectionData = [];\n var id = this.params.rscd;\n digitalReservoir.latestIns(id, function (res) {\n if (res.state) {\n _this14.inspectionData = res.value;\n\n _this14.inspectionData.forEach(function (e) {\n if (!e.createTime) {\n e.createTime = '';\n } else {\n e.createTime = e.createTime.replace('-', '/').split('/')[1].slice(0, 11).replace('-', '/');\n }\n });\n }\n });\n },\n //水情监测\n getRsvrLatestList: function getRsvrLatestList() {\n var _this15 = this;\n\n this.rsvrLatestLists = [];\n var param = {\n // rscd: this.params.rscd\n appTypeList: [],\n endTime: '',\n id: '',\n mpcd: '',\n periodTime: '',\n rscd: this.params.rscd,\n startTime: '',\n stcd: '',\n stlc: '',\n stnm: '',\n sttp: '',\n sttpList: [],\n usfl: ''\n };\n digitalReservoir.rsvrLatestList(param, function (res) {\n if (res.state) {\n _this15.rsvrLatestLists = res.value;\n\n _this15.$nextTick(function () {\n _this15.initWaterChart();\n });\n }\n });\n },\n //雨情监测\n getPptnLatestList: function getPptnLatestList() {\n var _this16 = this;\n\n this.pptnLatestLists = [];\n var param = {\n // rscd: this.params.rscd\n appTypeList: [],\n endTime: '',\n id: '',\n mpcd: '',\n periodTime: '',\n rscd: this.params.rscd,\n startTime: '',\n stcd: '',\n stlc: '',\n stnm: '',\n sttp: '',\n sttpList: [],\n usfl: '',\n tmOrderAsc: true\n };\n digitalReservoir.pptnLatestList(param, function (res) {\n if (res.state) {\n _this16.pptnLatestLists = res.value;\n\n _this16.$nextTick(function () {\n _this16.initRainChart();\n });\n }\n });\n },\n //获取监测站下拉\n getMonitoring: function getMonitoring() {\n this.dropDownList(1);\n this.dropDownList(2);\n this.dropDownList(3);\n },\n dropDownList: function dropDownList(val) {\n var _this17 = this;\n\n // console.log(val);\n this.monitoringList1 = this.$options.data().monitoringList1;\n this.monitoringList2 = this.$options.data().monitoringList2;\n this.monitoringList3 = this.$options.data().monitoringList3;\n this.stationKey1 = this.$options.data().stationKey1;\n this.stationKey2 = this.$options.data().stationKey2;\n this.stationKey3 = this.$options.data().stationKey3;\n var param = {\n id: '',\n mpcd: '',\n mpnm: '',\n rscd: this.params.rscd,\n stlc: '',\n sttp: val,\n wkcn: ''\n };\n digitalReservoir.monitoring(param, function (res) {\n // console.log(res);\n if (res.state) {\n // this.monitoringList = res.value\n if (val == 1) {\n _this17.monitoringList1 = res.value;\n\n if (_this17.monitoringList1.length > 0) {\n _this17.stationKey1 = _this17.monitoringList1[0].mpcd;\n }\n\n _this17.getDammvList(); //位移曲线\n\n } else if (val == 2) {\n _this17.monitoringList3 = res.value;\n\n if (_this17.monitoringList3.length > 0) {\n _this17.stationKey3 = _this17.monitoringList3[0].mpcd;\n }\n\n _this17.getDamspgList(); //渗流曲线\n\n } else if (val == 3) {\n _this17.monitoringList2 = res.value;\n\n if (_this17.monitoringList2.length > 0) {\n _this17.stationKey2 = _this17.monitoringList2[0].mpcd;\n }\n\n _this17.getDamspprList(); //渗压曲线\n\n }\n }\n });\n },\n //位移曲线图\n getDammvList: function getDammvList() {\n var _this18 = this;\n\n this.dammvLists = [];\n var param = {\n appTypeList: [],\n endTime: '',\n id: '',\n mpcd: '',\n periodTime: '',\n rscd: this.params.rscd,\n startTime: '',\n stcd: this.stationKey1,\n stlc: '',\n stnm: '',\n sttp: '',\n sttpList: [],\n usfl: '',\n tmOrderAsc: true\n };\n digitalReservoir.dammvList(param, function (res) {\n if (res.state) {\n _this18.dammvLists = res.value;\n\n _this18.$nextTick(function () {\n _this18.initShiftChart();\n });\n }\n });\n },\n //渗压监测\n getDamspprList: function getDamspprList() {\n var _this19 = this;\n\n var param = {\n startTime: '',\n endTime: '',\n mptp: '4',\n rscd: this.params.rscd,\n mpcd: this.stationKey2,\n tmOrderAsc: true\n };\n digitalReservoir.getDamspprList(param, function (res) {\n if (res.state) {\n _this19.damspprLists = res.value; // console.log(res.value);\n\n _this19.$nextTick(function () {\n _this19.initPressureChart();\n });\n }\n });\n },\n //渗流曲线图\n getDamspgList: function getDamspgList() {\n var _this20 = this;\n\n var param = {\n pageBean: {\n page: 1,\n pageSize: -1,\n showTotal: true\n },\n params: {\n rscd: this.params.rscd\n }\n };\n digitalReservoir.lvtpcQuery(param, function (res) {\n if (res.state) {\n _this20.damspgLists = res.value.rows;\n\n _this20.$nextTick(function () {\n _this20.initSeepageChart();\n });\n }\n });\n },\n openHistory: function openHistory() {\n //this.title, 1 // title 和 水库id\n this.$refs.historyModel.open(this.title, this.params.rscd);\n this.$refs.PDFModel.close();\n this.$refs.stationsModel.close();\n this.cutwindow('historyModel');\n },\n calculationWindow: function calculationWindow(size) {\n var iLeft, iTop, iWidth, iHeight;\n iLeft = size.left - size.leftV;\n iTop = size.top - size.topV;\n iWidth = size.leftV + size.widthV - size.left;\n iHeight = size.topV + size.heightV - size.top;\n return [iLeft, iTop, iWidth + 1, iHeight + 1];\n },\n cutwindow: function cutwindow(openWindow) {\n var _this21 = this;\n\n this.$nextTick(function () {\n var _this21$$refs$videoIf;\n\n var top = _this21.$refs[openWindow].$el.getBoundingClientRect().top;\n\n var left = _this21.$refs[openWindow].$el.getBoundingClientRect().left;\n\n var topV = _this21.$refs.videoIframe.$el.getBoundingClientRect().top;\n\n var leftV = _this21.$refs.videoIframe.$el.getBoundingClientRect().left;\n\n var widthV = _this21.$refs.videoIframe.$el.clientWidth;\n var heightV = _this21.$refs.videoIframe.$el.clientHeight;\n var windowSize = {\n top: top,\n left: left,\n topV: topV,\n leftV: leftV,\n widthV: widthV,\n heightV: heightV\n };\n\n var cutSize = _this21.calculationWindow(windowSize);\n\n (_this21$$refs$videoIf = _this21.$refs.videoIframe).cutWindow.apply(_this21$$refs$videoIf, _toConsumableArray(cutSize));\n });\n },\n openPDF: function openPDF(val, path) {\n //this.title, 1 // title 和 水库id\n this.$refs.PDFModel.open(val, this.title, this.params.rscd, path);\n this.$refs.historyModel.close();\n this.$refs.stationsModel.close();\n this.cutwindow('PDFModel');\n },\n handleStation: function handleStation(title, type, data) {\n var czlbList = dictUtils.getDictItemsFromCache('tj-czlb');\n czlbList.forEach(function (e) {\n if (e.name == title) {\n data.sttp = e.value;\n }\n });\n this.$refs.stationsModel.open(title, type, data, this.params.rscd);\n this.$refs.historyModel.close();\n this.$refs.PDFModel.close();\n this.cutwindow('stationsModel');\n },\n closeModel: function closeModel() {\n var _this22 = this;\n\n this.$nextTick(function () {\n _this22.$refs.videoIframe.repairWindow();\n });\n },\n removeCache: function removeCache() {\n window.localStorage.removeItem('rscd');\n window.localStorage.removeItem('title');\n },\n goBack: function goBack() {\n window.localStorage.removeItem('rscd');\n window.localStorage.removeItem('title');\n this.$router.push('/frontPlat/digitalReservoir/');\n },\n resize: function resize(delay) {\n var _this23 = this;\n\n // 动态计算表格的高度,自适应当前容器\n setTimeout(function () {\n _this23.rainChart.resize();\n\n _this23.waterChart.resize();\n\n _this23.seepageChart.resize();\n\n _this23.pressureChart.resize();\n\n _this23.shiftChart.resize();\n }, delay || 0);\n },\n initCharts: function initCharts() {\n this.$nextTick(function () {// this.initRainChart()\n // this.initWaterChart()\n // this.initSeepageChart()\n // this.initPressureChart()\n });\n },\n //下拉框选择\n // chengeMonitoring(){\n // \tconsole.log(this.stationKey1);\n // \tthis.getDammvList()\n // },\n initRainChart: function initRainChart() {\n // pptnLatestLists\n var times = [];\n var drpList = [];\n this.pptnLatestLists.forEach(function (e) {\n times.push(e.tm.split(' ')[1]);\n drpList.push(e.drp);\n });\n var rainChartDom = document.getElementById('rainChart');\n this.rainChart = echarts.init(rainChartDom);\n var option = {\n tooltip: {\n trigger: 'axis',\n backgroundColor: 'rgba(0,0,0,0.7)',\n textStyle: {\n color: '#dddee0'\n },\n axisPointer: {\n type: 'cross',\n label: {\n backgroundColor: '#6a7985'\n }\n }\n },\n legend: {\n top: '2%',\n left: '4%',\n data: ['小时雨量(mm)'],\n textStyle: {\n color: '#adb9ba',\n fontSize: 10\n }\n },\n grid: {\n top: '20%',\n left: '4%',\n right: '4%',\n bottom: '6%',\n containLabel: true\n },\n xAxis: [{\n type: 'category',\n boundaryGap: false,\n data: times\n }],\n yAxis: [{\n type: 'value',\n scale: true\n }],\n series: [{\n name: '小时雨量(mm)',\n type: 'line',\n smooth: true,\n areaStyle: {},\n emphasis: {\n focus: 'series'\n },\n data: drpList,\n itemStyle: {\n color: '#6767ff'\n }\n }]\n };\n option && this.rainChart.setOption(option);\n },\n initWaterChart: function initWaterChart() {\n // rsvrLatestLists\n var times = [];\n var rzList = [];\n var wList = [];\n this.rsvrLatestLists.forEach(function (e) {\n times.push(e.tm.split(' ')[1]);\n rzList.push(e.rz);\n wList.push(e.w);\n }); // let yMin = (Math.min(...rzList) + 1.5).toFixed(2)\n // let yMax = (Math.max(...rzList) - 1.5).toFixed(2)\n\n var waterChartDom = document.getElementById('waterChart');\n this.waterChart = echarts.init(waterChartDom);\n var option = {\n tooltip: {\n trigger: 'axis',\n backgroundColor: 'rgba(0,0,0,0.7)',\n textStyle: {\n color: '#dddee0'\n },\n axisPointer: {\n type: 'cross',\n label: {\n backgroundColor: '#6a7985'\n }\n },\n formatter: function formatter(params) {\n // params的个数等于折线的条数(对多条折线数据进行加单位,就需要遍历)\n var moment = require('moment'); //打开时默认时间为一天前至获取当前年月日时分秒\n\n\n var _today = moment();\n\n var endTime = moment().format('YYYY-MM-DD'); //当前年月日\n\n var relVal = endTime + ' ' + params[0].name;\n\n for (var i = 0, l = params.length; i < l; i++) {\n // circle变量是在数据前画一个对应颜色的圆形\n var circle = \"o\");\n relVal += '
' + circle + params[i].seriesName + ' : ' + params[i].value;\n }\n\n return relVal;\n }\n },\n legend: {\n top: '2%',\n left: '4%',\n data: ['当前水位(m)'],\n textStyle: {\n color: '#adb9ba',\n fontSize: 10\n }\n },\n grid: {\n top: '20%',\n left: '4%',\n right: '4%',\n bottom: '6%',\n containLabel: true\n },\n xAxis: [{\n type: 'category',\n boundaryGap: false,\n data: times\n }],\n yAxis: [{\n type: 'value',\n max: Math.ceil(Math.max.apply(Math, rzList)),\n min: Math.floor(Math.min.apply(Math, rzList)),\n interval: 0.5 //每次增加几个\n\n }],\n series: [{\n name: '当前水位(m)',\n type: 'line',\n smooth: true,\n areaStyle: {},\n emphasis: {\n focus: 'series'\n },\n data: rzList,\n itemStyle: {\n color: '#6767ff'\n }\n }]\n };\n option && this.waterChart.setOption(option);\n },\n initSeepageChart: function initSeepageChart() {\n var times = [];\n var rslvs = [];\n var rstpcs = []; // console.log(this.damspgLists);\n\n this.damspgLists.forEach(function (e) {\n // times.push(e.createTime.split(' ')[1])\n rslvs.push(e.rslv);\n rstpcs.push(e.rstpc);\n });\n var seepageChartDom = document.getElementById('seepageChart');\n this.seepageChart = echarts.init(seepageChartDom);\n var option = {\n tooltip: {\n trigger: 'axis',\n backgroundColor: 'rgba(0,0,0,0.7)',\n textStyle: {\n color: '#dddee0'\n },\n axisPointer: {\n type: 'cross',\n label: {\n backgroundColor: '#6a7985'\n }\n }\n },\n // legend: {\n // top: '2%',\n // left: '4%',\n // // data: ['水位'],\n // textStyle: {\n // color: '#adb9ba',\n // fontSize: 10,\n // },\n // },\n grid: {\n top: '20%',\n left: '4%',\n right: '10%',\n bottom: '6%',\n containLabel: true\n },\n xAxis: [{\n name: '库容',\n type: 'category',\n boundaryGap: false,\n data: rstpcs\n }],\n yAxis: [{\n name: '水位',\n type: 'value',\n scale: true\n }],\n series: [{\n name: '水位',\n type: 'line',\n smooth: true,\n emphasis: {\n focus: 'series'\n },\n data: rslvs,\n itemStyle: {\n color: '#0091ff'\n }\n }]\n };\n option && this.seepageChart.setOption(option);\n },\n initPressureChart: function initPressureChart() {\n // damspprLists\n var times = [];\n var pztbwls = [];\n var jpztbwls = [];\n var dpztbwls = [];\n var maxNum = [];\n var minNum = [];\n this.damspprLists.forEach(function (e) {\n console.log(e);\n\n if (e.pztbwl) {\n pztbwls.push(e.pztbwl);\n }\n\n if (e.jpztbwl) {\n jpztbwls.push(e.jpztbwl);\n }\n\n if (e.dpztbwl) {\n dpztbwls.push(e.dpztbwl);\n }\n\n times.push(e.mstm.slice(5));\n });\n\n if (pztbwls.length > 0) {\n maxNum.push(Math.max.apply(Math, pztbwls));\n minNum.push(Math.min.apply(Math, pztbwls));\n }\n\n if (jpztbwls.length > 0) {\n maxNum.push(Math.max.apply(Math, jpztbwls));\n minNum.push(Math.min.apply(Math, jpztbwls));\n }\n\n if (dpztbwls.length > 0) {\n maxNum.push(Math.max.apply(Math, dpztbwls));\n minNum.push(Math.min.apply(Math, dpztbwls));\n }\n\n var pressureChartDom = document.getElementById('pressureChart');\n this.pressureChart = echarts.init(pressureChartDom);\n var option = {\n tooltip: {\n trigger: 'axis',\n backgroundColor: 'rgba(0,0,0,0.7)',\n textStyle: {\n color: '#dddee0'\n },\n axisPointer: {\n type: 'cross',\n label: {\n backgroundColor: '#6a7985'\n }\n }\n },\n legend: {\n top: '2%',\n left: '4%',\n data: ['测压管危险水位', '测压管警戒水位', '测压管水位'],\n textStyle: {\n color: '#adb9ba',\n fontSize: 10\n }\n },\n grid: {\n top: '20%',\n left: '4%',\n right: '4%',\n bottom: '6%',\n containLabel: true\n },\n xAxis: [{\n type: 'category',\n boundaryGap: false,\n data: times\n }],\n yAxis: [{\n type: 'value',\n // max: Math.ceil(Math.max(...maxNum) * 1.0001),\n // min: Math.floor(Math.min(...maxNum) * 0.999),\n max: Math.ceil(Math.max.apply(Math, maxNum)),\n min: Math.floor(Math.min.apply(Math, maxNum)),\n // splitNumber: 6,// 想要分隔的段数\n interval: 0.1,\n //每次增加几个\n axisLabel: {\n showMaxLabel: true,\n showMinLabel: true\n }\n }],\n series: [// {\n // name: '测压管危险水位',\n // type: 'line',\n // smooth: true,\n // emphasis: {\n // focus: 'series' +\n // },\n // data: dpztbwls,\n // itemStyle: {\n // normal: {\n // color: '#b22222',\n // lineStyle: {\n // color: '#b22222'\n // }\n // }\n // }\n // },\n // {\n // name: '测压管警戒水位',\n // type: 'line',\n // smooth: true,\n // emphasis: {\n // focus: 'series'\n // },\n // data: jpztbwls,\n // itemStyle: {\n // normal: {\n // color: '#ff6347',\n // lineStyle: {\n // color: '#ff6347'\n // }\n // }\n // }\n // },\n {\n name: '测压管水位',\n type: 'line',\n smooth: true,\n emphasis: {\n focus: 'series'\n },\n data: pztbwls,\n itemStyle: {\n color: '#6767ff'\n }\n }]\n };\n option && this.pressureChart.setOption(option);\n },\n initShiftChart: function initShiftChart() {\n var times = [];\n var xrdsList = [];\n var yrdsList = [];\n var zrdsList = [];\n this.dammvLists.forEach(function (e) {\n times.push(e.tm.split(' ')[1]);\n xrdsList.push(e.dx);\n yrdsList.push(e.dy);\n zrdsList.push(e.dz);\n });\n var shiftChartDom = document.getElementById('shiftChart');\n this.shiftChart = echarts.init(shiftChartDom);\n var option = {\n tooltip: {\n trigger: 'axis',\n backgroundColor: 'rgba(0,0,0,0.7)',\n textStyle: {\n color: '#dddee0'\n },\n axisPointer: {\n type: 'cross',\n label: {\n backgroundColor: '#6a7985'\n }\n }\n },\n legend: {\n top: '6%',\n left: '4%',\n data: ['x方向位移(mm)', 'y方向位移(mm)', 'z方向位移(mm)'],\n textStyle: {\n color: '#adb9ba',\n fontSize: 10\n }\n },\n grid: {\n top: '24%',\n left: '4%',\n right: '4%',\n bottom: '6%',\n containLabel: true\n },\n xAxis: [{\n type: 'category',\n boundaryGap: false,\n data: times\n }],\n yAxis: [{\n type: 'value'\n }],\n series: [{\n name: 'x方向位移(mm)',\n type: 'line',\n smooth: true,\n emphasis: {\n focus: 'series'\n },\n data: xrdsList,\n itemStyle: {\n color: '#ff9a00'\n }\n }, {\n name: 'y方向位移(mm)',\n type: 'line',\n smooth: true,\n emphasis: {\n focus: 'series'\n },\n data: yrdsList,\n itemStyle: {\n color: '#6767ff'\n }\n }, {\n name: 'z方向位移(mm)',\n type: 'line',\n smooth: true,\n emphasis: {\n focus: 'series'\n },\n data: zrdsList,\n itemStyle: {\n color: '#91cc75'\n }\n }]\n };\n option && this.shiftChart.setOption(option);\n }\n }\n};",null]}