邓洁 : 首屏风压接口对接
This commit is contained in:
@@ -16,21 +16,25 @@ const props = defineProps({
|
|||||||
});
|
});
|
||||||
const wpList = ref([]);
|
const wpList = ref([]);
|
||||||
watch(() => props.list, (now, old) => {
|
watch(() => props.list, (now, old) => {
|
||||||
now.map(item=>{
|
wpList.value.forEach(item=>{
|
||||||
item.unit='Pa'
|
now.forEach(item2=>{
|
||||||
|
if(item.equipmentId === item2.equipmentId){
|
||||||
|
item.value = item2.value
|
||||||
|
}
|
||||||
|
})
|
||||||
})
|
})
|
||||||
wpList.value = now
|
|
||||||
}, {deep: true});
|
}, {deep: true});
|
||||||
|
|
||||||
watch(() => props.winData, (now) => {
|
watch(() => props.winData, (now) => {
|
||||||
getScreenInfo(now)
|
getScreenInfo(now.windPressureSensorList)
|
||||||
}, {deep: true});
|
}, {deep: true});
|
||||||
|
|
||||||
const getScreenInfo = (now) => {
|
const getScreenInfo = (now) => {
|
||||||
let windPressureObj = {}
|
let windPressureObj = {}
|
||||||
let windPressureArr = []
|
let windPressureArr = []
|
||||||
now.windPressureSensorList.map(item => {
|
now.map(item => {
|
||||||
windPressureObj = {
|
windPressureObj = {
|
||||||
|
equipmentId:item.equipmentId,
|
||||||
max: 120,
|
max: 120,
|
||||||
value: item.value,
|
value: item.value,
|
||||||
point: item.valueThreshold,
|
point: item.valueThreshold,
|
||||||
|
|||||||
Reference in New Issue
Block a user