小数点保留两位计算修正;暖表构件楼层转换为init解决构件未加载问题;照明恢复状态改为清除标签和构建不使用resetStatus方法

dev
zhangqun 3 years ago
parent 15f4d9df6f
commit 2c1c110c55
  1. 2
      src/components/monitoring/light.vue
  2. 108
      src/components/monitoring/warm.vue
  3. 5
      src/util/bfHelper.js
  4. 2
      src/views/garden/generalizePattern.vue
  5. 2
      src/views/sourceAnaly/components/consumeAnaly.vue
  6. 2
      src/views/sourceAnaly/totalCenter.vue

@ -365,6 +365,8 @@ export default {
if (newval) {
//
// bfHelper.resetStatus(2);
bfHelper.clearDrawableContainer();
bfHelper.clearTags();
if (newval == 1) {
window.sessionStorage.setItem(
"camera",

@ -3,13 +3,13 @@
<div v-if="warmState && bimModel == 1" class="warm">
<clickCp :bimModel="bimModel" sbType="暖" ref="clickcp"></clickCp>
<div class="mapDom" style="
position: absolute;
left: 105px;
top: 210px;
width: 250px;
height: 180px;
margin: 45px auto;
" v-if="bimModel == 1"></div>
position: absolute;
left: 105px;
top: 210px;
width: 250px;
height: 180px;
margin: 45px auto;
" v-if="bimModel == 1"></div>
<!-- 返回主视角 -->
<backHome :bimModel="bimModel" type="暖" :modelIds="warmModel" dom=".mapDom"></backHome>
<div class="mode_box">
@ -37,7 +37,7 @@
<img v-if="curWarm.compare > 0" class="compare" src="../../../public/img/monitoring/electricity/up.png" />
<img v-else class="compare" src="../../../public/img/monitoring/electricity/down.png" />
<span :style="{ color: curWarm.compare > 0 ? '#ff8b2e' : '#2cd52c' }" class="use-unit">{{
Math.abs(curWarm.compare)
(curWarm.compare + "").substring((curWarm.compare + "").indexOf(".")).length > 3 ? curWarm.compare.toFixed(2) : Math.abs(curWarm.compare)
}}MJ</span>
</div>
</div>
@ -85,7 +85,7 @@
<img v-if="item.compare > 0" class="compare" src="../../../public/img/monitoring/electricity/up.png" />
<img v-else class="compare" src="../../../public/img/monitoring/electricity/down.png" />
<span :style="{ color: item.compare > 0 ? '#ff8b2e' : '#2cd52c' }" class="use-unit">{{
Math.abs(item.monthBasis)
(item.monthBasis + "").substring((item.monthBasis + "").indexOf(".")) > 2 ? item.monthBasis.toFixed(2) : Math.abs(item.monthBasis)
}}%</span>
</div>
</div>
@ -227,9 +227,9 @@
}">{{ item.warnDate.substring(5, 16) }}</span>
</div>
</div>
<div class="item flex-center" v-for="(item, index) in listData.warnEventList"
<div v-if="activeTab == 2" class="item flex-center" v-for="(item, index) in listData.warnEventList"
@mouseenter="showAlarkAlert(item, index, 1)" style="position: relative"
@mouseleave="closeAlarkAlert(item, index, 1)" :key="'warnEvent' + index" v-else>
@mouseleave="closeAlarkAlert(item, index, 1)" :key="'warnEvent' + index">
<div :style="{ display: item.showAlert ? 'flex' : 'none' }" class="alark-alert">
<p @click="bjClick(item)">
<img src="../../../public/img/monitoring/electricity/alark-detail-icon.png" alt="" />
@ -273,15 +273,15 @@
</div>
</vue-seamless-scroll>
<div style="
position: absolute;
bottom: 10px;
right: 10px;
width: 345px;
text-align: right;
color: rgb(7, 230, 237);
font-size: 14px;
cursor: pointer;
">
position: absolute;
bottom: 10px;
right: 10px;
width: 345px;
text-align: right;
color: rgb(7, 230, 237);
font-size: 14px;
cursor: pointer;
">
<span @click="goMoreWarnList">查看报警详情</span>
</div>
</div>
@ -317,24 +317,24 @@
<el-table-column label="设备位置" width="100">
<template slot-scope="scope">
<div class="flex-center dev_name" style="
overflow: hidden;
text-overflow: ellipsis;
cursor: pointer;
">
<span style="
padding-left: 10px;
font-size: 13px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
" :style="{
color:
scope.row.status == 90000
? 'white'
: scope.row.status == 90001
? '#a5bbe5'
: '#ff0000',
}" :title="scope.row.location">{{ scope.row.location }}</span>
cursor: pointer;
">
<span style="
padding-left: 10px;
font-size: 13px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
" :style="{
color:
scope.row.status == 90000
? 'white'
: scope.row.status == 90001
? '#a5bbe5'
: '#ff0000',
}" :title="scope.row.location">{{ scope.row.location }}</span>
</div>
</template>
</el-table-column>
@ -477,6 +477,7 @@ export default {
//
bfHelper.resetStatus(2);
bfHelper.extObjMngClear(); //
console.log('bfstate',newval)
if (newval == 1) {
//
@ -514,6 +515,31 @@ export default {
}, 300);
bfHelper.lookEquipmentCop("暖");
bfHelper.setOpacityFun();
bfHelper.setCameraStatus({
aspect: 1.889763779527559,
coordinateSystem: "world",
far: 960464.7787185954,
fov: 45,
name: "persp",
near: 105041.57557288553,
position: {
x: 114923.08877241895,
y: -391542.9803033385,
z: 219845.7809478254
},
target: {
x: -8729.420142852026,
y: 863922.0428858905,
z: -496665.6824418152
},
up: {
x: -0.048407478040169157,
y: 0.4914893345691443,
z: 0.8695372045373162
},
version: 1,
zoom: 1
});//
} else {
if (floor.indexOf("undefined") == -1) {
//
@ -632,9 +658,9 @@ export default {
this.getHistoryWarm(); //
this.getCurWarm(); //
this.getMode(); //
this.getWarmLists(); //
// this.getWarmLists(); // 20230317bim
// this.getWarmGK(); //
this.getHeatWarnList(); //
// this.getHeatWarnList(); // 20230317bim
}
},
clickAlarm(item) {
@ -724,6 +750,7 @@ export default {
this.layer = item.floored;
bfHelper.clearDrawableContainer();
let id = bfHelper.disposeId(item.area, item.build, item.modelId);
console.log('bjclick',id)
bfHelper.customTag(
bfHelper.getBoxMessage(id, true).max,
null,
@ -770,7 +797,7 @@ export default {
},
addLabel() {
//
this.labelContent();;
this.labelContent();
window.addEventListener("click", (e) => {
//
if (e.target.id.indexOf("heatmeter") != -1) {
@ -885,14 +912,13 @@ export default {
},
labelContent() {
//
for (let i = 0; i < this.tableData.length; i++) {
let id = bfHelper.disposeId(
this.tableData[i].area,
this.tableData[i].build,
this.tableData[i].modelId
);
// console.log(bfHelper.getBoxMessage(id))
// console.log(id,bfHelper.getBoxMessage(id))
let zb = bfHelper.getBoxMessage(id, true).max;
bfHelper.customTag(
zb,

@ -3491,7 +3491,7 @@ const navigationMap = (dom, img, build, floor) => {
viewer3D.render();
};
const mapUpdate = (img, mapAnchors, modelAnchors) => {
console.log('mapUpdate', navigationMap2);
// console.log('mapUpdate', navigationMap2);
if (navigationMap2 != undefined && navigationMap2) {
navigationMap2.associateModel({
url: img,
@ -4467,7 +4467,7 @@ const lookPipeline2 = (
categoryId: conditions2[b].categoryId,
familyType: conditions2[b].familyType,
fileId: ywqTowerFileId[tower],
levelName: layer + 1 + "F",
levelName: (parseInt(layer) + 1) + "F",
};
} else {
obj = {
@ -4511,6 +4511,7 @@ const lookPipeline2 = (
// 根据条件显示
arr2.push(...arr3);
// 根据条件设置构件颜色
console.log('条件显示的构件',arr2)
showComponentsByObjectData(arr2);
setConditionsColor(arr2, color);
}

@ -638,7 +638,7 @@
>
<span
><span class="num">{{
(item.consumeTotal + "").substring(".").length > 3
(item.consumeTotal + "").substring((item.consumeTotal + "").indexOf(".")).length > 3
? item.consumeTotal.toFixed(2)
: item.consumeTotal
}}</span

@ -16,7 +16,7 @@
<el-table-column label="|" width="15" ></el-table-column>
<el-table-column label="总能耗" align="center">
<template slot-scope="scope">
{{ (scope.row.totalKgce + "").substring(".") > 2 ? scope.row.totalKgce.toFixed(2) : scope.row.totalKgce }}
{{ (scope.row.totalKgce + "").substring((scope.row.totalKgce + "").indexOf(".")).length > 3 ? scope.row.totalKgce.toFixed(2) : scope.row.totalKgce }}
</template>
</el-table-column>
<el-table-column label="|" width="15"></el-table-column>

@ -28,7 +28,7 @@
<div class="analy-total-detail-all-left">
消耗量
<span class="big-size"><span>{{
(consumeSituation.totalKgce + "").substring(".") > 2
(consumeSituation.totalKgce + "").substring((consumeSituation.totalKgce + "").indexOf(".")).length > 3
? consumeSituation.totalKgce.toFixed(2)
: consumeSituation.totalKgce
}}</span>kgce</span>

Loading…
Cancel
Save