Initial import of NODEDC BIM Viewer
This commit is contained in:
@@ -0,0 +1,92 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Title</title>
|
||||
|
||||
<style>
|
||||
|
||||
html, body {
|
||||
height: 100%;
|
||||
background: #f2f2f2;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 1.50;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.column {
|
||||
float: left;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.row:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
iframe {
|
||||
width: 100%;
|
||||
height: 800px;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body onload="init()">
|
||||
|
||||
<script>
|
||||
|
||||
function init() {
|
||||
|
||||
const iframeBaseURL = "./../app/index.html?projectId=Systhema&modelId=170133_Asvest_20200131";
|
||||
|
||||
const iframeElement = document.getElementById("embeddedViewer");
|
||||
if (!iframeElement) {
|
||||
throw "IFRAME not found";
|
||||
}
|
||||
|
||||
iframeElement.src = iframeBaseURL;
|
||||
|
||||
const objectIdsUsed = {};
|
||||
|
||||
window.selectObject = function (checkbox) {
|
||||
|
||||
const objectId = checkbox.name;
|
||||
|
||||
if (checkbox.checked) {
|
||||
objectIdsUsed[objectId] = true;
|
||||
} else {
|
||||
delete objectIdsUsed[objectId];
|
||||
}
|
||||
|
||||
const objectIds = Object.keys(objectIdsUsed);
|
||||
|
||||
if (objectIds.length === 0) {
|
||||
iframeElement.src = iframeBaseURL + "#actions=clearFocusObjects";
|
||||
} else {
|
||||
const objectIdsParam = objectIds.join(",");
|
||||
iframeElement.src = iframeBaseURL + "#actions=focusObjects,openTab&objectIds=" + objectIdsParam + "&tabId=objects";
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<ul>
|
||||
<li><input type="checkbox" name="0FazZzVxL0ZAC2Xz9Lc_VS" onclick="javascript:selectObject(this)">Focus object
|
||||
"0FazZzVxL0ZAC2Xz9Lc_VS"</input></li>
|
||||
<li><input type="checkbox" name="12NjfiY$5BWxO3cGvRvhMM" onclick="javascript:selectObject(this)">Focus object
|
||||
"12NjfiY$5BWxO3cGvRvhMM"</input></li>
|
||||
</ul>
|
||||
<iframe id="embeddedViewer"></iframe>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user