Просмотр исходного кода

Merge branch 'graphEq'

# Conflicts:
#	package.json
shaun-sheep 4 лет назад
Родитель
Сommit
5883afdcce

+ 2 - 2
package.json

@@ -20,9 +20,9 @@
   },
   "dependencies": {
     "@saga-web/base": "2.1.27",
-    "@saga-web/cad-engine": "2.0.575",
+    "@saga-web/cad-engine": "2.0.576",
     "@saga-web/draw": "2.1.110",
-    "@saga-web/graph": "2.1.132",
+    "@saga-web/graph": "2.1.131",
     "@saga-web/topology": "1.0.85",
     "axios": "^0.18.0",
     "echarts": "^4.1.0",

+ 2 - 2
src/views/ready/buildfloor/drawGraphy/drawFloor.vue

@@ -149,8 +149,8 @@ export default {
       let pa = {
         Filters: `FloorID='${this.FloorID}'`
       }
-      const temp = this.urlModelId.split('.')[1].toLowerCase()
-      if (temp == 'png' || temp == 'jpg') { //底图为图片且已经绑定过图片
+      const temp = this.urlModelId.split('.')[1]
+      if (temp && (temp.toLowerCase() == 'png' || temp.toLowerCase() == 'jpg')) { //底图为图片且已经绑定过图片
         floorQueryAndSign(pa, res => {
           this.floorData = res.Content[0];
           if (this.floorData.StructureInfo && this.floorData.StructureInfo.FloorMap) {

+ 3 - 2
src/views/ready/buildfloor/repetitionGraphy.vue

@@ -109,7 +109,7 @@ export default {
         if (this.modelId != '') {
             this.hasGraph = true;
             const temp = this.modelId.split('.');
-            if (temp[1].toLowerCase() == 'png' || temp[1].toLowerCase() == 'jpg') {
+            if (temp[1] && (temp[1].toLowerCase() == 'png' || temp[1].toLowerCase() == 'jpg')) {
                 // return
             } else {
                 this.init()
@@ -295,7 +295,8 @@ export default {
         },
         // 根据modelid初始化
         initFromModelId(id){
-            if (id.split('.')[1].toLowerCase() == 'png' || id.split('.')[1].toLowerCase() == 'jpg') {
+            const temp = id.split('.')[1];
+            if (temp && (temp.toLowerCase() == 'png' || temp.toLowerCase() == 'jpg')) {
                 this.$refs.drawFloor.initGraphy(id, 3)
             } else {
                 this.$refs.drawFloor.initGraphy(id, 1)