haojianlong 4 سال پیش
والد
کامیت
dc4b9a33a2
2فایلهای تغییر یافته به همراه6 افزوده شده و 5 حذف شده
  1. 1 1
      src/views/ready/buildfloor/drawGraphy/drawFloor.vue
  2. 5 4
      src/views/ready/buildfloor/repetitionGraphy.vue

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

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

+ 5 - 4
src/views/ready/buildfloor/repetitionGraphy.vue

@@ -3,7 +3,7 @@
     <div id='repetitionGraphy'>
         <div class='buttons'>
             <el-button icon='el-icon-back' size='mini' @click='backRouter'></el-button>
-            <template v-if="!!hasModel">
+            <template v-if="!hasModel">
                 <el-upload class='upload-demo' action='string' :http-request='uploadAndSubmit' :show-file-list='false' v-if="step==-1">
                     <el-button size="mini">{{hasGraph?'替换平面图图片':'上传平面图图片'}}</el-button>
                 </el-upload>
@@ -109,7 +109,7 @@ export default {
         if (this.modelId != '') {
             this.hasGraph = true;
             const temp = this.modelId.split('.');
-            if (temp[1] == 'png' || temp[1] == 'jpg') {
+            if (temp[1].toLowerCase() == 'png' || temp[1].toLowerCase() == 'jpg') {
                 // return
             } else {
                 this.init()
@@ -184,7 +184,7 @@ export default {
             this.modelId = modelId
             this.hasGraph = true;
             const temp = this.modelId.split('.');
-            if (temp[1] && temp[1] != 'png' && temp[1] != 'jpg') {
+            if (temp[1] && temp[1].toLowerCase() != 'png' && temp[1].toLowerCase() != 'jpg') {
                 this.key = '';
                 this.getFileName(this.modelId)
             }
@@ -295,7 +295,7 @@ export default {
         },
         // 根据modelid初始化
         initFromModelId(id){
-            if (id.split('.')[1] == 'png' || id.split('.')[1] == 'jpg') {
+            if (id.split('.')[1].toLowerCase() == 'png' || id.split('.')[1].toLowerCase() == 'jpg') {
                 this.$refs.drawFloor.initGraphy(id, 3)
             } else {
                 this.$refs.drawFloor.initGraphy(id, 1)
@@ -354,6 +354,7 @@ export default {
             if (v.StructureInfo && v.StructureInfo.FloorMap) {
                 const url = this.imgService + v.StructureInfo.FloorMap
                 this.curImgItem = new SImageItem(null, url);
+                this.curImgItem.enabled = false;
                 this.curImgItem.globalAlpha = 0.2;
                 this.curImgItem.showType = SImageShowType.AutoFit;
                 if (v.Properties) {