|
@@ -145,23 +145,29 @@ export default {
|
|
that.views[key].scene = null;
|
|
that.views[key].scene = null;
|
|
that.scenes[key] = null;
|
|
that.scenes[key] = null;
|
|
//类型
|
|
//类型
|
|
- if (typecode == 'Eq' || typecode == 'Ec')
|
|
|
|
|
|
+ if (typecode == 'Eq' || typecode == 'Ec') {
|
|
that.scenes[key] = new LocationPointScene();
|
|
that.scenes[key] = new LocationPointScene();
|
|
- else if (typecode == 'Sp')
|
|
|
|
|
|
+ }
|
|
|
|
+ else if (typecode == 'Sp') {
|
|
that.scenes[key] = new DivideFloorScene();
|
|
that.scenes[key] = new DivideFloorScene();
|
|
- else
|
|
|
|
|
|
+ }
|
|
|
|
+ else {
|
|
that.scenes[key] = null;
|
|
that.scenes[key] = null;
|
|
|
|
+ }
|
|
if (res2.Content[0].StructureInfo && res2.Content[0].StructureInfo.FloorMap) {
|
|
if (res2.Content[0].StructureInfo && res2.Content[0].StructureInfo.FloorMap) {
|
|
//获取数据,并加载canvas
|
|
//获取数据,并加载canvas
|
|
that.scenes[key].loadUrl(`/image-service/common/file_get?systemId=revit&key=${res2.Content[0].StructureInfo.FloorMap}`).then(() => {
|
|
that.scenes[key].loadUrl(`/image-service/common/file_get?systemId=revit&key=${res2.Content[0].StructureInfo.FloorMap}`).then(() => {
|
|
that.views[key].scene = that.scenes[key];
|
|
that.views[key].scene = that.scenes[key];
|
|
that.scenes[key].isSpaceSelectable = false;
|
|
that.scenes[key].isSpaceSelectable = false;
|
|
- if (typecode == 'Eq' || typecode == 'Ec')
|
|
|
|
|
|
+ if (typecode == 'Eq' || typecode == 'Ec') {
|
|
that.scenes[key].addMarker(options);
|
|
that.scenes[key].addMarker(options);
|
|
- else if (typecode == 'Sp')
|
|
|
|
|
|
+ }
|
|
|
|
+ else if (typecode == 'Sp') {
|
|
that.scenes[key].addZone(options);
|
|
that.scenes[key].addZone(options);
|
|
- else
|
|
|
|
- ;
|
|
|
|
|
|
+ }
|
|
|
|
+ else {
|
|
|
|
+
|
|
|
|
+ }
|
|
that.views[key].fitSceneToView();
|
|
that.views[key].fitSceneToView();
|
|
})
|
|
})
|
|
}
|
|
}
|