Commit 3f2a0720 authored by 纪泽龙's avatar 纪泽龙

Merge branch 'develop_jzl'

parents b467e3bd cc9fb299
/* /*
* @Author: your name * @Author: your name
* @Date: 2022-02-23 15:28:07 * @Date: 2022-02-23 15:28:07
* @LastEditTime: 2022-03-01 15:54:19 * @LastEditTime: 2022-03-04 17:16:53
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /newDev/gassafety-progress/gassafetyprogress-web/src/api/bigWindow/getdevice.js * @FilePath: /newDev/gassafety-progress/gassafetyprogress-web/src/api/bigWindow/getdevice.js
...@@ -25,6 +25,15 @@ export function getTyx(query) { ...@@ -25,6 +25,15 @@ export function getTyx(query) {
params: query params: query
}) })
} }
// 调压箱下面的设备接口
export function getTyxDevice(query) {
return request({
url: '/pipe/pipe/selectPressureFlow',
method: 'get',
params: query
})
}
// 是阀门 // 是阀门
export function getFm(query) { export function getFm(query) {
...@@ -35,6 +44,15 @@ export function getFm(query) { ...@@ -35,6 +44,15 @@ export function getFm(query) {
}) })
} }
// 阀门下面的设备接口
export function getFmDevice(query) {
return request({
url: '/pipe/pipe/selectPressureFlow',
method: 'get',
params: query
})
}
// 厂站 // 厂站
export function getCz(query) { export function getCz(query) {
...@@ -44,6 +62,14 @@ export function getCz(query) { ...@@ -44,6 +62,14 @@ export function getCz(query) {
params: query params: query
}) })
} }
// 场站下的设备
export function getCzDevice(query) {
return request({
url: '/pipe/pipe/selecttSiteStationInfoData',
method: 'get',
params: query
})
}
// 监控 // 监控
export function getVideo(query) { export function getVideo(query) {
return request({ return request({
......
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2022-01-26 20:07:52 * @Date: 2022-01-26 20:07:52
* @LastEditTime: 2022-02-28 18:05:19 * @LastEditTime: 2022-03-04 17:25:27
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
...@@ -61,8 +61,15 @@ ...@@ -61,8 +61,15 @@
<div>已处理报警</div> <div>已处理报警</div>
<div class="last">报警中</div> <div class="last">报警中</div>
</div> </div>
<div class="tbody flex" v-if="Array.isArray(deviceData.pressureFlows)"> <template v-if="list.length > 0">
<div class="first zzz">{{ "压力表" }}</div> <div
class="tbody flex"
v-for="deviceData in list"
:key="deviceData.inAlarm+Math.random()"
>
<div v-unValue class="first zzz">
{{ typeList[deviceData.dataType] }}
</div>
<div v-unValue class="">{{ deviceData.numberPressureGauges }}</div> <div v-unValue class="">{{ deviceData.numberPressureGauges }}</div>
<div v-unValue class=""> <div v-unValue class="">
{{ deviceData.onlineEquipment }} {{ deviceData.onlineEquipment }}
...@@ -80,25 +87,7 @@ ...@@ -80,25 +87,7 @@
{{ deviceData.inAlarm }} {{ deviceData.inAlarm }}
</div> </div>
</div> </div>
<div class="tbody flex" v-if="Array.isArray(deviceData.pressureFlows)"> </template>
<div class="first zzz">{{ "流量计" }}</div>
<div v-unValue class="">{{ deviceData.numberEquipment }}</div>
<div v-unValue class="">
{{ deviceData.numberOnlineEquipment }}
</div>
<div v-unValue class="">
{{ deviceData.numberOfflineEquipment }}
</div>
<div v-unValue class="">
{{ deviceData.numberHistoricalAlarm }}
</div>
<div v-unValue class="">
{{ deviceData.numberAlarmProcessed }}
</div>
<div v-unValue class="last">
{{ deviceData.numberInAlarm }}
</div>
</div>
</div> </div>
<div class="btn"> <div class="btn">
...@@ -109,12 +98,49 @@ ...@@ -109,12 +98,49 @@
<script> <script>
import { companyType, deviceType } from "@/utils/mapClass/config.js"; import { companyType, deviceType } from "@/utils/mapClass/config.js";
import { getCzDevice } from "@/api/bigWindow/getDevice.js";
export default { export default {
data() { data() {
return { return {
companyType, companyType,
deviceType, deviceType,
profile: "暂无", profile: "暂无",
typeList: {
// 1压力表 2流量计 3探测器
1: "压力表",
2: "流量计",
3: "探测器",
},
list: [
{
numberPressureGauges: "-",
onlineEquipment: "-",
offlineEquipment: "-",
historicalAlarm: "-",
alarmProcessed: "-",
inAlarm: "-",
dataType: 1,
},
{
numberPressureGauges: "-",
onlineEquipment: "-",
offlineEquipment: "-",
historicalAlarm: "-",
alarmProcessed: "-",
inAlarm: "-",
dataType: 2,
},
{
numberPressureGauges: "-",
onlineEquipment: "-",
offlineEquipment: "-",
historicalAlarm: "-",
alarmProcessed: "-",
inAlarm: "-",
dataType: 3,
},
],
}; };
}, },
computed: { computed: {
...@@ -133,7 +159,8 @@ export default { ...@@ -133,7 +159,8 @@ export default {
this.companyType[item.conpanyId] = item.companyName; this.companyType[item.conpanyId] = item.companyName;
}); });
} }
console.log(this.deviceData); this.myHttp()
}, },
methods: { methods: {
close() { close() {
...@@ -142,6 +169,12 @@ export default { ...@@ -142,6 +169,12 @@ export default {
btnClick() { btnClick() {
this.vueRoot.centerDataFunc(this.deviceData.pressureFlows); this.vueRoot.centerDataFunc(this.deviceData.pressureFlows);
}, },
myHttp() {
getCzDevice({ deviceId: this.deviceData.siteStationId }).then((res) => {
this.list = res.data[0].subordinateEquipmentList;
console.log("resresres",res)
});
},
}, },
}; };
</script> </script>
......
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2022-01-26 20:07:52 * @Date: 2022-01-26 20:07:52
* @LastEditTime: 2022-03-03 11:51:13 * @LastEditTime: 2022-03-04 17:27:21
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
...@@ -61,8 +61,15 @@ ...@@ -61,8 +61,15 @@
<div>已处理报警</div> <div>已处理报警</div>
<div class="last">报警中</div> <div class="last">报警中</div>
</div> </div>
<div class="tbody flex" v-if="Array.isArray(deviceData.pressureFlows)"> <template v-if="list.length > 0">
<div class="first zzz">{{ "压力表" }}</div> <div
class="tbody flex"
v-for="deviceData in list"
:key="deviceData.inAlarm+Math.random()"
>
<div v-unValue class="first zzz">
{{ typeList[deviceData.dataType] }}
</div>
<div v-unValue class="">{{ deviceData.numberPressureGauges }}</div> <div v-unValue class="">{{ deviceData.numberPressureGauges }}</div>
<div v-unValue class=""> <div v-unValue class="">
{{ deviceData.onlineEquipment }} {{ deviceData.onlineEquipment }}
...@@ -80,42 +87,60 @@ ...@@ -80,42 +87,60 @@
{{ deviceData.inAlarm }} {{ deviceData.inAlarm }}
</div> </div>
</div> </div>
<div class="tbody flex" v-if="Array.isArray(deviceData.pressureFlows)"> </template>
<div class="first zzz">{{ "流量计" }}</div>
<div v-unValue class="">{{ deviceData.numberEquipment }}</div>
<div v-unValue class="">
{{ deviceData.numberOnlineEquipment }}
</div>
<div v-unValue class="">
{{ deviceData.numberOfflineEquipment }}
</div>
<div v-unValue class="">
{{ deviceData.numberHistoricalAlarm }}
</div>
<div v-unValue class="">
{{ deviceData.numberAlarmProcessed }}
</div>
<div v-unValue class="last">
{{ deviceData.numberInAlarm }}
</div>
</div>
</div> </div>
<div class="btn"> <div class="btn">
<div @click="btnClick">感知设备</div> <!-- <div @click="btnClick">感知设备</div> -->
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import { companyType, deviceType } from "@/utils/mapClass/config.js"; import { companyType, deviceType } from "@/utils/mapClass/config.js";
import { getTyx, getFm } from "@/api/bigWindow/getDevice.js"; import { getTyxDevice, getFmDevice } from "@/api/bigWindow/getDevice.js";
export default { export default {
data() { data() {
return { return {
companyType, companyType,
deviceType, deviceType,
profile: "暂无", profile: "暂无",
typeList: {
// 1压力表 2流量计 3探测器
1: "压力表",
2: "流量计",
3: "探测器",
},
list: [
{
numberPressureGauges: "-",
onlineEquipment: "-",
offlineEquipment: "-",
historicalAlarm: "-",
alarmProcessed: "-",
inAlarm: "-",
dataType: 1,
},
{
numberPressureGauges: "-",
onlineEquipment: "-",
offlineEquipment: "-",
historicalAlarm: "-",
alarmProcessed: "-",
inAlarm: "-",
dataType: 2,
},
{
numberPressureGauges: "-",
onlineEquipment: "-",
offlineEquipment: "-",
historicalAlarm: "-",
alarmProcessed: "-",
inAlarm: "-",
dataType: 3,
},
],
}; };
}, },
computed: { computed: {
...@@ -146,25 +171,16 @@ export default { ...@@ -146,25 +171,16 @@ export default {
this.vueRoot.centerDataFunc(this.deviceData.pressureFlows); this.vueRoot.centerDataFunc(this.deviceData.pressureFlows);
}, },
myHttp() { myHttp() {
console.log(this.deviceData.iconType) console.log(this.deviceData.iconType);
if (this.deviceData.iconType == 2) { if (this.deviceData.iconType == 2) {
getTyx({ DeviceId: this.deviceData.DeviceId }).then((res) => { getTyxDevice({ deviceId: this.deviceData.deviceId }).then((res) => {
if (res.code == 200) { this.list = res.data[0].subordinateEquipmentList;
const data = res.data.filter( console.log(this.list);
(item) => item.deviceId == this.deviceData.deviceId
)[0].detectorCountList;
this.deviceData.detectorCountList = data;
}
}); });
} else { } else {
getFm({ DeviceId: this.deviceData.DeviceId }).then((res) => { getFmDevice({ deviceId: this.deviceData.deviceId }).then((res) => {
if (res.code == 200) { this.list = res.data[0].subordinateEquipmentList;
const data = res.data.filter(
(item) => item.deviceId == this.deviceData.deviceId
)[0].detectorCountList;
this.deviceData.detectorCountList = data;
}
}); });
} }
}, },
......
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2022-01-11 13:44:17 * @Date: 2022-01-11 13:44:17
* @LastEditTime: 2022-03-03 16:23:01 * @LastEditTime: 2022-03-04 14:34:32
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /test/hello-world/src/views/Home.vue * @FilePath: /test/hello-world/src/views/Home.vue
--> -->
<template> <template>
<div class="home bigwindow"> <div class="home bigwindow">
<div class="goSystem" @click="$router.push('/index')">进入管理系统</div> <div class="goSystem" @click="$router.push('/index')">进入管理系统</div>
<div id="map"></div> <div id="map"></div>
<Center :show="show" :centerData="centerData" /> <Center :show="show" :centerData="centerData" />
...@@ -180,6 +182,7 @@ export default { ...@@ -180,6 +182,7 @@ export default {
}, },
data() { data() {
return { return {
map: null, map: null,
show: false, show: false,
centerData: null, centerData: null,
...@@ -352,7 +355,6 @@ export default { ...@@ -352,7 +355,6 @@ export default {
goMap(httpFunc, addFunc, component) { goMap(httpFunc, addFunc, component) {
return httpFunc().then((res) => { return httpFunc().then((res) => {
// 给用户加icontype // 给用户加icontype
if (res.data && !res.data[0].iconType) { if (res.data && !res.data[0].iconType) {
res.data.forEach((item) => { res.data.forEach((item) => {
item.iconType = 6; item.iconType = 6;
...@@ -371,6 +373,8 @@ export default { ...@@ -371,6 +373,8 @@ export default {
} else { } else {
config = { data: res.data }; config = { data: res.data };
} }
console.log("reresresresresresresresresress",config)
addFunc(config, component); addFunc(config, component);
return config.iconType; return config.iconType;
}); });
......
...@@ -34,8 +34,8 @@ module.exports = { ...@@ -34,8 +34,8 @@ module.exports = {
proxy: { proxy: {
// detail: https://cli.vuejs.org/config/#devserver-proxy // detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
// target: `http://192.168.2.14:8903/gassafety`, target: `http://192.168.2.14:8903/gassafety`,
target: `http://222.223.203.154:8092/gassafety`, // target: `http://222.223.203.154:8092/gassafety`,
changeOrigin: true, changeOrigin: true,
pathRewrite: { pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: '' ['^' + process.env.VUE_APP_BASE_API]: ''
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment