修改4D模拟
parent
1a29da701d
commit
8fef02b45b
|
@ -361,7 +361,27 @@ function doPLay(that) {
|
||||||
}
|
}
|
||||||
}, that.playTime);
|
}, that.playTime);
|
||||||
}
|
}
|
||||||
|
function modelRotate(that) {
|
||||||
|
let api = bim4DApi;
|
||||||
|
if(that.isPlay!=0){
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (that.models.length > 0) {
|
||||||
|
api.Model.getCenter(that.models[0].modelId, (data) => {
|
||||||
|
data.xx = 0.5;
|
||||||
|
api.Camera.autoRotate({
|
||||||
|
Speed: 0.5,
|
||||||
|
Position: data.position,
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function modelClearRotate() {
|
||||||
|
let api = window.bim4DApi;
|
||||||
|
if (api) {
|
||||||
|
api.Camera.stopAutoRotate();
|
||||||
|
}
|
||||||
|
}
|
||||||
export default {
|
export default {
|
||||||
options,
|
options,
|
||||||
ganttStyle,
|
ganttStyle,
|
||||||
|
@ -375,4 +395,6 @@ export default {
|
||||||
playStop,
|
playStop,
|
||||||
getCurrentTaskIndex,
|
getCurrentTaskIndex,
|
||||||
doPLay,
|
doPLay,
|
||||||
|
modelRotate,
|
||||||
|
modelClearRotate,
|
||||||
};
|
};
|
||||||
|
|
|
@ -91,6 +91,27 @@ export default {
|
||||||
document.body.classList.remove("is-sapi");
|
document.body.classList.remove("is-sapi");
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
let timer;
|
||||||
|
const resetTimer = () => {
|
||||||
|
clearTimeout(timer);
|
||||||
|
bim4DTools.modelClearRotate();
|
||||||
|
timer = setTimeout(() => {
|
||||||
|
bim4DTools.modelRotate(this)
|
||||||
|
clearTimeout(timer);
|
||||||
|
}, 1000 * 60 * 5);
|
||||||
|
};
|
||||||
|
|
||||||
|
document.addEventListener('mousemove', resetTimer);
|
||||||
|
document.addEventListener('keydown', resetTimer);
|
||||||
|
|
||||||
|
resetTimer();
|
||||||
|
|
||||||
|
this.$once('hook:beforeDestroy', () => {
|
||||||
|
document.removeEventListener('mousemove', resetTimer);
|
||||||
|
document.removeEventListener('keydown', resetTimer);
|
||||||
|
clearTimeout(timer);
|
||||||
|
});
|
||||||
|
|
||||||
this.$store.dispatch("ChangeNav", 705);
|
this.$store.dispatch("ChangeNav", 705);
|
||||||
this.dpi = this.$dpi();
|
this.dpi = this.$dpi();
|
||||||
window.addEventListener("resize", () => {
|
window.addEventListener("resize", () => {
|
||||||
|
@ -357,11 +378,11 @@ export default {
|
||||||
top: 100px;
|
top: 100px;
|
||||||
right: 40px;
|
right: 40px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
z-index: 9999;
|
||||||
.svg-icon {
|
.svg-icon {
|
||||||
width: 30px;
|
width: 30px;
|
||||||
height: 30px;
|
height: 30px;
|
||||||
fill: darkturquoise;
|
fill: darkturquoise;
|
||||||
z-index: 9999;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -115,7 +115,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="div-row r33" v-if="1==2">
|
<div class="div-row r33" v-if="1 == 2">
|
||||||
<div class="row-title">
|
<div class="row-title">
|
||||||
<svg-icon icon-class="signal"></svg-icon>
|
<svg-icon icon-class="signal"></svg-icon>
|
||||||
进度信息
|
进度信息
|
||||||
|
@ -278,7 +278,10 @@ export default {
|
||||||
|
|
||||||
resolve(nd);
|
resolve(nd);
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
document.querySelectorAll(".bim-briefing .model-tree .el-tree-node")[0].click();
|
let els = document.querySelectorAll(".bim-briefing .model-tree .el-tree-node");
|
||||||
|
if (els.length > 0) {
|
||||||
|
els[0].click();
|
||||||
|
}
|
||||||
}, 1000);
|
}, 1000);
|
||||||
} else if (node.level == 1) {
|
} else if (node.level == 1) {
|
||||||
let nd = [];
|
let nd = [];
|
||||||
|
@ -421,7 +424,7 @@ export default {
|
||||||
api.Model.setVisible(node.modelId, true);
|
api.Model.setVisible(node.modelId, true);
|
||||||
this.models.find((mm) => mm.modelId == node.modelId).visible = true;
|
this.models.find((mm) => mm.modelId == node.modelId).visible = true;
|
||||||
api.Model.original(node.modelId);
|
api.Model.original(node.modelId);
|
||||||
if(tmps.length>0){
|
if (tmps.length > 0) {
|
||||||
let tmpsIds2 = tmps.splice(0, 1000);
|
let tmpsIds2 = tmps.splice(0, 1000);
|
||||||
api.Feature.showFeatures(tmpsIds2.join("#"));
|
api.Feature.showFeatures(tmpsIds2.join("#"));
|
||||||
this.setFeatueVisible(tmps, true);
|
this.setFeatueVisible(tmps, true);
|
||||||
|
@ -707,7 +710,7 @@ export default {
|
||||||
&.r66 {
|
&.r66 {
|
||||||
height: calc(100% - 180px);
|
height: calc(100% - 180px);
|
||||||
}
|
}
|
||||||
&.r100{
|
&.r100 {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -223,58 +223,6 @@
|
||||||
<span class="sp-text">电箱监控</span>
|
<span class="sp-text">电箱监控</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="test-box">
|
|
||||||
<div class="tag-box box-type-3">
|
|
||||||
<div class="tag-txt">
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
<div class="data-item"><span class="data-label">高度:</span><span class="data-value">15m</span></div>
|
|
||||||
</div>
|
|
||||||
<img src="bimImages/4.png" alt="" class="tag-bg-img" />
|
|
||||||
<img src="bimImages/towerMonitor.png" class="tag-img" />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="test-box" style="left: 400px">
|
|
||||||
<div class="tag-box box-type-3">
|
|
||||||
<div class="tag-txt">
|
|
||||||
<table class="tb-power">
|
|
||||||
<tr>
|
|
||||||
<td></td>
|
|
||||||
<td width="150">电压</td>
|
|
||||||
<td width="150">电流</td>
|
|
||||||
<td width="150">功率</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>A向</td>
|
|
||||||
<td>1</td>
|
|
||||||
<td>2</td>
|
|
||||||
<td>3</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>A向</td>
|
|
||||||
<td>1</td>
|
|
||||||
<td>2</td>
|
|
||||||
<td>3</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>A向</td>
|
|
||||||
<td>1</td>
|
|
||||||
<td>2</td>
|
|
||||||
<td>3</td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<img src="bimImages/4.png" alt="" class="tag-bg-img" />
|
|
||||||
<img src="bimImages/towerMonitor.png" class="tag-img" />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<video-dialog ref="videoDlg"></video-dialog>
|
<video-dialog ref="videoDlg"></video-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -164,7 +164,10 @@ export default {
|
||||||
|
|
||||||
resolve(nd);
|
resolve(nd);
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
document.querySelectorAll(".bim-roaming .model-tree .el-tree-node")[0].click();
|
let els = document.querySelectorAll(".bim-roaming .model-tree .el-tree-node");
|
||||||
|
if (els.length > 0) {
|
||||||
|
els[0].click();
|
||||||
|
}
|
||||||
}, 1000);
|
}, 1000);
|
||||||
} else if (node.level == 1) {
|
} else if (node.level == 1) {
|
||||||
let nd = [];
|
let nd = [];
|
||||||
|
|
|
@ -767,7 +767,6 @@ export default {
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
console.log(option)
|
|
||||||
return option
|
return option
|
||||||
},
|
},
|
||||||
renderChart7() {
|
renderChart7() {
|
||||||
|
|
Loading…
Reference in New Issue