| | |
| | | } |
| | | |
| | | /** |
| | | * 根据维护区查询机房站点 |
| | | * battInf/searchStationNameInGroup |
| | | * { |
| | | * stationName1 省 |
| | | * } |
| | | */ |
| | | export const roomsStation = (data) => { |
| | | return axios({ |
| | | method: "GET", |
| | | url: "battInf/searchStationNameInGroup", |
| | | params: data, |
| | | data: null |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据维护区和机房查询蓄电池组 |
| | | * {"stationName1":"省","stationName":"机房名称"} |
| | | */ |
| | | export const batterySearch = (data) => { |
| | | return axios({ |
| | | method: "GET", |
| | | url: "battInf/searchBattgroupidInGroup", |
| | | params: data, |
| | | data: null |
| | | }); |
| | | } |
| | | |
| | | /** |
| | | * 查询机房停电信息 |
| | | * 无参 |
| | | */ |
| | |
| | | { |
| | | label: "设备告警实时查询", |
| | | name: "deviceTimequery", |
| | | src: "/deviceTimequery", |
| | | src: "/alarmMager/deviceTimequery", |
| | | permitName: "dev_alm_query_permit", |
| | | closable: true, |
| | | id: 4005, |
| | |
| | | { |
| | | label: "设备告警历史查询", |
| | | name: "deviceHistoryquery", |
| | | src: "/deviceHistoryquery", |
| | | src: "/alarmMager/deviceHistoryquery", |
| | | permitName: "dev_alm_query_permit", |
| | | closable: true, |
| | | id: 4006, |
| | |
| | | title: '电池历史告警', |
| | | icon: 'his' |
| | | } |
| | | }, { |
| | | path: 'deviceTimequery', |
| | | name: 'deviceTimequery', |
| | | component: () => import('@/views/alarmMager/deviceTimequery'), |
| | | meta: { |
| | | title: '设备实时告警', |
| | | icon: 'rt' |
| | | } |
| | | }, { |
| | | path: 'deviceHistoryquery', |
| | | name: 'deviceHistoryquery', |
| | | component: () => import('@/views/alarmMager/deviceHistoryquery'), |
| | | meta: { |
| | | title: '设备历史告警', |
| | | icon: 'his' |
| | | } |
| | | },] |
| | | }, |
| | | |
| | |
| | | |
| | | <script> |
| | | import { |
| | | roomsStation /* 机房站点 */, |
| | | batterySearch /* 蓄电池组 */, |
| | | } from "./js/batteryrTimequery.js"; |
| | | import { |
| | | historySeroom /* 历史告警记录 */, |
| | | hisDelet /*删除 */, |
| | | } from "./js/batteryrHistoryquery.js"; |
| | | import { searchProvince } from "@/assets/js/api"; |
| | | import { |
| | | searchProvince, |
| | | roomsStation /* 机房站点 */, |
| | | batterySearch /* 蓄电池组 */, |
| | | } from "@/assets/js/api"; |
| | | // 引入导出表格 |
| | | import { export_json_to_excel } from "@/assets/js/excel/Export2Excel.js"; |
| | | import { isHasPermit } from "@/assets/js/tools"; |
| | |
| | | }); |
| | | let len = res.data.length; |
| | | newsHost.unshift({ |
| | | label: `全部共${len}种`, |
| | | label: `全部(共${len}种)`, |
| | | value: "", |
| | | }); |
| | | this.newsHost = newsHost; |
| | |
| | | let newSite = res.data.map((item) => { |
| | | return { |
| | | label: item, |
| | | value: item |
| | | value: item, |
| | | }; |
| | | }); |
| | | let len = res.data.length; |
| | | newSite.unshift({ |
| | | label: `全部共${len}种`, |
| | | label: `全部(共${len}种)`, |
| | | value: "", |
| | | }); |
| | | this.newSite = newSite; |
| | |
| | | height="100%" |
| | | class="tableCent" |
| | | > |
| | | <el-table-column label="编号" type="index" width="50"> </el-table-column> |
| | | <el-table-column label="编号" type="index" width="50"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | v-for="header in table1.headers" |
| | | :key="header.prop" |
| | |
| | | height="100%" |
| | | class="tableCent" |
| | | > |
| | | <el-table-column label="编号" type="index" width="50"> </el-table-column> |
| | | <el-table-column label="编号" type="index" width="50"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | v-for="header in table2.headers" |
| | | :key="header.prop" |
| | |
| | | |
| | | <script> |
| | | import { |
| | | roomsStation /* 机房站点 */, |
| | | batterySearch /* 蓄电池组 */, |
| | | newsAlarm /*告警信息 */, |
| | | deletionRecord /* 删除 */, |
| | | reporTemergency /* 确认告警 */, |
| | | CancelTheAlarm /* 取消告警 */, |
| | | } from "./js/batteryrTimequery.js"; |
| | | import { searchProvince } from "@/assets/js/api"; |
| | | import { |
| | | searchProvince, |
| | | roomsStation /* 机房站点 */, |
| | | batterySearch /* 蓄电池组 */, |
| | | } from "@/assets/js/api"; |
| | | import { isHasPermit, Timeout } from "@/assets/js/tools"; |
| | | // 引入导出表格 |
| | | import { export_json_to_excel } from "@/assets/js/excel/Export2Excel.js"; |
| | |
| | | }); |
| | | let len = res.data.length; |
| | | typeList.unshift({ |
| | | label: `全部共${len}种`, |
| | | label: `全部(共${len}种)`, |
| | | value: "", |
| | | }); |
| | | this.vindicate = typeList; |
| | |
| | | let newRoms = res.data.map((item) => { |
| | | return { |
| | | label: item, |
| | | value: item |
| | | value: item, |
| | | }; |
| | | }); |
| | | let len = res.data.length; |
| | | newRoms.unshift({ |
| | | label: `全部共${len}种`, |
| | | label: `全部(共${len}种)`, |
| | | value: "", |
| | | }); |
| | | this.newRoms = newRoms; |
| | |
| | | pageSize: this.queryInfo1.pagesize, |
| | | }, |
| | | stationname: this.selectValue2, |
| | | stationname1: this.selectValue1 |
| | | stationname1: this.selectValue1, |
| | | }; |
| | | return param; |
| | | }, |
| | |
| | | if (confirmResult !== "confirm") { |
| | | return; |
| | | } |
| | | const del = await deletionRecord({num: val.num}); |
| | | const del = await deletionRecord({ num: val.num }); |
| | | let res = del.data; |
| | | if (res.code) { |
| | | this.$message.success("删除成功"); |
| | |
| | | return; |
| | | } |
| | | // console.log(vlas, 'vlas======'); |
| | | const wk = await reporTemergency({num: vlas.num}); |
| | | const wk = await reporTemergency({ num: vlas.num }); |
| | | // console.log('wk=====',wk); |
| | | let res = wk.data; |
| | | if (res.code) { |
| | |
| | | deviserchSeions /* 机房站点 */, |
| | | deviceRecord /* 告警记录 */, |
| | | deviceArarmdel /* 删除*/ |
| | | } from "@/assets/js/alarmAdmian/deviceHistoryquery.js"; |
| | | } from "./js/deviceHistoryquery.js"; |
| | | // 引入导出表格 |
| | | import { |
| | | export_json_to_excel |
| | | } from '../../assets/js/excel/Export2Excel.js' |
| | | } from '@/assets/js/excel/Export2Excel.js' |
| | | import {isHasPermit} from "@/assets/js/tools"; |
| | | |
| | | export default { |
| | |
| | | size="small" |
| | | > |
| | | <el-option |
| | | v-for="item in sesionsNews" |
| | | :key="item.value" |
| | | v-for="(item, idx) in sesionsNews" |
| | | :key="'station_' + idx" |
| | | :label="item.label" |
| | | :value="item.value" |
| | | ></el-option> |
| | |
| | | size="small" |
| | | > |
| | | <el-option |
| | | :label="'全部共' + options.length + '种'" |
| | | :label="'全部(共' + options.length + '种)'" |
| | | value="0" |
| | | ></el-option> |
| | | <el-option |
| | |
| | | <!-- 表单 --> |
| | | <div class="flex-page-content"> |
| | | <el-table stripe size="small" :data="table1.datas" height="100%"> |
| | | <el-table-column type="index" label="编号" width="50"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | v-for="header in table1.headers" |
| | | :key="header.prop" |
| | |
| | | :min-width="header.minWidth" |
| | | align="center" |
| | | > |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="确认告警时间" |
| | | width="180px" |
| | | align="center" |
| | | > |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.isalarm1 ? scope.row.monomers1 : "" }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="确认告警" width="80px" align="center"> |
| | | <template slot-scope="scope"> |
| | |
| | | <div class="flex-page-content"> |
| | | <el-table stripe size="small" :data="table2.datas" height="100%"> |
| | | <el-table-column |
| | | type="index" |
| | | label="编号" |
| | | width="50" |
| | | ></el-table-column> |
| | | <el-table-column |
| | | v-for="header in table2.headers" |
| | | :key="header.prop" |
| | | :prop="header.prop" |
| | |
| | | :min-width="header.minWidth" |
| | | align="center" |
| | | > |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="确认告警时间" |
| | | width="180px" |
| | | align="center" |
| | | > |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.isalarm1 ? scope.row.monomers1 : "" }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="确认告警" width="80px" align="center"> |
| | | <template slot-scope="scope"> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { searchProvince, roomsStation } from "@/assets/js/api"; |
| | | import { |
| | | deviceTypes, |
| | | deviceSeions, |
| | | deviceAlarm, |
| | | deviceOk, |
| | | deviceDelete, |
| | | CancelWarning, |
| | | } from "@/assets/js/alarmAdmian/deviceTimequery.js"; |
| | | } from "./js/deviceTimequery.js"; |
| | | // 引入导出表格 |
| | | import { export_json_to_excel } from "../../assets/js/excel/Export2Excel.js"; |
| | | import { export_json_to_excel } from "@/assets/js/excel/Export2Excel.js"; |
| | | import { getLabelByValue, isHasPermit, Timeout } from "@/assets/js/tools"; |
| | | |
| | | import getDevAlarm from "@/assets/js/tools/getDevAlarm"; |
| | |
| | | let alarmTypes = getDevAlarm().types; |
| | | let levels = getDevAlarm().levels; |
| | | return { |
| | | isCanConfirm: isCanConfirm, |
| | | isCanQuit: isCanQuit, |
| | | isCanDel: isCanDel, |
| | | isCanConfirm: isCanConfirm || !0, |
| | | isCanQuit: isCanQuit || !0, |
| | | isCanDel: isCanDel || !0, |
| | | timer: new Timeout(), |
| | | queryInfo1: { |
| | | currentPage: 1, |
| | |
| | | acTabs: "unconfirmed", |
| | | total1: 0, |
| | | total2: 0, |
| | | /* 日期 */ |
| | | valueTime: ["2000-01-01 00:00:00", "2020-09-20 00:00:00"], |
| | | selectValue1: "", |
| | | selectPlace1: "", |
| | | selectValue2: "", |
| | |
| | | options: alarmTypes, |
| | | levels: levels, |
| | | /* 维护区 */ |
| | | newDevie: [ |
| | | { |
| | | value: 0, |
| | | label: null, |
| | | }, |
| | | ], |
| | | newDevie: [], |
| | | /* 机房站点 */ |
| | | sesionsNews: [ |
| | | { |
| | | value: 0, |
| | | label: null, |
| | | }, |
| | | ], |
| | | sesionsNews: [], |
| | | /* 表单 */ |
| | | table1: { |
| | | headers: [ |
| | | { |
| | | prop: "rooms1", |
| | | label: "编号", |
| | | width: 50, |
| | | }, |
| | | { |
| | | prop: "batterys1", |
| | | prop: "devId", |
| | | label: "设备ID", |
| | | width: 120, |
| | | }, |
| | | { |
| | | prop: "tesa1", |
| | | prop: "devName", |
| | | label: "设备名", |
| | | width: 160, |
| | | }, |
| | | { |
| | | prop: "dev1", |
| | | prop: "devIp", |
| | | label: "设备IP", |
| | | width: 160, |
| | | }, |
| | | { |
| | | prop: "tester1", |
| | | prop: "stationName", |
| | | label: "机房名称", |
| | | minWidth: 220, |
| | | }, |
| | | { |
| | | prop: "alm_name", |
| | | prop: "almType", |
| | | label: "告警事件", |
| | | width: 200, |
| | | }, |
| | | { |
| | | prop: "alm_level_name", |
| | | prop: "almLevel", |
| | | label: "告警等级", |
| | | width: 120, |
| | | }, |
| | | { |
| | | prop: "starts1", |
| | | prop: "almStartTime", |
| | | label: "告警开始时间", |
| | | width: 180, |
| | | }, |
| | | { |
| | | prop: "almConfirmedTime", |
| | | label: "告警确认时间", |
| | | width: 180, |
| | | }, |
| | | ], |
| | |
| | | table2: { |
| | | headers: [ |
| | | { |
| | | prop: "rooms1", |
| | | label: "编号", |
| | | width: 50, |
| | | }, |
| | | { |
| | | prop: "batterys1", |
| | | prop: "devId", |
| | | label: "设备ID", |
| | | width: 120, |
| | | }, |
| | | { |
| | | prop: "tesa1", |
| | | prop: "devName", |
| | | label: "设备名", |
| | | width: 160, |
| | | }, |
| | | { |
| | | prop: "dev1", |
| | | prop: "devIp", |
| | | label: "设备IP", |
| | | width: 160, |
| | | }, |
| | | { |
| | | prop: "tester1", |
| | | prop: "stationName", |
| | | label: "机房名称", |
| | | minWidth: 220, |
| | | }, |
| | | { |
| | | prop: "alm_name", |
| | | prop: "almType", |
| | | label: "告警事件", |
| | | width: 200, |
| | | }, |
| | | { |
| | | prop: "alm_level_name", |
| | | prop: "almLevel", |
| | | label: "告警等级", |
| | | width: 120, |
| | | }, |
| | | { |
| | | prop: "starts1", |
| | | prop: "almStartTime", |
| | | label: "告警开始时间", |
| | | width: 180, |
| | | }, |
| | | { |
| | | prop: "almConfirmedTime", |
| | | label: "告警确认时间", |
| | | width: 180, |
| | | }, |
| | | ], |
| | |
| | | }, |
| | | /* 维护区 */ |
| | | async deviceTime() { |
| | | const devieceList = await deviceTypes(); |
| | | if ( |
| | | devieceList.data.result && |
| | | JSON.parse(devieceList.data.result).code == 1 |
| | | ) { |
| | | let newDevie = JSON.parse(devieceList.data.result).data.map((item) => { |
| | | const devieceList = await searchProvince(); |
| | | let res = devieceList.data; |
| | | if (res.code) { |
| | | let newDevie = res.data.map((item) => { |
| | | return { |
| | | label: item, |
| | | value: item, |
| | | }; |
| | | }); |
| | | let len = res.data.length; |
| | | newDevie.unshift({ |
| | | label: `全部共${newDevie.length}种`, |
| | | label: `全部(共${len}种)`, |
| | | value: "", |
| | | }); |
| | | this.newDevie = newDevie; |
| | | this.selectPlace1 = `全部(共${newDevie.length}种)`; |
| | | this.selectPlace1 = `全部(共${len}种)`; |
| | | } |
| | | }, |
| | | /* 机房名称 */ |
| | | async deviceName(status) { |
| | | const newDevicess = await deviceSeions({ |
| | | UNote: this.selectValue1, |
| | | const newDevicess = await roomsStation({ |
| | | stationName1: this.selectValue1, |
| | | }); |
| | | if ( |
| | | newDevicess.data.result && |
| | | JSON.parse(newDevicess.data.result).code == 1 |
| | | ) { |
| | | let sesionsNews = JSON.parse(newDevicess.data.result).data.map( |
| | | (item) => { |
| | | return { |
| | | label: item, |
| | | value: item, |
| | | }; |
| | | } |
| | | ); |
| | | let res = newDevicess.data; |
| | | if (res.code) { |
| | | let sesionsNews = res.data.map((item) => { |
| | | return { |
| | | label: item, |
| | | value: item, |
| | | }; |
| | | }); |
| | | let len = res.data.length; |
| | | sesionsNews.unshift({ |
| | | label: `全部共${sesionsNews.length}种`, |
| | | label: `全部(共${len}种)`, |
| | | value: "", |
| | | }); |
| | | this.sesionsNews = sesionsNews; |
| | | this.selectPlace2 = `全部(共${sesionsNews.length}种)`; |
| | | this.selectPlace2 = `全部(共${len}种)`; |
| | | if (status == 1) { |
| | | this.alarmDev(); |
| | | } |
| | |
| | | const newAlarm = await deviceAlarm({ |
| | | stationName1: this.selectValue1, |
| | | stationName: this.selectValue2, |
| | | alm_type: this.value, |
| | | alm_is_confirmed: 0, |
| | | almType: this.value, |
| | | almIsConfirmed: 0, |
| | | page: { |
| | | pageSize: this.queryInfo1.pagesize, |
| | | pageCurr: this.queryInfo1.currentPage, |
| | | }, |
| | | }); |
| | | if (newAlarm.data.result && JSON.parse(newAlarm.data.result).code == 1) { |
| | | const ssAlram = JSON.parse(newAlarm.data.result).data; |
| | | const alarmNes = ssAlram.map((item, index) => { |
| | | item.index = index + 1; |
| | | let isalarm1; |
| | | if (item.alm_is_confirmed === 1) { |
| | | isalarm1 = true; |
| | | } else { |
| | | isalarm1 = false; |
| | | } |
| | | return { |
| | | rooms1: item.index, |
| | | batterys1: item.dev_id, |
| | | tesa1: item.dev_name, |
| | | dev1: item.dev_ip, |
| | | tester1: item.stationName, |
| | | starts1: item.alm_start_time, |
| | | ends1: item.alm_end_time, |
| | | monomers1: "", |
| | | num: item.num, |
| | | alm_is_confirmed: item.alm_is_confirmed, |
| | | alm_level: item.alm_level, |
| | | alm_level_name: getLabelByValue(item.alm_level, this.levels, "---"), |
| | | alm_type: item.alm_type, |
| | | alm_name: getLabelByValue(item.alm_type, this.options, "---"), |
| | | alm_value: item.alm_value, |
| | | isalarm1: isalarm1, |
| | | isalarm2: isalarm1 ? "是" : "否", |
| | | }; |
| | | let res = newAlarm.data; |
| | | // console.log(res, 'res33==========='); |
| | | if (res.code) { |
| | | const alarmNes = res.data.list.map((item) => { |
| | | let isalarm1 = !!item.almIsConfirmed; |
| | | item.isalarm1 = isalarm1; |
| | | item.isalarm2 = isalarm1 ? "是" : "否"; |
| | | item.almConfirmedTime = isalarm1 ? item.almConfirmedTime : ""; |
| | | return item; |
| | | }); |
| | | this.table1.datas = alarmNes; |
| | | this.total1 = ssAlram[ssAlram.length - 1].usr_id; |
| | | this.total1 = res.data.total; |
| | | this.isFirstQuery = false; |
| | | // 关闭等待框 |
| | | loading && this.$layer.close(loading); |
| | |
| | | const newAlarm = await deviceAlarm({ |
| | | stationName1: this.selectValue1, |
| | | stationName: this.selectValue2, |
| | | alm_type: this.value, |
| | | alm_is_confirmed: 1, |
| | | almType: this.value, |
| | | almIsConfirmed: 1, |
| | | page: { |
| | | pageSize: this.queryInfo2.pagesize, |
| | | pageCurr: this.queryInfo2.currentPage, |
| | | }, |
| | | }); |
| | | if (newAlarm.data.result && JSON.parse(newAlarm.data.result).code == 1) { |
| | | const ssAlram = JSON.parse(newAlarm.data.result).data; |
| | | const alarmNes = ssAlram.map((item, index) => { |
| | | item.index = index + 1; |
| | | let isalarm1; |
| | | if (item.alm_is_confirmed === 1) { |
| | | isalarm1 = true; |
| | | } else { |
| | | isalarm1 = false; |
| | | } |
| | | return { |
| | | rooms1: item.index, |
| | | batterys1: item.dev_id, |
| | | tesa1: item.dev_name, |
| | | dev1: item.dev_ip, |
| | | tester1: item.stationName, |
| | | starts1: item.alm_start_time, |
| | | ends1: item.alm_end_time, |
| | | monomers1: item.alm_confirmed_time, |
| | | num: item.num, |
| | | alm_is_confirmed: item.alm_is_confirmed, |
| | | alm_level: item.alm_level, |
| | | alm_level_name: getLabelByValue(item.alm_level, this.levels, "---"), |
| | | alm_type: item.alm_type, |
| | | alm_name: getLabelByValue(item.alm_type, this.options, "---"), |
| | | alm_value: item.alm_value, |
| | | isalarm1: isalarm1, |
| | | isalarm2: isalarm1 ? "是" : "否", |
| | | }; |
| | | let res = newAlarm.data; |
| | | if (res.code) { |
| | | const alarmNes = res.data.list.map((item) => { |
| | | let isalarm1 = !!item.almIsConfirmed; |
| | | item.isalarm1 = isalarm1; |
| | | item.isalarm2 = isalarm1 ? "是" : "否"; |
| | | item.almConfirmedTime = isalarm1 ? item.almConfirmedTime : ""; |
| | | return item; |
| | | }); |
| | | this.table2.datas = alarmNes; |
| | | this.total2 = ssAlram[ssAlram.length - 1].usr_id; |
| | | this.total2 = res.data.total; |
| | | this.isFirstQuery = false; |
| | | // 关闭等待框 |
| | | loading && this.$layer.close(loading); |
| | |
| | | } |
| | | ).catch((err) => err); |
| | | if (confirmResult !== "confirm") { |
| | | return this.$message.info("已取消删除"); |
| | | return; |
| | | } |
| | | const ws = await deviceDelete([ |
| | | { |
| | | num: value.num, |
| | | stationName: value.tester1, |
| | | note: " ", |
| | | }, |
| | | ]); |
| | | if (JSON.parse(ws.data.result).code !== 1) { |
| | | return this.$message.error("删除失败"); |
| | | } |
| | | this.$message.success("删除成功"); |
| | | if (this.currentPage !== 1) { |
| | | if (this.table.datas.length === 1) { |
| | | this.currentPage -= 1; |
| | | const ws = await deviceDelete({ |
| | | num: value.num, |
| | | }); |
| | | let res = ws.data; |
| | | if (res.code) { |
| | | this.$message.success("删除成功"); |
| | | if (this.currentPage !== 1) { |
| | | if (this.table.datas.length === 1) { |
| | | this.currentPage -= 1; |
| | | } |
| | | } |
| | | this.alarmDev(); |
| | | } else { |
| | | this.$message.error("删除失败"); |
| | | } |
| | | this.alarmDev(); |
| | | }, |
| | | /* 确认告警 */ |
| | | async okAlarm(vlas) { |
| | |
| | | } |
| | | ).catch((err) => err); |
| | | if (confirmResult !== "confirm") { |
| | | return this.$message.info("已取消确认!"); |
| | | return; |
| | | } |
| | | const wk = await deviceOk([ |
| | | { |
| | | stationname: vlas.tester1, |
| | | num: vlas.num, |
| | | alm_confirmed_time: new Date().format("yyyy-MM-dd hh:mm:ss"), |
| | | alm_is_confirmed: 1, |
| | | note: "", |
| | | }, |
| | | ]); |
| | | if (wk.data.result && JSON.parse(wk.data.result).code == 1) { |
| | | const wk = await deviceOk({ |
| | | num: vlas.num, |
| | | }); |
| | | let res = wk.data; |
| | | if (res.code) { |
| | | this.$message.info("修改成功!"); |
| | | this.alarmDev(); |
| | | } else { |
| | |
| | | } |
| | | ).catch((err) => err); |
| | | if (confirmResult !== "confirm") { |
| | | return this.$message.info("已取消确认!"); |
| | | return; |
| | | } |
| | | const cc = await CancelWarning([ |
| | | { |
| | | num: valuew.num, |
| | | stationName: valuew.tester1, |
| | | note: "0", |
| | | alm_cleared_type: "2", |
| | | alm_end_time: valuew.ends1, |
| | | record_id: "0", |
| | | }, |
| | | ]); |
| | | if (JSON.parse(cc.data.result).code !== 1) { |
| | | return this.$message.error("确认失败!"); |
| | | const cc = await CancelWarning({ |
| | | num: valuew.num, |
| | | }); |
| | | let res = cc.data; |
| | | if (res.code) { |
| | | this.$message.success("操作成功!"); |
| | | this.alarmDev(); |
| | | } else { |
| | | this.$message.error("操作失败!"); |
| | | } |
| | | this.$message.success("取消成功!"); |
| | | this.alarmDev(); |
| | | }, |
| | | //维护区改变 |
| | | changeSelect1() { |
| | |
| | | import axios from "axios"; |
| | | /* 电池告警实时页面查询 */ |
| | | |
| | | /** |
| | | * 根据维护区查询机房站点 |
| | | * battInf/searchStationNameInGroup |
| | | * { |
| | | * stationName1 省 |
| | | * } |
| | | */ |
| | | export const roomsStation = (data) => { |
| | | return axios({ |
| | | method: "GET", |
| | | url: "battInf/searchStationNameInGroup", |
| | | params: data, |
| | | data: null |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据维护区和机房查询蓄电池组 |
| | | * {"stationName1":"省","stationName":"机房名称"} |
| | | */ |
| | | export const batterySearch = (data) => { |
| | | return axios({ |
| | | method: "GET", |
| | | url: "battInf/searchBattgroupidInGroup", |
| | | params: data, |
| | | data: null |
| | | }); |
| | | } |
| | | |
| | | //查询当前的告警信息 |
| | | export const newsAlarm = (data) => { |
| | | return axios({ |
| | |
| | | import axios from "../axios"; |
| | | import axios from "axios"; |
| | | /* 设备告警历史页面查询 */ |
| | | |
| | | /* 查询设备历史告警记录 |
| | |
| | | /* 设备告警实时页面查询 */ |
| | | |
| | | /* 查询设备实时告警 |
| | | Batt_devalarm_dataAction!serchByInfo // 旧 |
| | | json={"stationName1":"","stationName":"","alm_type":"0","page":{"pageSize":14,"pageCurr":1}} |
| | | */ |
| | | export const deviceAlarm = (data) => { |
| | | return axios({ |
| | | method: "post", |
| | | url: "Batt_devalarm_dataAction!serchByInfo", |
| | | data: "json=" + JSON.stringify(data) |
| | | }) |
| | | return axios({ |
| | | method: "POST", |
| | | url: "DevalarmDataAction/serchByInfo", |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /* |
| | | 确认告警 |
| | | Batt_devalarm_dataAction!updatePro // 旧 |
| | | json=[{"num":"118001","stationName":"江苏省-连云港市-赣榆区-10kV紫菜工业园开闭所-LD9","alm_is_confirmed":1, |
| | | "alm_confirmed_time":"2020-09-11 09:51:57","note":"通信故障"}] |
| | | */ |
| | | export const deviceOk = (data) => { |
| | | return axios({ |
| | | method: "post", |
| | | url: "Batt_devalarm_dataAction!updatePro", |
| | | data: "json=" + JSON.stringify(data) |
| | | }) |
| | | return axios({ |
| | | method: "GET", |
| | | url: "DevalarmDataAction/update", |
| | | params: data, |
| | | data: null |
| | | }) |
| | | } |
| | | |
| | | /* 删除告警 |
| | | Batt_devalarm_dataAction!deletePro // 旧 |
| | | json=[{"num":"166763","stationName":"湖北省-黄石市-黄石港区-测试机房-61850设备","note":"通信故障"}] |
| | | */ |
| | | export const deviceDelete = (data) => { |
| | | return axios({ |
| | | method: "post", |
| | | url: "Batt_devalarm_dataAction!deletePro ", |
| | | data: "json=" + JSON.stringify(data) |
| | | }) |
| | | return axios({ |
| | | method: "GET", |
| | | url: "DevalarmDataAction/delete", |
| | | params: data, |
| | | data: null |
| | | }) |
| | | } |
| | | |
| | | |
| | | /* 页面加载时查询维护区中的枢纽类型 |
| | | 无参 |
| | | */ |
| | | export const deviceTypes = () => { |
| | | return axios({ |
| | | method: "post", |
| | | url: "User_battgroup_baojigroup_battgroupAction!serchStationName1InGroup ", |
| | | data: null |
| | | }) |
| | | } |
| | | |
| | | /* |
| | | 机房名称 json={"UNote":""} |
| | | */ |
| | | export const deviceSeions = (data) => { |
| | | return axios({ |
| | | method: "post", |
| | | url: "User_battgroup_baojigroup_battgroupAction!serchStationNameInGroup ", |
| | | data: "json=" + JSON.stringify(data) |
| | | }) |
| | | } |
| | | |
| | | /* |
| | | /* 取消告警 |
| | | Batt_devalarm_dataAction!cancelPro // 旧 |
| | | json=[{"num":"586192","stationName":"广西省-南宁市-西乡塘区-西乡塘区清川桥北基站-设备", |
| | | "note":"通信故障","alm_cleared_type":2,"alm_end_time":"2020-09-30 11:43:14","record_id":0}] |
| | | */ |
| | | export const CancelWarning = (data) => { |
| | | return axios({ |
| | | method: "post", |
| | | url: "Batt_devalarm_dataAction!cancelPro ", |
| | | data: "json=" + JSON.stringify(data) |
| | | }) |
| | | return axios({ |
| | | method: "GET", |
| | | url: "DevalarmDataAction/cancel", |
| | | params: data, |
| | | data: null |
| | | }) |
| | | } |