|
@@ -160,9 +160,9 @@ export default {
|
|
|
if (floor == "g80") {
|
|
|
// 屋顶
|
|
|
if (window.FENGMAP.frImg) {
|
|
|
- // const pj = this.urlMsg.fmapID.split('_')[0]
|
|
|
- // // 单张图片
|
|
|
- // if (!ProjectRf[pj]) {
|
|
|
+ const pj = this.urlMsg.fmapID.split('_')[0]
|
|
|
+ // 单张图片
|
|
|
+ if (!ProjectRf[pj]) {
|
|
|
const imgItem = new SImageItem(
|
|
|
null,
|
|
|
`${this.mapServerURL}/webtheme/${this.urlMsg.fmapID}/${window.FENGMAP.frImg}`
|
|
@@ -173,29 +173,29 @@ export default {
|
|
|
});
|
|
|
this.scene.addItem(imgItem);
|
|
|
this.view.scene = this.scene;
|
|
|
- // } else {
|
|
|
- // // 多张图
|
|
|
- // try {
|
|
|
- // // 初始化0
|
|
|
- // this.count = 0;
|
|
|
- // ProjectRf[pj].forEach(t => {
|
|
|
- // const item = new SImageItem(
|
|
|
- // null,
|
|
|
- // `${this.mapServerURL}/webtheme/${this.urlMsg.fmapID}/${t.name}`
|
|
|
- // );
|
|
|
- // item.width = t.width
|
|
|
- // item.height = t.height
|
|
|
- // item.moveTo(t.x, t.y)
|
|
|
- // item.connect("imgLoadOver", this, () => {
|
|
|
- // this.countRf(ProjectRf[pj].length);
|
|
|
- // });
|
|
|
- // this.scene.addItem(item);
|
|
|
- // })
|
|
|
- // this.view.scene = this.scene;
|
|
|
- // } catch(e) {
|
|
|
- // console.log(e);
|
|
|
- // }
|
|
|
- // }
|
|
|
+ } else {
|
|
|
+ // 多张图
|
|
|
+ try {
|
|
|
+ // 初始化0
|
|
|
+ this.count = 0;
|
|
|
+ ProjectRf[pj].forEach(t => {
|
|
|
+ const item = new SImageItem(
|
|
|
+ null,
|
|
|
+ `${this.mapServerURL}/webtheme/${this.urlMsg.fmapID}/${t.name}`
|
|
|
+ );
|
|
|
+ item.width = t.width
|
|
|
+ item.height = t.height
|
|
|
+ item.moveTo(t.x, t.y)
|
|
|
+ item.connect("imgLoadOver", this, () => {
|
|
|
+ this.countRf(ProjectRf[pj].length);
|
|
|
+ });
|
|
|
+ this.scene.addItem(item);
|
|
|
+ })
|
|
|
+ this.view.scene = this.scene;
|
|
|
+ } catch(e) {
|
|
|
+ console.log(e);
|
|
|
+ }
|
|
|
+ }
|
|
|
} else {
|
|
|
// 屋顶图不为图片
|
|
|
this.readBaseMap(floor);
|
|
@@ -345,6 +345,7 @@ export default {
|
|
|
// 顶楼为多张图时计数器
|
|
|
countRf(len) {
|
|
|
this.count++
|
|
|
+ console.log(len == this.count);
|
|
|
if (len == this.count) {
|
|
|
this.readGraph();
|
|
|
} else {
|