fanghuisheng 3 years ago
parent
commit
4cafa8bc3a
97 changed files with 3149 additions and 64 deletions
  1. 0 0
      2021.08.09/011-2_材料设备清单.xlsx
  2. 0 0
      2021.08.09/ChangeScene.js
  3. 0 0
      2021.08.09/CreateHtml.js
  4. 0 0
      2021.08.09/FloorClick.js
  5. 0 0
      2021.08.09/Jsons/中原路28弄11号.json
  6. 0 0
      2021.08.09/Jsons/中原路28弄12号.json
  7. 0 0
      2021.08.09/Jsons/中原路28弄1号.json
  8. 0 0
      2021.08.09/Jsons/中原路28弄2号.json
  9. 0 0
      2021.08.09/Jsons/中原路28弄3号.json
  10. 0 0
      2021.08.09/Jsons/中原路28弄4号.json
  11. 0 0
      2021.08.09/Jsons/中环和润苑10号.json
  12. 0 0
      2021.08.09/Jsons/中环和润苑12号.json
  13. 0 0
      2021.08.09/Jsons/中环和润苑13号.json
  14. 0 0
      2021.08.09/Jsons/中环和润苑15号.json
  15. 0 0
      2021.08.09/Jsons/中环和润苑16号.json
  16. 0 0
      2021.08.09/Jsons/中环和润苑17号.json
  17. 0 0
      2021.08.09/Jsons/中环和润苑18号.json
  18. 0 0
      2021.08.09/Jsons/中环和润苑19号.json
  19. 0 0
      2021.08.09/Jsons/中环和润苑20号.json
  20. 0 0
      2021.08.09/Jsons/中环和润苑3号.json
  21. 0 0
      2021.08.09/Jsons/中环和润苑4号.json
  22. 0 0
      2021.08.09/Jsons/中环和润苑6号.json
  23. 0 0
      2021.08.09/Jsons/中环和润苑7号.json
  24. 0 0
      2021.08.09/Jsons/中环和润苑9号.json
  25. 0 0
      2021.08.09/Jsons/同济北苑12号.json
  26. 0 0
      2021.08.09/Jsons/同济北苑13号.json
  27. 0 0
      2021.08.09/Jsons/同济北苑14号.json
  28. 0 0
      2021.08.09/Jsons/同济北苑15号.json
  29. 0 0
      2021.08.09/Jsons/同济北苑16号.json
  30. 0 0
      2021.08.09/Jsons/同济北苑17号.json
  31. 0 0
      2021.08.09/Jsons/同济北苑18号.json
  32. 0 0
      2021.08.09/Jsons/同济北苑19号.json
  33. 0 0
      2021.08.09/Jsons/同济北苑20号.json
  34. 0 0
      2021.08.09/Jsons/同济北苑21号.json
  35. 0 0
      2021.08.09/Jsons/同济北苑22号.json
  36. 0 0
      2021.08.09/Jsons/同济北苑23号.json
  37. 0 0
      2021.08.09/Jsons/同济北苑24号.json
  38. 0 0
      2021.08.09/Jsons/同济北苑25号.json
  39. 0 0
      2021.08.09/Jsons/同济北苑26号.json
  40. 0 0
      2021.08.09/Jsons/同济北苑27号.json
  41. 0 0
      2021.08.09/Jsons/同济北苑28号.json
  42. 0 0
      2021.08.09/Jsons/同济北苑30号.json
  43. 0 0
      2021.08.09/Jsons/同济北苑31号.json
  44. 0 0
      2021.08.09/Jsons/同济北苑32号.json
  45. 0 0
      2021.08.09/Jsons/同济西苑1号.json
  46. 0 0
      2021.08.09/Jsons/同济西苑2号.json
  47. 0 0
      2021.08.09/Jsons/宝钢又一村10号.json
  48. 0 0
      2021.08.09/Jsons/宝钢又一村27号.json
  49. 0 0
      2021.08.09/Jsons/宝钢又一村30号.json
  50. 0 0
      2021.08.09/Jsons/宝钢又一村31号.json
  51. 0 0
      2021.08.09/Jsons/宝钢又一村32号.json
  52. 0 0
      2021.08.09/Jsons/宝钢又一村33号.json
  53. 0 0
      2021.08.09/Jsons/市光二村103号.json
  54. 0 0
      2021.08.09/Jsons/市光二村104号.json
  55. 0 0
      2021.08.09/Jsons/市光二村105号.json
  56. 0 0
      2021.08.09/Jsons/市光二村106号.json
  57. 0 0
      2021.08.09/Jsons/市光二村111号.json
  58. 0 0
      2021.08.09/Jsons/市光二村112号.json
  59. 0 0
      2021.08.09/Jsons/市光二村113号.json
  60. 0 0
      2021.08.09/Jsons/市光二村114号.json
  61. 0 0
      2021.08.09/Jsons/市光二村115号.json
  62. 0 0
      2021.08.09/Jsons/市光二村68号.json
  63. 0 0
      2021.08.09/Jsons/市光二村69号.json
  64. 0 0
      2021.08.09/Jsons/松益公寓311号.json
  65. 0 0
      2021.08.09/Jsons/松益公寓319号.json
  66. 0 0
      2021.08.09/Jsons/浣纱五村2号楼.json
  67. 0 0
      2021.08.09/Jsons/浣纱五村3号楼.json
  68. 0 0
      2021.08.09/Jsons/长华绿苑.json
  69. 0 0
      2021.08.09/Jsons/飞虹路1047弄46号.json
  70. 0 0
      2021.08.09/Jsons/飞虹路1047弄48号.json
  71. 0 0
      2021.08.09/MainPanel.js
  72. 0 0
      2021.08.09/README.md
  73. 0 0
      2021.08.09/UIAnchor.js
  74. 1084 0
      2021.08.09/buildingStore.json
  75. 379 0
      2021.08.09/park.json
  76. 0 0
      2021.08.09/pulic.js
  77. 0 0
      2021.08.09/removeMark.js
  78. 0 0
      2021.08.09/杨浦.js
  79. BIN
      icons/YTRU.png
  80. BIN
      icons/YTWG.png
  81. BIN
      icons/yCR8dP.png
  82. BIN
      icons/yCRGIf.png
  83. BIN
      icons/ySL6MT.png
  84. BIN
      icons/多楼层.png
  85. BIN
      icons/建筑.png
  86. BIN
      icons/透视.png
  87. BIN
      images/op0.png
  88. 54 0
      js/ChangeScene.js
  89. 43 0
      js/CreateHtml.js
  90. 262 0
      js/FloorClick.js
  91. 100 0
      js/MainPanel.js
  92. 270 0
      js/UIAnchor.js
  93. 206 0
      js/public.js
  94. 18 0
      js/removeMark.js
  95. 63 64
      park.json
  96. 21 0
      杨浦16.cps
  97. 649 0
      杨浦16.js

+ 0 - 0
011-2_材料设备清单.xlsx → 2021.08.09/011-2_材料设备清单.xlsx


+ 0 - 0
ChangeScene.js → 2021.08.09/ChangeScene.js


+ 0 - 0
CreateHtml.js → 2021.08.09/CreateHtml.js


+ 0 - 0
FloorClick.js → 2021.08.09/FloorClick.js


+ 0 - 0
Jsons/中原路28弄11号.json → 2021.08.09/Jsons/中原路28弄11号.json


+ 0 - 0
Jsons/中原路28弄12号.json → 2021.08.09/Jsons/中原路28弄12号.json


+ 0 - 0
Jsons/中原路28弄1号.json → 2021.08.09/Jsons/中原路28弄1号.json


+ 0 - 0
Jsons/中原路28弄2号.json → 2021.08.09/Jsons/中原路28弄2号.json


+ 0 - 0
Jsons/中原路28弄3号.json → 2021.08.09/Jsons/中原路28弄3号.json


+ 0 - 0
Jsons/中原路28弄4号.json → 2021.08.09/Jsons/中原路28弄4号.json


+ 0 - 0
Jsons/中环和润苑10号.json → 2021.08.09/Jsons/中环和润苑10号.json


+ 0 - 0
Jsons/中环和润苑12号.json → 2021.08.09/Jsons/中环和润苑12号.json


+ 0 - 0
Jsons/中环和润苑13号.json → 2021.08.09/Jsons/中环和润苑13号.json


+ 0 - 0
Jsons/中环和润苑15号.json → 2021.08.09/Jsons/中环和润苑15号.json


+ 0 - 0
Jsons/中环和润苑16号.json → 2021.08.09/Jsons/中环和润苑16号.json


+ 0 - 0
Jsons/中环和润苑17号.json → 2021.08.09/Jsons/中环和润苑17号.json


+ 0 - 0
Jsons/中环和润苑18号.json → 2021.08.09/Jsons/中环和润苑18号.json


+ 0 - 0
Jsons/中环和润苑19号.json → 2021.08.09/Jsons/中环和润苑19号.json


+ 0 - 0
Jsons/中环和润苑20号.json → 2021.08.09/Jsons/中环和润苑20号.json


+ 0 - 0
Jsons/中环和润苑3号.json → 2021.08.09/Jsons/中环和润苑3号.json


+ 0 - 0
Jsons/中环和润苑4号.json → 2021.08.09/Jsons/中环和润苑4号.json


+ 0 - 0
Jsons/中环和润苑6号.json → 2021.08.09/Jsons/中环和润苑6号.json


+ 0 - 0
Jsons/中环和润苑7号.json → 2021.08.09/Jsons/中环和润苑7号.json


+ 0 - 0
Jsons/中环和润苑9号.json → 2021.08.09/Jsons/中环和润苑9号.json


+ 0 - 0
Jsons/同济北苑12号.json → 2021.08.09/Jsons/同济北苑12号.json


+ 0 - 0
Jsons/同济北苑13号.json → 2021.08.09/Jsons/同济北苑13号.json


+ 0 - 0
Jsons/同济北苑14号.json → 2021.08.09/Jsons/同济北苑14号.json


+ 0 - 0
Jsons/同济北苑15号.json → 2021.08.09/Jsons/同济北苑15号.json


+ 0 - 0
Jsons/同济北苑16号.json → 2021.08.09/Jsons/同济北苑16号.json


+ 0 - 0
Jsons/同济北苑17号.json → 2021.08.09/Jsons/同济北苑17号.json


+ 0 - 0
Jsons/同济北苑18号.json → 2021.08.09/Jsons/同济北苑18号.json


+ 0 - 0
Jsons/同济北苑19号.json → 2021.08.09/Jsons/同济北苑19号.json


+ 0 - 0
Jsons/同济北苑20号.json → 2021.08.09/Jsons/同济北苑20号.json


+ 0 - 0
Jsons/同济北苑21号.json → 2021.08.09/Jsons/同济北苑21号.json


+ 0 - 0
Jsons/同济北苑22号.json → 2021.08.09/Jsons/同济北苑22号.json


+ 0 - 0
Jsons/同济北苑23号.json → 2021.08.09/Jsons/同济北苑23号.json


+ 0 - 0
Jsons/同济北苑24号.json → 2021.08.09/Jsons/同济北苑24号.json


+ 0 - 0
Jsons/同济北苑25号.json → 2021.08.09/Jsons/同济北苑25号.json


+ 0 - 0
Jsons/同济北苑26号.json → 2021.08.09/Jsons/同济北苑26号.json


+ 0 - 0
Jsons/同济北苑27号.json → 2021.08.09/Jsons/同济北苑27号.json


+ 0 - 0
Jsons/同济北苑28号.json → 2021.08.09/Jsons/同济北苑28号.json


+ 0 - 0
Jsons/同济北苑30号.json → 2021.08.09/Jsons/同济北苑30号.json


+ 0 - 0
Jsons/同济北苑31号.json → 2021.08.09/Jsons/同济北苑31号.json


+ 0 - 0
Jsons/同济北苑32号.json → 2021.08.09/Jsons/同济北苑32号.json


+ 0 - 0
Jsons/同济西苑1号.json → 2021.08.09/Jsons/同济西苑1号.json


+ 0 - 0
Jsons/同济西苑2号.json → 2021.08.09/Jsons/同济西苑2号.json


+ 0 - 0
Jsons/宝钢又一村10号.json → 2021.08.09/Jsons/宝钢又一村10号.json


+ 0 - 0
Jsons/宝钢又一村27号.json → 2021.08.09/Jsons/宝钢又一村27号.json


+ 0 - 0
Jsons/宝钢又一村30号.json → 2021.08.09/Jsons/宝钢又一村30号.json


+ 0 - 0
Jsons/宝钢又一村31号.json → 2021.08.09/Jsons/宝钢又一村31号.json


+ 0 - 0
Jsons/宝钢又一村32号.json → 2021.08.09/Jsons/宝钢又一村32号.json


+ 0 - 0
Jsons/宝钢又一村33号.json → 2021.08.09/Jsons/宝钢又一村33号.json


+ 0 - 0
Jsons/市光二村103号.json → 2021.08.09/Jsons/市光二村103号.json


+ 0 - 0
Jsons/市光二村104号.json → 2021.08.09/Jsons/市光二村104号.json


+ 0 - 0
Jsons/市光二村105号.json → 2021.08.09/Jsons/市光二村105号.json


+ 0 - 0
Jsons/市光二村106号.json → 2021.08.09/Jsons/市光二村106号.json


+ 0 - 0
Jsons/市光二村111号.json → 2021.08.09/Jsons/市光二村111号.json


+ 0 - 0
Jsons/市光二村112号.json → 2021.08.09/Jsons/市光二村112号.json


+ 0 - 0
Jsons/市光二村113号.json → 2021.08.09/Jsons/市光二村113号.json


+ 0 - 0
Jsons/市光二村114号.json → 2021.08.09/Jsons/市光二村114号.json


+ 0 - 0
Jsons/市光二村115号.json → 2021.08.09/Jsons/市光二村115号.json


+ 0 - 0
Jsons/市光二村68号.json → 2021.08.09/Jsons/市光二村68号.json


+ 0 - 0
Jsons/市光二村69号.json → 2021.08.09/Jsons/市光二村69号.json


+ 0 - 0
Jsons/松益公寓311号.json → 2021.08.09/Jsons/松益公寓311号.json


+ 0 - 0
Jsons/松益公寓319号.json → 2021.08.09/Jsons/松益公寓319号.json


+ 0 - 0
Jsons/浣纱五村2号楼.json → 2021.08.09/Jsons/浣纱五村2号楼.json


+ 0 - 0
Jsons/浣纱五村3号楼.json → 2021.08.09/Jsons/浣纱五村3号楼.json


+ 0 - 0
Jsons/长华绿苑.json → 2021.08.09/Jsons/长华绿苑.json


+ 0 - 0
Jsons/飞虹路1047弄46号.json → 2021.08.09/Jsons/飞虹路1047弄46号.json


+ 0 - 0
Jsons/飞虹路1047弄48号.json → 2021.08.09/Jsons/飞虹路1047弄48号.json


+ 0 - 0
MainPanel.js → 2021.08.09/MainPanel.js


+ 0 - 0
README.md → 2021.08.09/README.md


+ 0 - 0
UIAnchor.js → 2021.08.09/UIAnchor.js


+ 1084 - 0
2021.08.09/buildingStore.json

@@ -0,0 +1,1084 @@
+{
+    "buildingStore": [
+        {
+            "device_name": "环境监测#1",
+            "dwtype": "YTCI",
+            "max_level": -1,
+            "object_name": "B1层消防水泵房内.环境监测#1",
+            "owner_code": "4023383030323435",
+            "owner_dwtype": 6,
+            "min_level": -1
+        },
+        {
+            "device_name": "环境监测#2",
+            "dwtype": "YTCI",
+            "max_level": -1,
+            "object_name": "B1层消防水泵房内.环境监测#2",
+            "owner_code": "4023383030323435",
+            "owner_dwtype": 6,
+            "min_level": -1
+        },
+        {
+            "device_name": "环境监测#1",
+            "dwtype": "YTCI",
+            "max_level": 1,
+            "object_name": "1楼配电间内.环境监测#1",
+            "owner_code": "4023383030313632",
+            "owner_dwtype": 6,
+            "min_level": 1
+        },
+        {
+            "device_name": "环境监测#2",
+            "dwtype": "YTCI",
+            "max_level": 1,
+            "object_name": "1楼配电间内.环境监测#2",
+            "owner_code": "4023383030313632",
+            "owner_dwtype": 6,
+            "min_level": 1
+        },
+        {
+            "device_name": "1#居民用电电气火灾",
+            "dwtype": "YTEF",
+            "max_level": 1,
+            "object_name": "1层配电间",
+            "owner_code": "00000627020021",
+            "owner_dwtype": 7,
+            "min_level": 1
+        },
+        {
+            "device_name": "电梯电气火灾",
+            "dwtype": "YTEF",
+            "max_level": 1,
+            "object_name": "1层配电间",
+            "owner_code": "00000627020820",
+            "owner_dwtype": 7,
+            "min_level": 1
+        },
+        {
+            "device_name": "公用照明电气火灾",
+            "dwtype": "YTEF",
+            "max_level": 1,
+            "object_name": "1层配电间",
+            "owner_code": "00000627020003",
+            "owner_dwtype": 7,
+            "min_level": 1
+        },
+        {
+            "device_name": "水泵电气火灾",
+            "dwtype": "YTEF",
+            "max_level": 1,
+            "object_name": "1层配电间",
+            "owner_code": "00000627020035",
+            "owner_dwtype": 7,
+            "min_level": 1
+        },
+        {
+            "device_name": "3#居民用电电气火灾",
+            "dwtype": "YTEF",
+            "max_level": 3,
+            "object_name": "1层配电间",
+            "owner_code": "00000627020010",
+            "owner_dwtype": 7,
+            "min_level": 3
+        },
+        {
+            "device_name": "2#居民用电电气火灾",
+            "dwtype": "YTEF",
+            "max_level": 2,
+            "object_name": "1层配电间",
+            "owner_code": "00000627020025",
+            "owner_dwtype": 7,
+            "min_level": 2
+        },
+        {
+            "device_name": "消防控制柜",
+            "dwtype": "YTFC",
+            "max_level": -1,
+            "object_name": "B1层消防水泵房内.消防控制柜",
+            "owner_code": "4023383030323435",
+            "owner_dwtype": 6,
+            "min_level": -1
+        },
+        {
+            "device_name": "屋顶消防水箱液位",
+            "dwtype": "YTLL",
+            "max_level": 19,
+            "object_name": "屋顶水箱",
+            "owner_code": "864016054803367",
+            "owner_dwtype": 5,
+            "min_level": 19
+        },
+        {
+            "device_name": "地下消防水池液位",
+            "dwtype": "YTLL",
+            "max_level": -1,
+            "object_name": "B1楼消防水泵房",
+            "owner_code": "864016054787602",
+            "owner_dwtype": 5,
+            "min_level": -1
+        },
+        {
+            "device_name": "18楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 18,
+            "object_name": "市光二村112号楼18楼",
+            "owner_code": "70B3D53AF00F39FB",
+            "owner_dwtype": 3,
+            "min_level": 18
+        },
+        {
+            "device_name": "18楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 18,
+            "object_name": "市光二村112号楼18楼",
+            "owner_code": "70B3D53AF00F390B",
+            "owner_dwtype": 3,
+            "min_level": 18
+        },
+        {
+            "device_name": "18楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 18,
+            "object_name": "市光二村112号楼18楼",
+            "owner_code": "70B3D53AF00F39F2",
+            "owner_dwtype": 3,
+            "min_level": 18
+        },
+        {
+            "device_name": "18楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 18,
+            "object_name": "市光二村112号楼18楼",
+            "owner_code": "70B3D53AF00F3977",
+            "owner_dwtype": 3,
+            "min_level": 18
+        },
+        {
+            "device_name": "17楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 17,
+            "object_name": "市光二村112号楼17楼",
+            "owner_code": "70B3D53AF00F3744",
+            "owner_dwtype": 3,
+            "min_level": 17
+        },
+        {
+            "device_name": "17楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 17,
+            "object_name": "市光二村112号楼17楼",
+            "owner_code": "70B3D53AF00F373D",
+            "owner_dwtype": 3,
+            "min_level": 17
+        },
+        {
+            "device_name": "17楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 17,
+            "object_name": "市光二村112号楼17楼",
+            "owner_code": "70B3D53AF00F3776",
+            "owner_dwtype": 3,
+            "min_level": 17
+        },
+        {
+            "device_name": "17楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 17,
+            "object_name": "市光二村112号楼17楼",
+            "owner_code": "70B3D53AF00F372D",
+            "owner_dwtype": 3,
+            "min_level": 17
+        },
+        {
+            "device_name": "16楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 16,
+            "object_name": "市光二村112号楼16楼",
+            "owner_code": "70B3D53AF00F37CB",
+            "owner_dwtype": 3,
+            "min_level": 16
+        },
+        {
+            "device_name": "16楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 16,
+            "object_name": "市光二村112号楼16楼",
+            "owner_code": "70B3D53AF00F37CB",
+            "owner_dwtype": 3,
+            "min_level": 16
+        },
+        {
+            "device_name": "16楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 16,
+            "object_name": "市光二村112号楼16楼",
+            "owner_code": "70B3D53AF00F3705",
+            "owner_dwtype": 3,
+            "min_level": 16
+        },
+        {
+            "device_name": "16楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 16,
+            "object_name": "市光二村112号楼16楼",
+            "owner_code": "70B3D53AF00F3728",
+            "owner_dwtype": 3,
+            "min_level": 16
+        },
+        {
+            "device_name": "16楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 16,
+            "object_name": "市光二村112号楼16楼",
+            "owner_code": "70B3D53AF00F3713",
+            "owner_dwtype": 3,
+            "min_level": 16
+        },
+        {
+            "device_name": "15楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 15,
+            "object_name": "市光二村112号楼15楼",
+            "owner_code": "70B3D53AF00F37D7",
+            "owner_dwtype": 3,
+            "min_level": 15
+        },
+        {
+            "device_name": "15楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 15,
+            "object_name": "市光二村112号楼15楼",
+            "owner_code": "70B3D53AF00F3846",
+            "owner_dwtype": 3,
+            "min_level": 15
+        },
+        {
+            "device_name": "15楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 15,
+            "object_name": "市光二村112号楼15楼",
+            "owner_code": "70B3D53AF00F37C4",
+            "owner_dwtype": 3,
+            "min_level": 15
+        },
+        {
+            "device_name": "15楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 15,
+            "object_name": "市光二村112号楼15楼",
+            "owner_code": "70B3D53AF00F37D8",
+            "owner_dwtype": 3,
+            "min_level": 15
+        },
+        {
+            "device_name": "14楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 14,
+            "object_name": "市光二村112号楼14楼",
+            "owner_code": "70B3D53AF00F3711",
+            "owner_dwtype": 3,
+            "min_level": 14
+        },
+        {
+            "device_name": "14楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 14,
+            "object_name": "市光二村112号楼14楼",
+            "owner_code": "70B3D53AF00F3858",
+            "owner_dwtype": 3,
+            "min_level": 14
+        },
+        {
+            "device_name": "14楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 14,
+            "object_name": "市光二村112号楼14楼",
+            "owner_code": "70B3D53AF00F37B3",
+            "owner_dwtype": 3,
+            "min_level": 14
+        },
+        {
+            "device_name": "14楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 14,
+            "object_name": "市光二村112号楼14楼",
+            "owner_code": "70B3D53AF00F37AA",
+            "owner_dwtype": 3,
+            "min_level": 14
+        },
+        {
+            "device_name": "13楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 13,
+            "object_name": "市光二村112号楼13楼",
+            "owner_code": "70B3D53AF00F379D",
+            "owner_dwtype": 3,
+            "min_level": 13
+        },
+        {
+            "device_name": "13楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 13,
+            "object_name": "市光二村112号楼13楼",
+            "owner_code": "70B3D53AF00F3740",
+            "owner_dwtype": 3,
+            "min_level": 13
+        },
+        {
+            "device_name": "13楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 13,
+            "object_name": "市光二村112号楼13楼",
+            "owner_code": "70B3D53AF00F379C",
+            "owner_dwtype": 3,
+            "min_level": 13
+        },
+        {
+            "device_name": "13楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 13,
+            "object_name": "市光二村112号楼13楼",
+            "owner_code": "70B3D53AF00F37BB",
+            "owner_dwtype": 3,
+            "min_level": 13
+        },
+        {
+            "device_name": "12楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 12,
+            "object_name": "市光二村112号楼12楼",
+            "owner_code": "70B3D53AF00F37CE",
+            "owner_dwtype": 3,
+            "min_level": 12
+        },
+        {
+            "device_name": "12楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 12,
+            "object_name": "市光二村112号楼12楼",
+            "owner_code": "70B3D53AF00F37F4",
+            "owner_dwtype": 3,
+            "min_level": 12
+        },
+        {
+            "device_name": "12楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 12,
+            "object_name": "市光二村112号楼12楼",
+            "owner_code": "70B3D53AF00F3732",
+            "owner_dwtype": 3,
+            "min_level": 12
+        },
+        {
+            "device_name": "12楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 12,
+            "object_name": "市光二村112号楼12楼",
+            "owner_code": "70B3D53AF00F379A",
+            "owner_dwtype": 3,
+            "min_level": 12
+        },
+        {
+            "device_name": "11楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 11,
+            "object_name": "市光二村112号楼11楼",
+            "owner_code": "70B3D53AF00F3723",
+            "owner_dwtype": 3,
+            "min_level": 11
+        },
+        {
+            "device_name": "11楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 11,
+            "object_name": "市光二村112号楼11楼",
+            "owner_code": "70B3D53AF00F373C",
+            "owner_dwtype": 3,
+            "min_level": 11
+        },
+        {
+            "device_name": "11楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 11,
+            "object_name": "市光二村112号楼11楼",
+            "owner_code": "70B3D53AF00F3742",
+            "owner_dwtype": 3,
+            "min_level": 11
+        },
+        {
+            "device_name": "11楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 11,
+            "object_name": "市光二村112号楼11楼",
+            "owner_code": "70B3D53AF00F371A",
+            "owner_dwtype": 3,
+            "min_level": 11
+        },
+        {
+            "device_name": "10楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 10,
+            "object_name": "市光二村112号楼10楼",
+            "owner_code": "70B3D53AF00F37D9",
+            "owner_dwtype": 3,
+            "min_level": 10
+        },
+        {
+            "device_name": "10楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 10,
+            "object_name": "市光二村112号楼10楼",
+            "owner_code": "70B3D53AF00F37BF",
+            "owner_dwtype": 3,
+            "min_level": 10
+        },
+        {
+            "device_name": "10楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 10,
+            "object_name": "市光二村112号楼10楼",
+            "owner_code": "70B3D53AF00F3881",
+            "owner_dwtype": 3,
+            "min_level": 10
+        },
+        {
+            "device_name": "10楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 10,
+            "object_name": "市光二村112号楼10楼",
+            "owner_code": "70B3D53AF00F374E",
+            "owner_dwtype": 3,
+            "min_level": 10
+        },
+        {
+            "device_name": "9楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 9,
+            "object_name": "市光二村112号楼9楼",
+            "owner_code": "70B3D53AF00F37C1",
+            "owner_dwtype": 3,
+            "min_level": 9
+        },
+        {
+            "device_name": "9楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 9,
+            "object_name": "市光二村112号楼9楼",
+            "owner_code": "70B3D53AF00F37A3",
+            "owner_dwtype": 3,
+            "min_level": 9
+        },
+        {
+            "device_name": "9楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 9,
+            "object_name": "市光二村112号楼9楼",
+            "owner_code": "70B3D53AF00F3741",
+            "owner_dwtype": 3,
+            "min_level": 9
+        },
+        {
+            "device_name": "9楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 9,
+            "object_name": "市光二村112号楼9楼",
+            "owner_code": "70B3D53AF00F37B4",
+            "owner_dwtype": 3,
+            "min_level": 9
+        },
+        {
+            "device_name": "8楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 8,
+            "object_name": "市光二村112号楼8楼",
+            "owner_code": "70B3D53AF00F3859",
+            "owner_dwtype": 3,
+            "min_level": 8
+        },
+        {
+            "device_name": "8楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 8,
+            "object_name": "市光二村112号楼8楼",
+            "owner_code": "70B3D53AF00F372A",
+            "owner_dwtype": 3,
+            "min_level": 8
+        },
+        {
+            "device_name": "8楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 8,
+            "object_name": "市光二村112号楼8楼",
+            "owner_code": "70B3D53AF00F3857",
+            "owner_dwtype": 3,
+            "min_level": 8
+        },
+        {
+            "device_name": "8楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 8,
+            "object_name": "市光二村112号楼8楼",
+            "owner_code": "70B3D53AF00F379F",
+            "owner_dwtype": 3,
+            "min_level": 8
+        },
+        {
+            "device_name": "7楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 7,
+            "object_name": "市光二村112号楼7楼",
+            "owner_code": "70B3D53AF00F37CB",
+            "owner_dwtype": 3,
+            "min_level": 7
+        },
+        {
+            "device_name": "7楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 7,
+            "object_name": "市光二村112号楼7楼",
+            "owner_code": "70B3D53AF00F37CB",
+            "owner_dwtype": 3,
+            "min_level": 7
+        },
+        {
+            "device_name": "7楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 7,
+            "object_name": "市光二村112号楼7楼",
+            "owner_code": "70B3D53AF00F3719",
+            "owner_dwtype": 3,
+            "min_level": 7
+        },
+        {
+            "device_name": "7楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 7,
+            "object_name": "市光二村112号楼7楼",
+            "owner_code": "70B3D53AF00F371E",
+            "owner_dwtype": 3,
+            "min_level": 7
+        },
+        {
+            "device_name": "7楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 7,
+            "object_name": "市光二村112号楼7楼",
+            "owner_code": "70B3D53AF00F3717",
+            "owner_dwtype": 3,
+            "min_level": 7
+        },
+        {
+            "device_name": "6楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 6,
+            "object_name": "市光二村112号楼6楼",
+            "owner_code": "70B3D53AF00F379E",
+            "owner_dwtype": 3,
+            "min_level": 6
+        },
+        {
+            "device_name": "6楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 6,
+            "object_name": "市光二村112号楼6楼",
+            "owner_code": "70B3D53AF00F37B8",
+            "owner_dwtype": 3,
+            "min_level": 6
+        },
+        {
+            "device_name": "6楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 6,
+            "object_name": "市光二村112号楼6楼",
+            "owner_code": "70B3D53AF00F373E",
+            "owner_dwtype": 3,
+            "min_level": 6
+        },
+        {
+            "device_name": "6楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 6,
+            "object_name": "市光二村112号楼6楼",
+            "owner_code": "70B3D53AF00F3725",
+            "owner_dwtype": 3,
+            "min_level": 6
+        },
+        {
+            "device_name": "5楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 5,
+            "object_name": "市光二村112号楼5楼",
+            "owner_code": "70B3D53AF00F3734",
+            "owner_dwtype": 3,
+            "min_level": 5
+        },
+        {
+            "device_name": "5楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 5,
+            "object_name": "市光二村112号楼5楼",
+            "owner_code": "70B3D53AF00F370D",
+            "owner_dwtype": 3,
+            "min_level": 5
+        },
+        {
+            "device_name": "5楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 5,
+            "object_name": "市光二村112号楼5楼",
+            "owner_code": "70B3D53AF00F37C3",
+            "owner_dwtype": 3,
+            "min_level": 5
+        },
+        {
+            "device_name": "5楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 5,
+            "object_name": "市光二村112号楼5楼",
+            "owner_code": "70B3D53AF00F37BE",
+            "owner_dwtype": 3,
+            "min_level": 5
+        },
+        {
+            "device_name": "4楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 4,
+            "object_name": "市光二村112号楼4楼",
+            "owner_code": "70B3D53AF00F3704",
+            "owner_dwtype": 3,
+            "min_level": 4
+        },
+        {
+            "device_name": "4楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 4,
+            "object_name": "市光二村112号楼4楼",
+            "owner_code": "70B3D53AF00F377B",
+            "owner_dwtype": 3,
+            "min_level": 4
+        },
+        {
+            "device_name": "4楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 4,
+            "object_name": "市光二村112号楼4楼",
+            "owner_code": "70B3D53AF00F383E",
+            "owner_dwtype": 3,
+            "min_level": 4
+        },
+        {
+            "device_name": "4楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 4,
+            "object_name": "市光二村112号楼4楼",
+            "owner_code": "70B3D53AF00F3736",
+            "owner_dwtype": 3,
+            "min_level": 4
+        },
+        {
+            "device_name": "3楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 3,
+            "object_name": "市光二村112号楼3楼",
+            "owner_code": "70B3D53AF00F37D5",
+            "owner_dwtype": 3,
+            "min_level": 3
+        },
+        {
+            "device_name": "3楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 3,
+            "object_name": "市光二村112号楼3楼",
+            "owner_code": "70B3D53AF00F3753",
+            "owner_dwtype": 3,
+            "min_level": 3
+        },
+        {
+            "device_name": "3楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 3,
+            "object_name": "市光二村112号楼3楼",
+            "owner_code": "70B3D53AF00F37CC",
+            "owner_dwtype": 3,
+            "min_level": 3
+        },
+        {
+            "device_name": "3楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 3,
+            "object_name": "市光二村112号楼3楼",
+            "owner_code": "70B3D53AF00F36FE",
+            "owner_dwtype": 3,
+            "min_level": 3
+        },
+        {
+            "device_name": "2楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 2,
+            "object_name": "市光二村112号楼2楼",
+            "owner_code": "70B3D53AF00F3745",
+            "owner_dwtype": 3,
+            "min_level": 2
+        },
+        {
+            "device_name": "2楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 2,
+            "object_name": "市光二村112号楼2楼",
+            "owner_code": "70B3D53AF00F385B",
+            "owner_dwtype": 3,
+            "min_level": 2
+        },
+        {
+            "device_name": "2楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 2,
+            "object_name": "市光二村112号楼2楼",
+            "owner_code": "70B3D53AF00F3733",
+            "owner_dwtype": 3,
+            "min_level": 2
+        },
+        {
+            "device_name": "2楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 2,
+            "object_name": "市光二村112号楼2楼",
+            "owner_code": "70B3D53AF00F37AB",
+            "owner_dwtype": 3,
+            "min_level": 2
+        },
+        {
+            "device_name": "1楼1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 1,
+            "object_name": "市光二村112号楼1楼",
+            "owner_code": "70B3D53AF00F37CA",
+            "owner_dwtype": 3,
+            "min_level": 1
+        },
+        {
+            "device_name": "1楼2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 1,
+            "object_name": "市光二村112号楼1楼",
+            "owner_code": "70B3D53AF00F37A7",
+            "owner_dwtype": 3,
+            "min_level": 1
+        },
+        {
+            "device_name": "1楼3#烟感",
+            "dwtype": "YTSM",
+            "max_level": 1,
+            "object_name": "市光二村112号楼1楼",
+            "owner_code": "70B3D53AF00F3710",
+            "owner_dwtype": 3,
+            "min_level": 1
+        },
+        {
+            "device_name": "1楼4#烟感",
+            "dwtype": "YTSM",
+            "max_level": 1,
+            "object_name": "市光二村112号楼1楼",
+            "owner_code": "70B3D53AF00F3785",
+            "owner_dwtype": 3,
+            "min_level": 1
+        },
+        {
+            "device_name": "1楼配电间1#烟感",
+            "dwtype": "YTSM",
+            "max_level": 1,
+            "object_name": "市光二村112号楼1楼配电间",
+            "owner_code": "70B3D53AF00F3911",
+            "owner_dwtype": 3,
+            "min_level": 1
+        },
+        {
+            "device_name": "1楼配电间2#烟感",
+            "dwtype": "YTSM",
+            "max_level": 1,
+            "object_name": "市光二村112号楼1楼配电间",
+            "owner_code": "70B3D53AF00F3B81",
+            "owner_dwtype": 3,
+            "min_level": 1
+        },
+        {
+            "device_name": "B1楼水泵房1#烟感",
+            "dwtype": "YTSM",
+            "max_level": -1,
+            "object_name": "市光二村112号楼B1楼水泵房",
+            "owner_code": "70B3D53AF00F3912",
+            "owner_dwtype": 3,
+            "min_level": -1
+        },
+        {
+            "device_name": "B1楼水泵房2#烟感",
+            "dwtype": "YTSM",
+            "max_level": -1,
+            "object_name": "市光二村112号楼B1楼水泵房",
+            "owner_code": "70B3D53AF00F395F",
+            "owner_dwtype": 3,
+            "min_level": -1
+        },
+        {
+            "device_name": "占道摄像机",
+            "dwtype": "YTVA",
+            "max_level": 1,
+            "object_name": "1楼电梯厅",
+            "owner_code": "SGEC112DTTZD",
+            "owner_dwtype": 16,
+            "min_level": 1
+        },
+        {
+            "device_name": "占道摄像机",
+            "dwtype": "YTVA",
+            "max_level": 1,
+            "object_name": "1楼大堂内",
+            "owner_code": "SGEC112DTZD",
+            "owner_dwtype": 16,
+            "min_level": 1
+        },
+        {
+            "device_name": "火点侦测摄像机",
+            "dwtype": "YTVA",
+            "max_level": 1,
+            "object_name": "1楼配电间内",
+            "owner_code": "SGEC112PDJ",
+            "owner_dwtype": 16,
+            "min_level": 1
+        },
+        {
+            "device_name": "火点侦测摄像机",
+            "dwtype": "YTVA",
+            "max_level": -1,
+            "object_name": "B1层消防水泵房内",
+            "owner_code": "SGEC112SBF",
+            "owner_dwtype": 16,
+            "min_level": -1
+        },
+        {
+            "device_name": "占道摄像机",
+            "dwtype": "YTVA",
+            "max_level": 1,
+            "object_name": "1楼大堂内",
+            "owner_code": "SGEC112DTZD2",
+            "owner_dwtype": 16,
+            "min_level": 1
+        },
+        {
+            "device_name": "水浸监测#1",
+            "dwtype": "YTWI",
+            "max_level": -1,
+            "object_name": "B1层消防水泵房内.水浸监测#1",
+            "owner_code": "4023383030323435",
+            "owner_dwtype": 6,
+            "min_level": -1
+        },
+        {
+            "device_name": "水浸监测#2",
+            "dwtype": "YTWI",
+            "max_level": -1,
+            "object_name": "B1层消防水泵房内.水浸监测#2",
+            "owner_code": "4023383030323435",
+            "owner_dwtype": 6,
+            "min_level": -1
+        },
+        {
+            "device_name": "水浸监测#1",
+            "dwtype": "YTWI",
+            "max_level": 1,
+            "object_name": "1楼配电间内.水浸监测#1",
+            "owner_code": "4023383030313632",
+            "owner_dwtype": 6,
+            "min_level": 1
+        },
+        {
+            "device_name": "水浸监测#2",
+            "dwtype": "YTWI",
+            "max_level": 1,
+            "object_name": "1楼配电间内.水浸监测#2",
+            "owner_code": "4023383030313632",
+            "owner_dwtype": 6,
+            "min_level": 1
+        },
+        {
+            "device_name": "1楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 1,
+            "object_name": "1楼喷淋末端",
+            "owner_code": "864016058661274",
+            "owner_dwtype": 2,
+            "min_level": 1
+        },
+        {
+            "device_name": "2楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 2,
+            "object_name": "2楼喷淋末端",
+            "owner_code": "864016058782260",
+            "owner_dwtype": 2,
+            "min_level": 2
+        },
+        {
+            "device_name": "3楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 3,
+            "object_name": "3楼喷淋末端",
+            "owner_code": "864016058616047",
+            "owner_dwtype": 2,
+            "min_level": 3
+        },
+        {
+            "device_name": "4楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 4,
+            "object_name": "4楼喷淋末端",
+            "owner_code": "864016058672164",
+            "owner_dwtype": 2,
+            "min_level": 4
+        },
+        {
+            "device_name": "5楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 5,
+            "object_name": "5楼喷淋末端",
+            "owner_code": "864016058675044",
+            "owner_dwtype": 2,
+            "min_level": 5
+        },
+        {
+            "device_name": "6楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 6,
+            "object_name": "6楼喷淋末端",
+            "owner_code": "864016058540072",
+            "owner_dwtype": 2,
+            "min_level": 6
+        },
+        {
+            "device_name": "7楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 7,
+            "object_name": "7楼喷淋末端",
+            "owner_code": "864016058862344",
+            "owner_dwtype": 2,
+            "min_level": 7
+        },
+        {
+            "device_name": "8楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 8,
+            "object_name": "8楼喷淋末端",
+            "owner_code": "864016058854036",
+            "owner_dwtype": 2,
+            "min_level": 8
+        },
+        {
+            "device_name": "9楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 9,
+            "object_name": "9楼喷淋末端",
+            "owner_code": "864016058661282",
+            "owner_dwtype": 2,
+            "min_level": 9
+        },
+        {
+            "device_name": "10楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 10,
+            "object_name": "10楼喷淋末端",
+            "owner_code": "864016058620502",
+            "owner_dwtype": 2,
+            "min_level": 10
+        },
+        {
+            "device_name": "11楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 11,
+            "object_name": "11楼喷淋末端",
+            "owner_code": "864016058753725",
+            "owner_dwtype": 2,
+            "min_level": 11
+        },
+        {
+            "device_name": "12楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 12,
+            "object_name": "12楼喷淋末端",
+            "owner_code": "864016058651853",
+            "owner_dwtype": 2,
+            "min_level": 12
+        },
+        {
+            "device_name": "13楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 13,
+            "object_name": "13楼喷淋末端",
+            "owner_code": "864016058621799",
+            "owner_dwtype": 2,
+            "min_level": 13
+        },
+        {
+            "device_name": "14楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 14,
+            "object_name": "14楼喷淋末端",
+            "owner_code": "864016058671950",
+            "owner_dwtype": 2,
+            "min_level": 14
+        },
+        {
+            "device_name": "15楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 15,
+            "object_name": "15楼喷淋末端",
+            "owner_code": "864016058863169",
+            "owner_dwtype": 2,
+            "min_level": 15
+        },
+        {
+            "device_name": "16楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 16,
+            "object_name": "16楼喷淋末端",
+            "owner_code": "864016058618688",
+            "owner_dwtype": 2,
+            "min_level": 16
+        },
+        {
+            "device_name": "17楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 17,
+            "object_name": "17楼喷淋末端",
+            "owner_code": "864016058792145",
+            "owner_dwtype": 2,
+            "min_level": 17
+        },
+        {
+            "device_name": "18楼喷淋末端水压",
+            "dwtype": "YTWP",
+            "max_level": 18,
+            "object_name": "18楼喷淋末端",
+            "owner_code": "864016058616716",
+            "owner_dwtype": 2,
+            "min_level": 18
+        },
+        {
+            "device_name": "喷淋泵主管水压",
+            "dwtype": "YTWP",
+            "max_level": -1,
+            "object_name": "B1楼消防水泵房",
+            "owner_code": "864016058542789",
+            "owner_dwtype": 2,
+            "min_level": -1
+        },
+        {
+            "device_name": "消防泵主管水压",
+            "dwtype": "YTWP",
+            "max_level": -1,
+            "object_name": "B1楼消防水泵房",
+            "owner_code": "864016058794778",
+            "owner_dwtype": 2,
+            "min_level": -1
+        }
+    ]
+}

+ 379 - 0
2021.08.09/park.json

@@ -0,0 +1,379 @@
+{
+    "array":[
+        {
+            "id":"10309",
+            "name":"建信大厦",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10308",
+            "name":"公安大厦",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10307",
+            "name":"城科大楼",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10306",
+            "name":"同济北苑29号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10305",
+            "name":"同济北苑33号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10304",
+            "name":"同济北苑32号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10303",
+            "name":"同济北苑31号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10302",
+            "name":"同济北苑30号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10301",
+            "name":"同济北苑27号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10300",
+            "name":"同济北苑28号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10299",
+            "name":"同济北苑26号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10298",
+            "name":"同济北苑24号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10297",
+            "name":"宝钢又一村33号",
+            "url":"/api/scene/23f6906b59c24fec7d817f1c"
+        },
+        {
+            "id":"10296",
+            "name":"宝钢又一村32号",
+            "url":"/api/scene/7e9157bb863767353e7d0403"
+        },
+        {
+            "id":"10295",
+            "name":"宝钢又一村31号",
+            "url":"/api/scene/8fe9eaf0118f74c71010bc19"
+        },
+        {
+            "id":"10294",
+            "name":"宝钢又一村30号",
+            "url":"/api/scene/8d41c52f5b73d5806e6003ea"
+        },
+        {
+            "id":"10293",
+            "name":"宝钢又一村27号",
+            "url":"/api/scene/b601a0725de07365a182bc9b"
+        },
+        {
+            "id":"10292",
+            "name":"宝钢又一村10号",
+            "url":"/api/scene/2a41884954252c579b2b2175"
+        },
+        {
+            "id":"10291",
+            "name":"同济北苑23号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10290",
+            "name":"同济北苑22号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10289",
+            "name":"同济北苑21号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10288",
+            "name":"飞虹路1047弄48号",
+            "url":"/api/scene/75adb5e6eeddb28762570454"
+        },
+        {
+            "id":"10287",
+            "name":"飞虹路1047弄46号",
+            "url":"/api/scene/2463314c97dda1bf58be11c3"
+        },
+        {
+            "id":"10286",
+            "name":"同济北苑20号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10285",
+            "name":"同济北苑19号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10284",
+            "name":"同济北苑18号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10283",
+            "name":"同济北苑17号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10282",
+            "name":"同济西苑2号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10281",
+            "name":"同济西苑1号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10280",
+            "name":"同济北苑16号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10279",
+            "name":"同济北苑15号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10278",
+            "name":"同济北苑14号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10277",
+            "name":"同济北苑13号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10276",
+            "name":"同济北苑12号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10275",
+            "name":"中原路28弄12号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10274",
+            "name":"中原路28弄11号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10273",
+            "name":"翔殷消防大楼",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10272",
+            "name":"贵人大厦",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10271",
+            "name":"中原路28弄4号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10270",
+            "name":"中原路28弄3号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10269",
+            "name":"中原路28弄2号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10268",
+            "name":"中原路28弄1号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10267",
+            "name":"松益公寓319号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10266",
+            "name":"松益公寓311号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10265",
+            "name":"浣纱五村3号楼",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10264",
+            "name":"浣纱五村2号楼",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10263",
+            "name":"中环和润苑20号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10262",
+            "name":"中环和润苑19号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10261",
+            "name":"中环和润苑18号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10260",
+            "name":"中环和润苑17号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10259",
+            "name":"中环和润苑16号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10258",
+            "name":"中环和润苑15号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10257",
+            "name":"中环和润苑13号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10256",
+            "name":"中环和润苑12号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10255",
+            "name":"中环和润苑11号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10254",
+            "name":"中环和润苑7号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10253",
+            "name":"中环和润苑6号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10252",
+            "name":"中环和润苑4号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10251",
+            "name":"中环和润苑3号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10250",
+            "name":"中环和润苑10号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10249",
+            "name":"中环和润苑9号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10248",
+            "name":"同济北苑25号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10247",
+            "name":"内江路小学",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10246",
+            "name":"市光二村68号",
+            "url":"/api/scene/cfd148a7ea1fd87d2d1b9ac0"
+        },
+        {
+            "id":"10245",
+            "name":"市光二村69号",
+            "url":"/api/scene/cfd148a7ea1fd87d2d1b9ac0"
+        },
+        {
+            "id":"10244",
+            "name":"市光二村106号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10243",
+            "name":"市光二村105号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10242",
+            "name":"市光二村103号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10241",
+            "name":"市光二村114号",
+            "url":"/api/scene/be75b3227487f868eb20588b"
+        },
+        {
+            "id":"10240",
+            "name":"市光二村113号",
+            "url":"/api/scene/be75b3227487f868eb20588b"
+        },
+        {
+            "id":"10239",
+            "name":"市光二村111号",
+            "url":"/api/scene/be75b3227487f868eb20588b"
+        },
+        {
+            "id":"10238",
+            "name":"市光二村104号",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10237",
+            "name":"市光二村115号",
+            "url":"/api/scene/be75b3227487f868eb20588b"
+        },
+        {
+            "id":"10236",
+            "name":"长华绿苑",
+            "url":"/api/scene/ab93bd9640a9db05a4937351"
+        },
+        {
+            "id":"10234",
+            "name":"市光二村112号",
+            "url":"/api/scene/be75b3227487f868eb20588b"
+        }
+    ]
+}

+ 0 - 0
pulic.js → 2021.08.09/pulic.js


+ 0 - 0
removeMark.js → 2021.08.09/removeMark.js


+ 0 - 0
杨浦.js → 2021.08.09/杨浦.js


BIN
icons/YTRU.png


BIN
icons/YTWG.png


BIN
icons/yCR8dP.png


BIN
icons/yCRGIf.png


BIN
icons/ySL6MT.png


BIN
icons/多楼层.png


BIN
icons/建筑.png


BIN
icons/透视.png


BIN
images/op0.png


+ 54 - 0
js/ChangeScene.js

@@ -0,0 +1,54 @@
+app.on(THING.EventType.LoadCampusProgress, function (ev) {
+    var value = ev.progress;
+    dataObj.progress = value;
+}, '加载场景进度');
+// 配置相应建筑的园区场景url
+
+/**
+ * 切换场景
+ */
+function changeScene(campusData) {
+    app.create({
+        type: "Campus",
+        url: campusData.url,
+        position: [0, 0, 0],
+        visible: false, // 创建园区过程中隐藏园区
+        complete: function (ev) {
+            // console.log(curCampus)
+            if(curCampus != undefined){
+                curCampus.destroy();  // 新园区创建完成后删除之前的
+            }
+            curCampus = ev.object;  // 将新园区赋给全局变量
+            curCampus.fadeIn();  // 创建完成后显示(渐现)
+            app.level.change(curCampus);  // 开启层级切换
+
+            var building = app.query(".Building");  // 获取园区中的建筑
+            mainPanle = new MainPanel(app);// 界面的类
+            creatFloorChoose();//创建楼层选择器
+            createHtml();  // 创建html
+            restarRotate();  // 自动旋转
+        }
+    });
+}
+
+
+/**
+ * 创建进度条组件
+ */
+function createWidgets() {
+    // 进度条界面组件
+    loadingPanel = new THING.widget.Panel({
+        titleText: '场景加载进度',
+        opacity: 0.9, // 透明度
+        hasTitle: true
+    });
+
+    // 设置进度条界面位置
+    loadingPanel.positionOrigin = 'TR'// 基于界面右上角定位
+    loadingPanel.position = ['100%', 0];
+
+    loadingPanel.visible = false;
+
+    loadingPanel.addNumberSlider(dataObj, 'progress').step(0.01).min(0).max(1).isPercentage(true);
+}
+

+ 43 - 0
js/CreateHtml.js

@@ -0,0 +1,43 @@
+/**
+ * 说明:创建页面元素
+ */
+function createHtml() {
+    let sign =
+        `<div id="all-controls">
+            <div class="controls">
+                <a id="horizontalExpansion" class="control-item">
+                    <i class="btn-horizontal"></i>
+                    <span class="tooltiptext">横向展开</span>
+                </a>
+                <a id="verticalExpansion" class="control-item">
+                    <i class="btn-vertical"></i>
+                    <span class="tooltiptext">纵向展开</span>
+                </a>
+                <a id="moveByFps" class="control-item">
+                    <i class="btn-fps"></i>
+                    <span class="tooltiptext">第一人称行走</span>
+                </a> 
+                <a id="miniMap" class="control-item">
+                    <i class="btn-map"></i>
+                    <span class="tooltiptext">小地图</span>
+                </a>
+                <a id="sceneSetting" class="control-item">
+                    <i class="btn-setting"></i>
+                    <span class="tooltiptext">设置</span>
+                    <div class="control-menu map-bg-select-menu">
+                        <div class="control-menu-wrapper" style="position: relative">
+                            <div class="control-menu-pane">
+                                <ul class="setting-list">
+                                    <li class="autoRotate setting-item selected">自动旋转</li>
+                                </ul>
+                            </div>
+                        </div>
+                    </div>
+                </a>
+           
+            </div>
+        </div>`;
+    // 将页面元素加入到div2d容器中,相关示例可参考官方示例-->界面2D-->UIAnchor
+    $('#div2d').append($(sign));
+    registerEvent();  // 注册事件
+}

+ 262 - 0
js/FloorClick.js

@@ -0,0 +1,262 @@
+//创建楼层选择器
+function creatFloorChoose() {
+    var floorsign =
+        `
+        <div value='close' onclick="handleSide()"  class ="closeIocn"  id='rightSideSwitch'></div>
+        <div id="floorChooseDiv" class="showFloorBtn" style="height:95%">         
+        
+        
+        </div>`;
+
+    $('#div2d').append($(floorsign));
+
+    var car = app.query(".Floor")
+
+    var html = ``
+    for(let i = 0 ; i < car.length; i++){
+        html +=
+        `
+        <div onclick="floorclick('${car[i].id}')" class = "showFloorBtns" id='${car[i].id}'>${car[i].id}</div> 
+        `
+    }
+    $('#floorChooseDiv').append($(html));
+    
+    $('head').append($(`
+        <style>
+            .showFloorBtns{
+                margin-bottom:6px;
+                border:1px solid rgb(24,118,208);
+                border-radius:4px;
+                text-align:center;
+                height:28px;
+                line-height:28px;
+                width:40px;
+                color:rgba(255,255,255,0.5);
+                background-color:rgba(24,144,255,0.3);
+                //  display:inline-block;
+            }
+            .showFloorBtn{
+                position: absolute;
+                // top:10px;
+                top:calc(2%);
+                right:-52px;
+                // height:800px;
+                width:50px;
+                border-radius:0px;
+                margin-top:0px;
+                overflow-y: auto;
+                cursor:pointer;
+                scrollbar-width: none; /* firefox */
+                -ms-overflow-style: none; /* IE 10+ */
+            }
+            .closeIocn{
+                //  margin-bottom:6px;
+                //  border:1px solid rgb(24,118,208);
+                border-radius:4px;
+                text-align:center;
+                height:30px;
+                line-height:28px;
+                width:40px;
+                color:rgba(255,255,255,0.5);
+                background-image: url(/uploads/wechat/163607/file/杨浦16/icons/yCR8dP.png);
+                background-repeat:no-repeat;
+                background-position:center center;
+                position: absolute;
+                top: calc(50%);
+                right: 0;
+            }
+            .active{
+                background-color:red;
+            }
+            .showFloorBtn::-webkit-scrollbar {
+                display: none;
+            }
+        </style>
+    `));
+}
+//楼层切换
+function floorclick(id) {
+    // test();
+    //  delMydiv();
+    //  floormen = id.id;
+    //  building = app.buildings[0];
+    //  var num = floormen.substring(1, 3);
+    //  var s = parseInt(num);
+    //  var floor = building.floors[s - 1];
+    var floor = app.query("#" + id)[0];
+    app.level.change(floor);
+    // creatbutType(s);
+    creatbutElement(id)
+}
+// 点击右侧侧边栏开关
+function handleSide() {
+    if ($('#rightSideSwitch').attr('value') == 'close') {
+        
+        $('.closeIocn').animate({ right: 48 }, 300);
+        $('.showFloorBtn').animate({ right: 0 }, 300);
+        //  $('#rightSideSwitch').attr('value', 'open');
+        $('#rightSideSwitch').attr('value', 'open').css('background-image', 'url(/uploads/wechat/163607/file/杨浦16/icons/yCRGIf.png)');
+    } else if ($('#rightSideSwitch').attr('value') == 'open') {
+        $('.closeIocn').animate({ right: 0 }, 300);
+        $('.showFloorBtn').animate({ right: -52 }, 300);
+        $('#rightSideSwitch').attr('value', 'close').css('background-image', 'url(/uploads/wechat/163607/file/杨浦16/icons/yCR8dP.png)');
+        //  $('#rightSideSwitch').attr('value', 'close');
+    }
+}
+//设备类型div删除
+function delMydiv() {
+    var mydiv = document.getElementById("bottomBtnsRight")
+    if (mydiv) {
+        if (mydiv != null)
+            mydiv.parentNode.removeChild(mydiv);
+    }
+}
+//设备类型选择器
+function creatbutElement(floorNum) {
+    if(floorNum == "B1"){
+        floorNum = "F-1"
+    }
+    delMydiv();
+    var devType = [];
+    var data = cleanObj(buildingStore);
+    for (var i = 0; i < data.length; i++) {
+        var floorData = data[i]
+        var floorId = floorData.min_level;
+        var num = floorNum.substring(1, 3);
+        var s = parseInt(num)
+        if (floorId == s) {
+            var dataArray = floorData.item;
+            if (dataArray) {
+                for (var q = 0; q < dataArray.length; q++) {
+                    var eee = dataArray[q].dwtype;
+                    devType.push(eee);
+                }
+            }
+            break;
+        }
+    }
+    var darray = uniq(devType);
+    var textAndPictureMarkerHtml =
+        `<div class="bottomBtnsRight" id="bottomBtnsRight">
+		</div>`;
+    $('#div2d').append($(textAndPictureMarkerHtml));
+    var cont = 1;
+    console.log(darray)
+    darray.forEach(function (name) {
+        if (name == "YTVA") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTVA',` + s + `)" class="bottomBtn" value='视频告警监测'>
+				<span class="bottomBtnText">视频告警监测<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        } else if (name == "YTWP") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTWP',` + s + `)" class="bottomBtn" value='水压检测'>
+				<span class="bottomBtnText">水压监测<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        } else if (name == "YTCI") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTCI',` + s + `)" class="bottomBtn" value='环境监测'>
+				<span class="bottomBtnText">环境监测<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        } else if (name == "YTEF") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTEF',` + s + `)" class="bottomBtn" value='电气火灾监测'>
+				<span class="bottomBtnText">电气火灾监测<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        } else if (name == "YTFC") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTFC',` + s + `)" class="bottomBtn" value='消防控制柜'>
+				<span class="bottomBtnText">消防控制柜<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        } else if (name == "YTSM") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTSM',` + s + `)" class="bottomBtn" value='烟感'>
+				<span class="bottomBtnText">烟感<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        }
+        else if (name == "YTLL") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTLL',` + s + `)" class="bottomBtn" value='液位'>
+				<span class="bottomBtnText">液位<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        }
+        else if (name == "YTWI") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTWI',` + s + `)" class="bottomBtn" value='水浸'>
+				<span class="bottomBtnText">水浸<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        }else if (name == "YTWG") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTWG',` + s + `)" class="bottomBtn" value='网关'>
+				<span class="bottomBtnText">网关<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        }else if (name == "YTRU") {
+            var yTVAHtml =
+                `<div onclick="icon_click('YTRU',` + s + `)" class="bottomBtn" value='路由'>
+				<span class="bottomBtnText">路由<span>
+			</div>
+            	`;
+            $('#bottomBtnsRight').append($(yTVAHtml));
+        }
+    })
+    $('head').append($(`
+        <style>
+          .bottomBtn{
+	        text-align: center;
+            left:200px;
+	        width: 100px;
+    	    height: 31px;
+        	margin-top: 7px;
+            top:650px;
+           // display: inline-block;
+        	background-image: url(${baseURL}ySL6MT.png);
+        }
+        .bottomBtnsRight{
+            position: relative;
+         //   top:481px;
+            bottom:-459px;
+	        justify-content: left;
+	      //  width: calc(100% - 203px);
+	        height: 40px;
+                }
+         .bottomBtnText{
+            font-size: 12px;
+            display: inline-block;
+            text-align:center;
+            padding-left: 15px;
+            color:rgba(255,255,255,0.5);
+            letter-spacing: 2px;
+            line-height: 36px;
+                  }
+        </style>
+    `));
+}
+//创建设备点位标识
+function icon_click(deviceType, floorNum) {
+    buildingStore;
+    deviceList = [];
+    for (var i = 0; i < buildingStore.length; i++) {
+        if (floorNum == buildingStore[i].min_level) {
+            deviceList.push(buildingStore[i]);
+        }
+    }
+    create_ui(deviceType, floorNum, deviceList);
+}

+ 100 - 0
js/MainPanel.js

@@ -0,0 +1,100 @@
+class MainPanel {
+    constructor(app) {
+        this.app = app;
+        this.panels_znyg = [];
+        this.panels_znjk = [];
+        this.panels_znef = [];
+        this.toolBar = null;
+        this.toolImgs = {};
+        this.isExpandBuilding = false;
+        this.createToolsPanel();
+        this.building = this.app.buildings[0];
+    }
+    // 创建工具面板
+    createToolsPanel() {
+        var that = this;
+
+        //  this.toolBar = THING.widget.ToolBar({ width: '12%', media: true,captionPos:'hover',opacity:0.5});
+        this.toolBar = THING.widget.Banner({ column: 'left', width: '20px', media: true, captionPos: 'hover', opacity: 0.8 });
+        this.toolBar.data = { znsx: false, enterBuilding: false, expandBuilding: false, deviceShow: false, electricalFire: false };
+        this.toolBar.setPosition({ right: 0, top: 60 });
+        this.toolImgs.img3 = this.toolBar.addImageBoolean(this.toolBar.data, 'enterBuilding').name('进入建筑').imgUrl(baseURL + '建筑.png');
+        this.toolImgs.img4 = this.toolBar.addImageBoolean(this.toolBar.data, 'expandBuilding').name('楼层展开').imgUrl(baseURL + '多楼层.png');
+        this.toolImgs.img6 = this.toolBar.addImageBoolean(this.toolBar.data, 'deviceShow').name('建筑透视').imgUrl(baseURL + '透视.png');
+        this.toolImgs.img3.on('change', function (boolValue) { that.onChangeImageButton('enterBuilding', boolValue); });
+        this.toolImgs.img4.on('change', function (boolValue) { that.onChangeImageButton('expandBuilding', boolValue); });
+        this.toolImgs.img6.on('change', function (boolValue) { that.onChangeImageButton('deviceShow', boolValue); });
+
+    }
+    // 处理工具条按钮
+    onChangeImageButton(key, boolValue) {
+        var that = this;
+        if (key == "enterBuilding") { // 进入建筑/室外
+            this.goinBuild(boolValue);
+
+        } else if (key == "deviceShow") {//展示全部设备隐藏楼层\
+            var devicList = [];
+            var build = app.buildings[0]
+            var opacity = build.style.opacity;// 0 为全透明 ,1 为不透明
+            build.style.opacity = (opacity > 0.8) ? 0.1 : 1.0;
+            var deviceArray = app.query('["userData/物体类型"="烟感"]');
+            devicList.push(deviceArray)
+            if (boolValue) {
+                flash(devicList);
+                this.goinBuild(boolValue);
+                //    updateData();
+            }
+            else {
+                reset(devicList);
+            }
+        }
+        else if (key == "expandBuilding") { // 楼层横向展开
+            this.app.level.change(app.buildings[0]); // 进入建筑
+            if (boolValue) {
+                this.building.expandFloors({
+                    'time': 1000,
+                    'length': 4,
+                    'horzMode': false,
+                    'hideRoof': true,
+                    'complete': function () {
+
+                        that.isExpandBuilding = true;
+                    }
+                })
+            } else {
+                this.building.unexpandFloors({
+                    'time': 500,
+                    'complete': function () { that.isExpandBuilding = false; }
+                })
+            }
+        }
+    }
+    // 展开的楼层收回去
+    resetExpand() {
+        var that = this;
+        if (this.isExpandBuilding) {
+            this.toolBar.data.expandBuilding = false;
+            this.building.unexpandFloors({
+                'time': 500,
+                'complete': function () { that.isExpandBuilding = false; }
+            })
+        }
+    }
+    goinBuild(boolValue) {
+        delMydiv();
+        this.resetExpand();
+        var name = boolValue ? '返回室外' : '进入建筑';
+        this.toolImgs.img3.name(name);
+        if (boolValue) {
+            removeMark();
+            this.app.level.change(app.buildings[0]);
+            var domDiv = document.getElementById('bottomBackground');
+            if (domDiv) {
+                domDiv.remove();
+            }
+        }
+        else {
+            this.app.level.change(app.root.campuses[0]);
+        }
+    }
+}

+ 270 - 0
js/UIAnchor.js

@@ -0,0 +1,270 @@
+/**
+ * 创建UIAnchor界面
+ * @param {Object} obj - 创建界面的父物体
+ * @param {String} value - 创建界面的类型
+ */
+function createUIAnchor(floorNum) {
+    let anchorCreateJson = {
+        type: "UIAnchor",
+        //   element: $(".pictureMarker")[0],
+        //  position: [100, -10, -21],
+        //  parent: app.query('#1F1FS01')[0],
+        //  pivotPixel: [parseFloat($(".textAndPictureMarker").css("width")) / 2, parseFloat($(".textAndPictureMarker").css("height"))],
+    }
+    var s = app.query('#' + floorNum)[0];
+    let n = Math.ceil(Math.random() * 10)
+    anchorCreateJson.element = $(".textAndPictureMarker")[0];
+    //anchorCreateJson.position = [5, 2, n];
+    anchorCreateJson.parent = app.query('#' + floorNum)[0];
+    anchorCreateJson.pivotPixel = [parseFloat($(".textAndPictureMarker").css("width")) / 2, parseFloat($(".textAndPictureMarker").css("height"))];
+    let tempTopCard = app.create(anchorCreateJson);  // 创建顶牌
+    tempTopCard.visible = true;  // 设置初始顶牌状态
+}
+function deviceIcon_click(dwtype, floorNum, ownercode) {
+    let funcName = "icon_click";
+    var data = {
+        'dwtype': dwtype,
+        'level': floorNum,
+        'id': ownercode
+    }
+    var message = {
+        'funcName': funcName, // 所要调用父页面里的函数名
+        'param': data
+    }
+    // 向父窗体(用户主页面)发送消息
+    // 第一个参数是具体的信息内容,
+    // 第二个参数是接收消息的窗口的源(origin),即"协议 + 域名 + 端口"。也可以设为*,表示不限制域名,向所有窗口发送
+    window.parent.postMessage(message, '*');
+}
+//======================================================================================================================
+// 添加html
+function create_html() {
+    var sign =
+        `<div 
+		</div>`
+    $('#div3d').append($(sign));
+}
+function create_element(dName, deviceTypes, floorNum, ownercode) {
+
+    var srcElem = document.getElementById('board');
+
+    if (deviceTypes == 'YTVA') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J9mvD.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTWP') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J9GPP.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTCI') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J935t.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTEF') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J91UI.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTFC') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J9lVA.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTSM') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J9Mbd.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTLL') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J9J8f.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+
+    } else if (deviceTypes == 'YTWI') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url(https://s3.ax1x.com/2021/03/10/6J9Y28.png) no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTWG') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url('/uploads/wechat/163607/file/杨浦16/icons/YTWG.png') no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    } else if (deviceTypes == 'YTRU') {
+        var sign =
+            `<div class="sign" id=${dName} style="font-size: 12px;width: 120px;text-align: center;background-color: rgba(0, 0, 0, .6);border: 0px solid #eeeeee;border-radius: 8px;color: #eee;position: absolute;top: 0;left: 0;z-index: 10;display: none;">
+			<div class="s1" style="margin: 5px 0px 5px 0px;line-height: 32px;overflow: hidden;">
+				<span class="span-l icon" style="float: left;width: 30px;height: 30px;background:url('/uploads/wechat/163607/file/杨浦16/icons/YTRU.png') no-repeat center;margin: 1px 1px 1px 5px;"></span>
+				<span class="span-l font" style="float: left;margin: 0px 0px 0px 1px;">${dName}</span>
+			</div>
+		</div>`
+    }
+
+
+    $('#div3d').append($(sign));
+    var newElem = document.getElementById(dName);
+    // var newElem = srcElem.cloneNode(true);
+    newElem.style.display = "block";
+    newElem.setAttribute("onclick", "deviceIcon_click('" + deviceTypes + "','" + floorNum + "','" + ownercode + "')");
+    app.domElement.insertBefore(newElem, srcElem);
+    return newElem;
+}
+// 物体顶界面
+var ui = null;
+var uis = [];
+var position = []
+var list = []
+function create_ui(deviceType, floorNum, deviceList) {
+    var deviceTypes = deviceType;
+    destroy_ui();
+    create_html();
+    deviceIcon = [];
+    for (var j = 0; j < deviceList.length; j++) {
+        if (deviceList[j].dwtype == deviceType) {
+            deviceIcon.push(deviceList[j]);
+        }
+    }
+    if (deviceType == 'YTVA') {
+        deviceType = '摄像头';
+    } else if (deviceType == 'YTWP') {
+        deviceType = '水表';
+    } else if (deviceType == 'YTCI') {
+        deviceType = '环境监测';
+    } else if (deviceType == 'YTEF') {
+        deviceType = '电气火灾';
+    } else if (deviceType == 'YTFC') {
+        deviceType = '消防控制柜';
+    } else if (deviceType == 'YTSM') {
+        deviceType = '烟感';
+    } else if (deviceType == 'YTLL') {
+        deviceType = '液位';
+    } else if (deviceType == 'YTWI') {
+        deviceType = '水浸';
+    } else if (deviceType == 'YTWG') {
+        deviceType = '网关';
+    } else if (deviceType == 'YTRU') {
+        deviceType = '4G路由';
+    }
+    let num;
+    if (floorNum == -1) {
+        num = 'B1'
+    } else {
+        num = 'F' + floorNum;
+    }
+
+
+    var carList = app.query("#" + num)[0].query(deviceType)
+    var carList1 = app.query("#" + num)[0]
+    var carList2 = app.query(".Room")[0]
+    var url = '';
+    var scale; //物体大小
+    var parent;
+    for (var i = 0; i < deviceIcon.length; i++) {
+        // console.log(deviceIcon[i])
+        dName = deviceIcon[i].device_name;
+        var ownercode = deviceIcon[i].owner_code
+        if (carList[i] == undefined) {
+            if (deviceType == '烟感') {
+                url = '/api/models/641A9B800DE5431E8C84DC290F8EFDE6/0/gltf/'
+                scale = [2, 2, 2]
+            } else if (deviceType == '摄像头') {
+                url = '/api/models/2DBD1DCD7B5F49BDA43CC6444FC5CBD0/0/gltf/'
+                scale = [2, 2, 2]
+            } else {
+                url = '/api/models/5BD84A6968384A3F919DE8B82DD7D7DC/0/gltf/'; //万能圆球
+                scale = [0.1, 0.1, 0.1]
+            }
+            var position_1 = [carList1.position[0], carList1.position[1] + 3, carList1.position[2] + i - 3]
+
+            if (carList2 == undefined) {
+                position = position_1
+            } else {
+                if (num == 'B1') {
+                    if (carList2.name == '水泵房') {
+                        position = [carList2.position[0], carList2.position[1] + 3, carList2.position[2] + i - 3]
+                    } else {
+                        position = position_1
+                    }
+                } else {
+                    position = position_1
+                }
+
+            }
+
+
+            // console.log(carList2)
+
+            truck = app.create({
+                type: 'Thing',
+                name: deviceType,
+                url: url,
+                id: deviceType + i,
+                position: position,
+                angle: 0,
+                angles: [0, 270, 0],
+                scale: scale
+            });
+            list.push(truck)
+            parent = truck
+
+        } else {
+            parent = carList[i]
+        }
+        ui = app.create({
+            type: 'UIAnchor',
+            parent: parent,
+            element: create_element(dName, deviceTypes, floorNum, ownercode),
+            localPosition: [0, 2, 0],
+            pivot: [0.5, 1] //  [0,0]即以界面左上角定位,[1,1]即以界面右下角进行定位
+        });
+        uis.push(ui);
+    }
+
+}
+// 删除界面
+function destroy_ui() {
+    if (uis) {
+        for (var i = 0; i < uis.length; i++) {
+            uis[i].destroy();
+        }
+        uis = [];
+    }
+    if (list) {
+        for (var i = 0; i < list.length; i++) {
+            list[i].destroy();
+        }
+        list = [];
+    }
+
+}

+ 206 - 0
js/public.js

@@ -0,0 +1,206 @@
+/**
+ * 说明:检测菜单项是否已打开
+ */
+function checkBtnActives(arr) {
+    for (let i = 0; i < arr.length; i++) {
+        let temp = arr[i];
+        if ($(temp).hasClass('active')) {
+            $(temp).removeClass('active');
+            $(temp).find('.control-menu').removeClass('actives');
+        }
+    }
+}
+/**
+ * 说明:判断是否全屏
+ */
+function checkFull() {
+    var isFull =
+        document.fullscreenElement ||
+        document.mozFullScreenElement ||
+        document.webkitFullscreenElement;
+    //to fix : false || undefined == undefined
+    if (isFull === undefined) isFull = false;
+    return isFull;
+}
+/**
+ * 说明:创建胶囊
+ */
+function createBox() {
+    if (box == null) {
+        box = app.create({
+            type: 'Thing',
+            url: 'https://model.3dmomoda.com/models/9CD08ED91F5C4E0ABB6B0833C86F2942/0/gltf/',
+            position: [0, 0, 0],
+            angle: 180,
+            scale: [1.7, 1.7, 1.7],
+            style: {
+                color: '#FF0000'
+            }
+        });
+    }
+}
+/**
+ * 说明:第一人称行走
+ */
+function enterFps(pos) {
+    if (fpsCtrl == null) {
+        app.pauseEvent(THING.EventType.Pick, '*', THING.EventTag.LevelPickOperation);
+        app.pauseEvent(THING.EventType.KeyUp, null, '空格键切换视角');
+        app.camera.position = pos;  // 起始位置为鼠标点击时的位置
+        // 添加第一人称行走控件
+        fpsCtrl = app.addControl(
+            new THING.WalkControl({  // 参数可以动态修改
+                walkSpeed: 0.02,  // 行走速度
+                turnSpeed: 0.25,  // 右键旋转速度
+                gravity: 26,  // 物体重量
+                eyeHeight: 1.6,  // 人高度
+                jumpSpeed: 10,  // 按空格键 跳跃的速度
+                enableKeyRotate: false,  // 默认不开启键盘控制旋转
+                useCollision: true,  // 默认不开启碰撞检测
+                useGravity: true,  // 默认开启重力
+                groundObjects: [app.scene],  // 把整个场景都添加,可把楼层或其他需要检测的添加进入碰撞体系里 | 默认值 园区地板,如果园区过大,可取消提升性能
+                collisionObjects: [app.scene]  // 把整个场景都添加,可把楼层或其他需要检测的添加进入碰撞体系里 | 默认值 园区地板,如果园区过大,可取消提升性能
+            })
+        );
+    }
+}
+/**
+ * 说明:退出第一人称行走
+ */
+function exitFps() {
+    app.removeControl(fpsCtrl);
+    fpsCtrl = null;
+    cameraFly(cameraInitPos[0], cameraInitPos[1]);
+    // 恢复默认双击事件
+    app.resumeEvent(THING.EventType.DBLClick, '*', THING.EventTag.LevelEnterOperation);
+    // 恢复默认点击事件
+    app.resumeEvent(THING.EventType.Click, '*', THING.EventTag.LevelBackOperation);
+    // 恢复默认拾取事件
+    app.resumeEvent(THING.EventType.Pick, '*', THING.EventTag.LevelPickOperation);
+    // 恢复默认键盘键抬起事件
+    app.resumeEvent(THING.EventType.KeyUp, null, '空格键切换视角');
+    $('#moveByFps').removeClass('active');
+}
+/**
+ * 说明:开启小地图
+ */
+function createMiniMap() {
+    if (miniMapCtrl == null) {
+        // 添加小地图控件
+        miniMapCtrl = app.addControl(new THING.MiniMapControl({
+            width: 200,
+            height: 200,
+            position: THING.CornerType.LeftBottom,
+            opacity: 0.8,
+            scale: 1,
+            angle: 0,
+            mousewheel: true,
+            cameraViewImg: 'http://www.thingjs.com/static/images/minimap1.png',
+            cameraCenterImg: 'http://www.thingjs.com/static/images/minimap0.png'
+        }));
+        $('.minimap').css('border', '1px solid rgba(255, 255, 255, 0.8)');
+        $('.minimap').css('left', '3px');
+        $('.minimap').css('bottom', '3px');
+    } else {
+        destoryMiniMap();
+        createMiniMap();
+    }
+}
+/**
+ * 说明:关闭小地图
+ */
+function destoryMiniMap() {
+    if (miniMapCtrl != null) {
+        app.removeControl(miniMapCtrl);
+        miniMapCtrl = null;
+    }
+}
+/**
+ * 说明:全屏显示
+ */
+function fullScreen() {
+    let el = document.documentElement;
+    let rfs = el.requestFullScreen || el.webkitRequestFullScreen;
+    if (typeof rfs != "undefined" && rfs) {
+        rfs.call(el);
+    } else if (typeof window.ActiveXObject != "undefined") {
+        let wscript = new ActiveXObject("WScript.Shell");
+        if (wscript != null) {
+            wscript.SendKeys("{F11}");
+        }
+    }
+}
+/**
+ * 说明:退出全屏
+ */
+function exitFullScreen() {
+    let el = document;
+    let cfs = el.cancelFullScreen || el.webkitCancelFullScreen || el.exitFullScreen;
+    if (typeof cfs != "undefined" && cfs) {
+        cfs.call(el);
+    } else if (typeof window.ActiveXObject != "undefined") {
+        let wscript = new ActiveXObject("WScript.Shell");
+        if (wscript != null) {
+            wscript.SendKeys("{F11}");
+        }
+    }
+}
+/**
+ * 说明:摄像机飞行
+ */
+function cameraFly(position, target) {
+    // 摄像机飞行到某位置
+    app.camera.flyTo({
+        'position': position,
+        'target': target,
+        'time': 1000,
+        'complete': function () {
+        }
+    });
+}
+/**
+ * 说明:自动旋转
+ */
+function startRotate() {
+    app.camera.enableRotate = false;  // 关闭默认的旋转操作
+    app.camera.enablePan = false;  // 关闭默认的平移操作
+    app.camera.enableZoom = false;  // 关闭默认的缩放操作
+    // 绕摄像机当前目标点旋转
+    app.camera.rotateAround({
+        target: app.camera.target,  // 围绕摄像机当前目标点
+        // object: obj,  // 环绕的物体 (object 与 target 的设置互斥)
+        speed: 4,  // 环绕飞行的时间(3min)
+        yRotateAngle: 360,  // 环绕y轴飞行的旋转角度
+        loopType: THING.LoopType.Repeat  // 设置循环类型
+    });
+}
+/**
+ * 说明:停止自动旋转
+ */
+function stopRotate() {
+    app.camera.enableRotate = true;  // 开启默认的旋转操作
+    app.camera.enablePan = true;  // 开启默认的平移操作
+    app.camera.enableZoom = true;  // 开启默认的缩放操作
+    app.camera.stopRotateAround();
+    if (rotateTimer) {
+        clearTimeout(rotateTimer);
+        rotateTimer = null;
+    }
+}
+/**
+ * 说明:重新开始转动,未进行任何操作5s后开始自动旋转
+ */
+function restarRotate() {
+    if (fpsCtrl != null || !$('#sceneSetting .control-menu-pane li.autoRotate').hasClass('selected')) {
+        return;
+    }
+    if (rotateTimer == null) {
+        rotateTimer = setTimeout(function () {
+            //  startRotate();
+        }, restartTime);
+    } else {
+        clearTimeout(rotateTimer);
+        rotateTimer = null;
+        restarRotate();
+    }
+}

+ 18 - 0
js/removeMark.js

@@ -0,0 +1,18 @@
+/**
+ * 清除标注
+ */
+function removeMark() {
+    // 清除图片加文本标注
+    $('.textAndPictureMarker').remove();
+    var marker = app.query(/marker/);
+    if (marker) {
+        marker.destroy();
+    }
+    marker01 = null;
+    marker02 = null;
+    // 移除box
+    var box = app.query('.Box');
+    if (box) {
+        box.destroy();
+    }
+}

+ 63 - 64
park.json

@@ -3,62 +3,63 @@
         {
             "id":"10309",
             "name":"建信大厦",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/c6b71c8c21e8dfc3333989d4"
         },
         {
             "id":"10308",
             "name":"公安大厦",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/e13968d6272428910d2c4354"
         },
+
         {
             "id":"10307",
             "name":"城科大楼",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/a8fba28ea8b1c077d74d801e"
         },
         {
             "id":"10306",
             "name":"同济北苑29号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/cc7bd06e749ab9fec64da1f6"
         },
         {
             "id":"10305",
             "name":"同济北苑33号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/f0f39b072bb9f7b86c6e1f18"
         },
         {
             "id":"10304",
             "name":"同济北苑32号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/5a0469dde805520eb8d66d17"
         },
         {
             "id":"10303",
             "name":"同济北苑31号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/5a0469dde805520eb8d66d17"
         },
         {
             "id":"10302",
             "name":"同济北苑30号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/d61c7491e8c202643902a925"
         },
         {
             "id":"10301",
             "name":"同济北苑27号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/fe428942a178cebaa5aec0ed"
         },
         {
             "id":"10300",
             "name":"同济北苑28号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/182009fe57189910c10111f9"
         },
         {
             "id":"10299",
             "name":"同济北苑26号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/dee36d1a8d7356132d6af493"
         },
         {
             "id":"10298",
             "name":"同济北苑24号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/e7ce33224dd695d914d22d97"
         },
         {
             "id":"10297",
@@ -93,17 +94,17 @@
         {
             "id":"10291",
             "name":"同济北苑23号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/e7ce33224dd695d914d22d97"
         },
         {
             "id":"10290",
             "name":"同济北苑22号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/ae7dd11e02e823568b92252a"
         },
         {
             "id":"10289",
             "name":"同济北苑21号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/0d1f2c9e6bed8d968f600b80"
         },
         {
             "id":"10288",
@@ -118,202 +119,199 @@
         {
             "id":"10286",
             "name":"同济北苑20号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/5a0469dde805520eb8d66d17"
         },
         {
             "id":"10285",
             "name":"同济北苑19号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/0c51c5b8289b5f76326404c7"
         },
         {
             "id":"10284",
             "name":"同济北苑18号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/f0f39b072bb9f7b86c6e1f18"
         },
         {
             "id":"10283",
             "name":"同济北苑17号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/3e06139ba82596595eab7ee8"
         },
+
         {
             "id":"10282",
             "name":"同济西苑2号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/b7ec828044bcde81b1b72c27"
         },
         {
             "id":"10281",
             "name":"同济西苑1号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/b7ec828044bcde81b1b72c27"
         },
         {
             "id":"10280",
             "name":"同济北苑16号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/ae7dd11e02e823568b92252a"
         },
         {
             "id":"10279",
             "name":"同济北苑15号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/a7b1933fbd06d6b216c3f392"
         },
         {
             "id":"10278",
             "name":"同济北苑14号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/ae7dd11e02e823568b92252a"
         },
         {
             "id":"10277",
             "name":"同济北苑13号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/fe428942a178cebaa5aec0ed"
         },
         {
             "id":"10276",
             "name":"同济北苑12号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/a7b1933fbd06d6b216c3f392"
         },
         {
             "id":"10275",
             "name":"中原路28弄12号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/aac345df62079fa637583627"
         },
         {
             "id":"10274",
             "name":"中原路28弄11号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/4fd4da5140ed755643a8f3dc"
         },
         {
             "id":"10273",
             "name":"翔殷消防大楼",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/e2b0c8560ef030e8056567bc"
         },
         {
             "id":"10272",
             "name":"贵人大厦",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/a557442c93d06e1ad7e67fe4"
         },
         {
             "id":"10271",
             "name":"中原路28弄4号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/358246b8228d50d8241dc6fa"
         },
         {
             "id":"10270",
             "name":"中原路28弄3号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/4fd4da5140ed755643a8f3dc"
         },
         {
             "id":"10269",
             "name":"中原路28弄2号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/358246b8228d50d8241dc6fa"
         },
         {
             "id":"10268",
             "name":"中原路28弄1号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/4fd4da5140ed755643a8f3dc"
         },
         {
             "id":"10267",
             "name":"松益公寓319号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/73fa9d2b7af1852e653ff177"
         },
         {
             "id":"10266",
             "name":"松益公寓311号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/6c851e0830eff9ad56172cec"
         },
         {
             "id":"10265",
             "name":"浣纱五村3号楼",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/30c08eab04c444f64f5ef56b"
         },
         {
             "id":"10264",
             "name":"浣纱五村2号楼",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/b17d2283596164a739b02b65"
         },
         {
             "id":"10263",
             "name":"中环和润苑20号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/b00c849138381dfaf027b97e"
         },
         {
             "id":"10262",
             "name":"中环和润苑19号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/d65a7ab82bb29cca46e6b2d2"
         },
         {
             "id":"10261",
             "name":"中环和润苑18号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/01e707cd54fe698c2125c48c"
         },
         {
             "id":"10260",
             "name":"中环和润苑17号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/d19b5cee8c1ad6f0a29aab49"
         },
         {
             "id":"10259",
             "name":"中环和润苑16号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/1c9132e8d7e5fb60f570651a"
         },
         {
             "id":"10258",
             "name":"中环和润苑15号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/4df3340064e5cb9d87316166"
         },
         {
             "id":"10257",
             "name":"中环和润苑13号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/1c9132e8d7e5fb60f570651a"
         },
         {
             "id":"10256",
             "name":"中环和润苑12号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/4df3340064e5cb9d87316166"
         },
         {
             "id":"10255",
             "name":"中环和润苑11号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/b00c849138381dfaf027b97e"
         },
         {
             "id":"10254",
             "name":"中环和润苑7号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/01e707cd54fe698c2125c48c"
         },
         {
             "id":"10253",
             "name":"中环和润苑6号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/d19b5cee8c1ad6f0a29aab49"
         },
         {
             "id":"10252",
             "name":"中环和润苑4号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/01e707cd54fe698c2125c48c"
         },
+
         {
             "id":"10251",
             "name":"中环和润苑3号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/aa3971c314283b59002307ce"
         },
         {
             "id":"10250",
             "name":"中环和润苑10号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/ffad2f43313bd3269b7ca9fc"
         },
         {
             "id":"10249",
             "name":"中环和润苑9号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/24815ef1d4ec27ec0e55ff9b"
         },
         {
             "id":"10248",
             "name":"同济北苑25号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
-        },
-        {
-            "id":"10247",
-            "name":"内江路小学",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/08928440b4ad2d8057ef08a9"
         },
         {
             "id":"10246",
@@ -328,17 +326,17 @@
         {
             "id":"10244",
             "name":"市光二村106号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/0455e402fd04dbc5ed678fe9"
         },
         {
             "id":"10243",
             "name":"市光二村105号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/343afae2b9e1c128a26e1722"
         },
         {
             "id":"10242",
             "name":"市光二村103号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/343afae2b9e1c128a26e1722"
         },
         {
             "id":"10241",
@@ -355,10 +353,11 @@
             "name":"市光二村111号",
             "url":"/api/scene/be75b3227487f868eb20588b"
         },
+
         {
             "id":"10238",
             "name":"市光二村104号",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/0455e402fd04dbc5ed678fe9"
         },
         {
             "id":"10237",
@@ -368,7 +367,7 @@
         {
             "id":"10236",
             "name":"长华绿苑",
-            "url":"/api/scene/ab93bd9640a9db05a4937351"
+            "url":"/api/scene/02f087d70683e5fa3cd6b6c2"
         },
         {
             "id":"10234",

+ 21 - 0
杨浦16.cps

@@ -0,0 +1,21 @@
+/*
+* 说明:本文件是“项目离线部署包”场景打包配置文件。
+* 提示:项目离线部署包打包时将参考本文件配置进行。为确保打包完整,请将项目引入的“园区”场景URL、
+*       模型URL,填写到下方的配置中。
+*/
+{
+    // 当前项目使用的ThingJS包(thing.min.js)版本号
+    "thingjs_version" : "1.2.7.18",
+    // 举例:项目中引用的第一个场景URL为 "/api/scene/d370cad09e74f42d932b083d",
+    //      第二个场景URL为 "/api/scene/b422fd26d4c7874df3992068",
+    //      为能正确打包上述两个场景,需配置如下:
+    // "scenes": [
+    //     "/api/scene/d370cad09e74f42d932b083d",
+    //     "/api/scene/b422fd26d4c7874df3992068"
+    //  ],
+    // 举例:项目中动态引用了模型 "/api/models/8CF6171F7EE046968B16E10181E8D941/0/gltf/",
+    //      为能正确打包该引用模型,需配置如下:
+    // "models": [
+    //     "/api/models/8CF6171F7EE046968B16E10181E8D941/0/gltf/"
+    //  ]
+}

+ 649 - 0
杨浦16.js

@@ -0,0 +1,649 @@
+var filePath = '/uploads/wechat/5oiR5pyJ5pyA6ZW/55qE572R5ZCN5LiN5L+h5L2g5pWw5pWw/file/ScenePreview/';
+// 需要用到的外部文件
+var fileArr = [
+    "https://www.layuicdn.com/layui/layui.js",
+    'https://www.layuicdn.com/layui/css/layui.css',
+    filePath + 'assets/css/index.css',  // 功能按钮样式文件
+    filePath + 'assets/font-awesome-4.7.0/css/font-awesome.min.css',  // 功能按钮字体样式
+    filePath + 'assets/css/myAlert.css',  // 弹出框样式
+    filePath + 'assets/css/sweetalert2.min.css',  // 弹出框样式
+    filePath + 'assets/js/sweetalert2.all.min.js',  // 弹出框脚本
+    filePath + 'assets/js/myAlert.js',  // 弹出框脚本
+    filePath + 'assets/js/posTransform.js',  // 不同坐标系经纬度互相转换的脚本文件
+    filePath + 'assets/js/expandFloor.js', // 楼层展开脚本
+    '/guide/lib/echarts.min.js',
+    '/uploads/wechat/163607/file/杨浦16/js/removeMark.js',//清除标注脚本
+    '/uploads/wechat/163607/file/杨浦16/js/UIAnchor.js',//UI界面脚本
+    '/uploads/wechat/163607/file/杨浦16/js/FloorClick.js',//创建切换楼层脚本
+    '/uploads/wechat/163607/file/杨浦16/js/MainPanel.js',//公共工具功能脚本
+    '/uploads/wechat/163607/file/杨浦16/js/CreateHtml.js',//创建页面元素脚本
+    '/uploads/wechat/163607/file/杨浦16/js/public.js',//公共场景功能脚本  
+    '/uploads/wechat/163607/file/杨浦16/js/ChangeScene.js',//场景切换脚本
+];
+/**
+ * 说明:加载外部文件
+ */
+THING.Utils.dynamicLoad(fileArr, function () {});
+
+
+
+// 创建app
+var app = new THING.App({   
+    url: '/api/scene/0b75dc5f4460f22c329afd96',
+    // url: '/api/scene/a8fba28ea8b1c077d74d801e',//城科大楼
+    // url: '/api/scene/8fe9eaf0118f74c71010bc19',//宝钢又一村31号
+    // url: '/api/scene/ab93bd9640a9db05a4937351',
+    // url: '/api/scene/e1137071cd763730846f50ba',//常福医院
+    background: 'https://www.thingjs.com/static/images/background_img_03.png'
+});
+
+
+
+//设备列表
+var buildingStore;
+// $.ajax({
+//     type: "GET",
+//     url:'/uploads/wechat/163607/file/杨浦16/buildingStore.json',
+//     dataType: "json",
+//     async: false,
+//     success: function (data) {
+//         buildingStore = data.buildingStore
+//     }
+// });
+
+app.camera.xAngleLimitRange = [0, 90];
+
+
+var truck;
+var campusUrl;//场景列表
+var dataObj = { progress: 0 };  // 场景加载进度条数据对象
+var loadingPanel;  // 进度条界面组件
+var curCampus;//存放园区url路径
+var company_code;
+
+var buildingStore;
+var miniMapCtrl = null;  // 小地图控件
+var webSocket;//webSocket
+var tileLayer1 = null;  // 加入地图背景后选用的图层
+var box = null;  // 鼠标点击第一人称行走按钮时,红色盒子提示
+var fpsCtrl = null;  // 第一人称行走控件
+var cameraInitPos = null;  // 进入第一人称行走前摄像机位置
+var fullScreenState = false;  // 全屏
+var skyBox = null;  // 天空盒
+var hiddenControlTimer = null;  // 隐藏控制按钮计时器
+var showControlTimer = null;  // 显示控制按钮计时器
+var cameraDistace = [];
+var building = null, mainPanle;  // 建筑
+var restartTime = 5000;  // 自动旋转停止后重启时间间隔
+var rotateTimer = null;  // 自动旋转计时器
+//var baseURL = "http://47.103.74.123/ThingjsIcon/";
+// var baseURL = "https://s3.ax1x.com/2021/01/28/";
+var baseURL = "/uploads/wechat/163607/file/杨浦16/icons/";
+
+
+
+
+app.on('load', function (ev) {  
+    curCampus = ev.campus;
+    skyBox = app.skyBox;  // 获取天空盒
+    app.level.change(ev.campus);  // 切换至园区层级
+    ev.campus.azimuth = '180';
+    //  setupNavpanel();
+    // creatFloorChoose();  //======================================本地数据测试===============================================
+    // 获取园区在CampusBuilder编辑时保存的地理位置
+    let tjsLnglat = app.root.defaultCampus.extraData;
+    if (tjsLnglat != undefined && tjsLnglat != null) {
+        tjsLnglat = tjsLnglat.coordinates;
+        if (tjsLnglat != undefined && tjsLnglat != null) {
+            tjsLnglat = tjsLnglat.split(",");
+        }
+    } else {
+        ev.campus.extraData = { coordinates: "116.4641,39.98606" }  // 园区绑定默认经纬度,地图才生效
+    }
+});
+
+// 监听建筑层级的 LeaveLevel 事件
+app.on(THING.EventType.LeaveLevel, ".Building", function (ev) {
+    // 要进入的层级对象
+    var current = ev.current;
+    // 上一层级对象(退出的层级)
+    var preObject = ev.previous;
+    if (current.parent === preObject) {
+        removeMark();
+    }
+    else {
+        removeMark();
+    }
+})
+
+
+/**
+ * 说明:注册事件
+ */
+function registerEvent() {
+    var _this = this
+    // 楼层横向展开按钮的点击事件,楼层展开只在建筑有2层或2层以上的楼层才会生效
+    $('#horizontalExpansion').on('click', function () {
+        stopRotate();
+        checkBtnActives(['#mapBg', '#sceneSetting']);
+        let expandState = building.getAttribute('expandState');
+        if ($(this).hasClass('active')) {
+            // 楼层横向展开关闭
+            if (expandState == 'horizontal') {
+                $(this).removeClass('active');
+                horizontalExpand(building, 'close');
+            }
+        } else {
+            // 楼层横向展开前应判断楼层是否处于垂直展开状态,是,则应先关闭垂直展开,然后横向展开
+            if (expandState != 'moving') {
+                $(this).addClass('active');
+                $('#verticalExpansion').removeClass('active');
+                if (expandState == 'vertical') {
+                    verticalToHorizontal(building);
+                } else {
+                    horizontalExpand(building, 'horizontal');
+                }
+            }
+        }
+        restarRotate();
+    });
+    // 楼层垂直展开按钮的点击事件,楼层展开只在建筑有2层或2层以上的楼层才会生效
+    $('#verticalExpansion').on('click', function () {
+        stopRotate();
+        checkBtnActives(['#mapBg', '#sceneSetting']);
+        let expandState = building.getAttribute('expandState');
+        if ($(this).hasClass('active')) {
+            // 楼层垂直展开关闭
+            if (expandState == 'vertical') {
+                $(this).removeClass('active');
+                verticalExpand(building, 'close');
+            }
+        } else {
+            // 楼层垂直展开前应判断楼层是否处于横向展开状态,是,则应先关闭横向展开,然后垂直展开
+            if (expandState != 'moving') {
+                $(this).addClass('active');
+                $('#horizontalExpansion').removeClass('active');
+                if (expandState == 'horizontal') {
+                    horizontalToVertical(building);
+                } else {
+                    verticalExpand(building, 'vertical');
+                }
+            }
+        }
+        restarRotate();
+    });
+    // 设置按钮点击事件,按钮的tip与功能面板的互相切换
+    $('#sceneSetting').on('click', function () {
+        checkBtnActives(['#mapBg']);
+        if ($(this).hasClass('active')) {
+            $(this).removeClass('active');
+            $(this).children('.control-menu').removeClass('actives');
+            $(this).find('.tooltiptext').css({ "visibility": "visible" });
+        } else {
+            $(this).addClass('active');
+            $(this).children('.control-menu').addClass('actives');
+            $(this).find('.tooltiptext').css({ "visibility": "hidden" });
+        }
+    }).hover(function () {
+        if (!$(this).hasClass('active')) {
+            $(this).find('.tooltiptext').css({ "visibility": "visible" });
+        }
+    }, function () {
+        $(this).find('.tooltiptext').css({ "visibility": "hidden" });
+    });
+    // 设置li标签添加点击事件
+    $('#sceneSetting .control-menu-pane li').on('click', function (ev) {
+        //ev.stopPropagation();
+        if ($(this).hasClass('selected')) {
+            stopRotate();
+            $(this).removeClass('selected');
+        } else {
+            $(this).addClass('selected');
+            restarRotate();
+        }
+    });
+    // 小地图的开启/关闭按钮的鼠标点击事件
+    $('#miniMap').on('click', function () {
+        if ($(this).hasClass('active')) {
+            $(this).removeClass('active');
+            destoryMiniMap();
+        } else {
+            $(this).addClass('active');
+            createMiniMap();
+        }
+        checkBtnActives(['#mapBg', '#sceneSetting']);
+    });
+    // 地图背景的开启/关闭按钮的鼠标点击事件,按钮的tip与功能面板的互相切换
+    $('#mapBg').on('click', function () {
+        checkBtnActives(['#sceneSetting']);
+        if ($(this).hasClass('active')) {
+            $(this).removeClass('active');
+            $(this).children('.control-menu').removeClass('actives');
+            $(this).find('.tooltiptext').css({ "visibility": "visible" });
+        } else {
+            $(this).addClass('active');
+            $(this).children('.control-menu').addClass('actives');
+            $(this).find('.tooltiptext').css({ "visibility": "hidden" });
+        }
+    }).hover(function () {
+        if (!$(this).hasClass('active')) {
+            $(this).find('.tooltiptext').css({ "visibility": "visible" });
+        }
+    }, function () {
+        $(this).find('.tooltiptext').css({ "visibility": "hidden" });
+    });
+    // 进入层级事件
+    app.on(THING.EventType.EnterLevel, function (ev) {
+        app.background = 'https://www.thingjs.com/static/images/background_img_03.png'
+        stopRotate();
+        // 进入建筑层级
+        if (ev.object.type == 'Building') {
+            var id = document.getElementById("rightSideSwitch")
+            if(id == null){
+                creatFloorChoose();//创建楼层选择器
+            }
+            //清除设备列表和面板
+            _this.delMydiv();
+            _this.destroy_ui();
+            let floors = ev.object.floors;
+            if (floors.length > 1) {
+                building = ev.object;
+                addFloorPos(building);
+                let expandState = building.getAttribute('expandState');
+                if (expandState == null) {
+                    building.setAttribute('expandState', 'close');
+                }
+                $('#horizontalExpansion').css({ 'display': 'block' });
+                $('#verticalExpansion').css({ 'display': 'block' });
+            }
+        } else {
+            $('#horizontalExpansion').css({ 'display': 'none' });
+            $('#verticalExpansion').css({ 'display': 'none' });
+            // 进入园区层级
+            if (ev.object.type == 'Campus') {
+                if (building != null) {
+                    exitBuildingCloseFloor(building);
+                    $('#horizontalExpansion').removeClass('active');
+                    $('#verticalExpansion').removeClass('active');
+                    building = null;
+                }
+            }
+        }
+        if (skyBox != null) {
+            app.skyBox = skyBox;
+        }
+        // 重新创建小地图
+        if ($('#miniMap').hasClass('active')) {
+            destoryMiniMap();
+            createMiniMap();
+        }
+    });
+    // 行走按钮的鼠标点击事件
+    $('#moveByFps').on('click', function () {
+        stopRotate();
+        if ($(this).hasClass('active')) {
+            $(this).removeClass('active');
+            if (box != null) {
+                // 恢复默认双击进入层级事件
+                app.resumeEvent(THING.EventType.DBLClick, '*', THING.EventTag.LevelEnterOperation);
+                // 恢复默认右键退出层级事件
+                app.resumeEvent(THING.EventType.Click, '*', THING.EventTag.LevelBackOperation);
+                box.destroy();
+                box = null;
+            }
+            if (fpsCtrl != null) {
+                exitFps();
+            }
+        } else {
+            $(this).addClass('active');
+            // 禁用默认双击进入层级事件
+            app.pauseEvent(THING.EventType.DBLClick, '*', THING.EventTag.LevelEnterOperation);
+            // 禁用默认右键退出层级事件
+            app.pauseEvent(THING.EventType.Click, '*', THING.EventTag.LevelBackOperation);
+            // 记录摄像机当前位置
+            cameraInitPos = [app.camera.position, app.camera.target];
+            createBox();
+        }
+        checkBtnActives(['#mapBg', '#sceneSetting']);
+    });
+    // 全屏按钮的鼠标抬起事件
+    $('#fullScreen').mouseup(function () {
+        if (!fullScreenState) {
+            $('.btn-full-screen').css('display', 'none');
+            $('.btn-narrow').css('display', 'block');
+            $('#fullScreen span').text('退出全屏');
+            fullScreen();
+            fullScreenState = true;
+        } else {
+            $('.btn-full-screen').css('display', 'block');
+            $('.btn-narrow').css('display', 'none');
+            $('#fullScreen span').text('全屏');
+            exitFullScreen();
+            fullScreenState = false;
+            if ($('#mapBg').hasClass('active')) {
+                destoryMiniMap();
+                createMiniMap();
+            }
+        }
+        checkBtnActives(['#mapBg', '#sceneSetting']);
+    });
+    // 鼠标键按下事件,功能按钮隐藏
+    app.on(THING.EventType.MouseDown, function () {
+        app.pauseEvent(THING.EventType.CameraZoom, null, '摄像机前后滚动,功能图片隐藏');
+        if (showControlTimer != null) {
+            clearTimeout(showControlTimer);
+            showControlTimer = null;
+        }
+        stopRotate();
+        if (hiddenControlTimer == null) {
+            clearTimeout(showControlTimer);
+            hiddenControlTimer = setTimeout(function () {
+                $('#all-controls').css('display', 'none');
+                clearTimeout(hiddenControlTimer);
+                hiddenControlTimer = null;
+            }, 300);
+        }
+    });
+    // 鼠标键抬起事件,功能按钮显示
+    app.on(THING.EventType.MouseUp, function () {
+        app.resumeEvent(THING.EventType.CameraZoom, null, '摄像机前后滚动,功能图片隐藏');
+        if (hiddenControlTimer != null) {
+            clearTimeout(hiddenControlTimer);
+            hiddenControlTimer = null;
+        }
+        if (showControlTimer == null) {
+            showControlTimer = setTimeout(function () {
+                $('#all-controls').css('display', 'block');
+                clearTimeout(showControlTimer);
+                showControlTimer = null;
+                restarRotate();
+            }, 300);
+        }
+    });
+    let count = 0;
+    // 鼠标滑轮滚动
+    app.on(THING.EventType.CameraZoom, function () {
+        if (showControlTimer != null) {
+            count = 0;
+            return;
+        }
+        stopRotate();
+        if (showControlTimer == null) {
+            $('#all-controls').css('display', 'none');
+            showControlTimer = setInterval(function () {
+                count++;
+                if (count >= 2) {
+                    $('#all-controls').css('display', 'block');
+                    restarRotate();
+                    clearInterval(showControlTimer);
+                    showControlTimer = null;
+                }
+            }, 300);
+        }
+    }, '摄像机前后滚动,功能图片隐藏');
+
+    // 鼠标移动事件,已创建的红色胶囊跟随鼠标移动
+    app.on(THING.EventType.MouseMove, function (ev) {
+        if (box != null) {
+            if (ev.picked) {
+                box.position = ev.pickedPosition;
+            }
+        }
+    });
+    // 摄像机位置改变结束事件,记录当前摄像机位置与目标点x,y,z的差
+    app.on(THING.EventType.CameraChangeEnd, function () {
+        if (cameraDistace.length > 0) {
+            let caPos = app.camera.position;
+            let scePos = app.root.defaultCampus.position;
+            cameraDistace = [caPos[0] - scePos[0], caPos[1] - scePos[1], caPos[2] - scePos[2]];
+        }
+        restarRotate();
+    });
+    // 点击事件,放置红色胶囊,进入第一人称行走
+    app.on(THING.EventType.Click, function (ev) {
+        stopRotate();
+        if (ev.button == 0 && box != null) {
+            let pos = box.position;
+            box.destroy();
+            box = null;
+            app.camera.flyTo(pos);
+            enterFps([pos[0], pos[1] + 2, pos[2]]);
+        }
+        checkBtnActives(['#mapBg', '#sceneSetting']);
+    });
+    // 进入层级事件,退出第一人称行走
+    app.on(THING.EventType.EnterLevel, function () {
+        if (fpsCtrl != null) {
+            exitFps();
+        }
+    });
+    // 离开层级事件,停止旋转
+    app.on(THING.EventType.LeaveLevel, function () {
+        stopRotate();
+    })
+    // 鼠标滑轮事件,停止旋转
+    app.on(THING.EventType.MouseWheel, function () {
+        stopRotate();
+    })
+    // 场景添加键盘按下事件,当进入第一人称行走时,按下esc键退出第一人称行走
+    app.on(THING.EventType.KeyDown, function (ev) {
+        if (ev.code == 'Escape') {
+            if (box != null) {
+                app.resumeEvent(THING.EventType.DBLClick, '*', THING.EventTag.LevelEnterOperation);
+                app.resumeEvent(THING.EventType.Click, '*', THING.EventTag.LevelBackOperation);
+                box.destroy();
+                box = null;
+                $('#moveByFps').removeClass('active');
+                restarRotate();
+            }
+            if (fpsCtrl != null) {
+                exitFps();
+                restarRotate();
+            }
+            checkBtnActives(['#mapBg', '#sceneSetting']);
+        }
+    });
+    window.onresize = function () {
+        if (!checkFull()) {
+            //要执行的动作
+            if (fullScreenState == true) {
+                $('.btn-full-screen').css('display', 'block');
+                $('.btn-narrow').css('display', 'none');
+                $('#fullScreen span').text('全屏');
+                fullScreenState = false;
+            }
+        }
+    }
+}
+
+
+//====设备闪烁提示====
+function flash(objArray) {
+    objArray.forEach(function (obj) {
+        obj.on('update', function () {
+            obj.style.color = '#FFF000'
+            obj.style.opacity = 0.5 + 0.5 * Math.sin(2 * app.elapsedTime / 500);
+        }, '每帧改变透明度');
+    })
+}
+function queryDeviceStatus(evt) {
+    objArray = evt.data;
+    // objArray.forEach(function (deviceobj) {
+    //     obj = app.query("#" + deviceobj.ownerCode)[0];
+    //     obj.on('update', function () {
+    //         obj.style.color = '#FF0000'
+    //         obj.style.opacity = 0.5 + 0.5 * Math.sin(2 * app.elapsedTime / 500);
+    //     }, '每帧改变透明度');
+
+
+    // })
+    obj = app.query("#" + objArray)[0];
+    obj.on('update', function () {
+        obj.style.color = '#FF0000'
+        obj.style.opacity = 0.5 + 0.5 * Math.sin(2 * app.elapsedTime / 500);
+    }, '每帧改变透明度');
+}
+function reset(objArray) {
+    objArray.forEach(function (obj) {
+        obj.style.opacity = 1.0;
+        obj.style.color = null;
+        obj.off('update', null, '每帧改变透明度');
+    })
+}
+var timer = null;
+function getTabledata(d) {
+    var ygArray = [];
+    d.forEach(function (d) {
+        var deviceInfo = {
+            "设备编号": d.ownerCode,
+            "设备名称": d.ownerName,
+            "安装位置": d.unitinfo,
+        };
+        ygArray.push(deviceInfo)
+    })
+    // 表格数据//创建对象 book
+    var tableData = {
+
+        // 列标题
+        props: ['设备编号', '设备名称', '安装位置'],
+        // 列数据
+        items: ygArray
+    };
+    return tableData;
+}
+function createPerson(name, age, family) {
+    var o = new Object();
+    o.name = name;
+    o.age = age;
+    o.family = family;
+    o.say = function () {
+        alert(this.name);
+    }
+    return o;
+}
+function destroyPanel() {
+    var mydiv = document.getElementById('mydiv')
+    mydiv.remove();
+}
+//====================
+function updateData(obj) {
+
+    /** ******************* 以下为websoket数据对接 ********************/
+    // 对接自有websoket服务器
+    if (!webSocket) {
+        // 如果网站是 https 则对应 wss
+        // 如果网站是 http 则对应 ws 即可
+        webSocket = new WebSocket('ws://101.133.214.75:8080/Device_Manager/socket');
+        // 建立 websocket 连接成功触发事件
+        webSocket.onopen = function () {
+
+        };
+        // 接收服务端数据时触发事件
+        webSocket.onmessage = function (evt) {
+            queryDeviceStatus(evt);
+        };
+        webSocket.onclose = function (evt) {
+
+            webSocket = null;
+        }
+    }
+}
+//接收父级页面数据
+function userListener(data) {
+    buildingStore = data.data;
+}
+
+// 监听用户页面传回的数据 并调用 ThingJS 页面方法
+window.addEventListener('message', function (e) {
+    
+
+    var _this=this;
+    var array;
+    var data = e.data;
+    // console.log(JSON.stringify(data))
+    
+    var funcName = data.funcName;
+    var param = data.param;
+    var company_code = e.data.param.company_code
+    // 调用 ThingJS 页面方法
+    window[funcName](param);
+    //请求场景url的json文件
+    $.ajax({
+        type: "GET",
+        url:'/uploads/wechat/163607/file/杨浦16/park.json',
+        dataType: "json",
+        success: function (data) {
+            for(let i = 0; i < data.array.length; i++){
+                if(company_code === data.array[i].id){
+                    campusUrl = data.array[i]
+                    _this.changeScene(campusUrl);
+                    _this.createWidgets();
+                }
+            }
+        }
+    });
+});
+
+//父级页面数据处理
+function cleanObj(arr, key) {
+    var map = {},
+        dest = [];
+    for (var i = 0; i < arr.length; i++) {
+        var ai = arr[i];
+        if (!map[ai.min_level]) {
+            dest.push({
+                min_level: ai.min_level,
+                item: [ai]
+            });
+            map[ai.min_level] = ai;
+        } else {
+            for (var j = 0; j < dest.length; j++) {
+                var dj = dest[j];
+                if (dj.min_level == ai.min_level) {
+                    dj.item.push(ai);
+                    break;
+                }
+            }
+        }
+    }
+    return dest;
+}
+function uniq(array) {
+    var temp = []; //一个新的临时数组
+    for (var i = 0; i < array.length; i++) {
+        if (temp.indexOf(array[i]) == -1) {
+            temp.push(array[i]);
+        }
+    }
+    return temp;
+}
+
+//设备点位标识
+// function createDeviceElement(deviceType, floorNum) {
+//     removeMark();
+//     let data = cleanObj(buildingStore);
+//     for (var i = 0; i < data.length; i++) {
+//         if (data[i].min_level == floorNum) {
+//             let arry = data[i].item;
+//             for (var q = 0; q < arry.length; q++) {
+//                 if (arry[q].dwtype == deviceType) {
+//                     let devicename = arry[q].device_name;
+//                     let dwtype = arry[q].dwtype;
+//                     var ownercode = arry[q].owner_code
+//                     var textAndPictureMarkerHtml =
+//                         `<div  class="textAndPictureMarker" onclick="deviceIcon_click('${dwtype}','${floorNum}','${ownercode}')" style="position: absolute;">
+// 			<div class="text" style="color: #FF0000;font-size: 12px;text-shadow: white  0px 2px, white  2px 0px, white  -2px 0px, white  0px -2px, white  -1.4px -1.4px, white  1.4px 1.4px, white  1.4px -1.4px, white  -1.4px 1.4px;margin-bottom: 5px;">
+// 				`+ devicename + `
+// 			</div>
+// 			<div class="picture" style="height: 30px;width: 30px;margin: auto;">
+// 				<img src="/guide/examples/images/navigation/pointer.png" style="height: 100%;width: 100%;">
+// 			</div>
+// 		</div>`;
+//                     $('#div3d').append($(textAndPictureMarkerHtml));
+//                     createUIAnchor(floorNum);
+//                 }
+
+//             }
+//         }
+//     }
+// }