Parcourir la source

Merge branch 'dev' of http://39.106.8.246:3003/web/ibms into dev

haojianlong il y a 5 ans
Parent
commit
2c124fc13d

+ 13 - 10
src/components/ledger/details/detail/lookFile.vue

@@ -21,10 +21,12 @@
                   <p> {{delFile(item.CreateTime)}}</p>
                 </div>
                 <div class="file-box-right ">
-                  <span
-                    style="height: 88px;"
+                  <a
+                    style="height: 88px;cursor: pointer;color: #555"
                     class="iconfont icon-download1 df fs20"
-                    @click="download(item.Key)"/>
+                    :href="`/image-service/common/file_get/${item.Key}?systemId=dataPlatform`"
+                    :download="item.Name"
+                  />
                 </div>
               </div>
 
@@ -49,17 +51,10 @@
     created() {
     },
     methods: {
-
       //处理地址
       delFile(name) {
         return name && name.length > 20 ? name.substring(0, 20) + "..." : name
       },
-      //点击下载
-      download(key) {
-        console.log(key)
-        window.open("/image-service/common/file_get/" + key + "?systemId=dataPlatform")
-      },
-
       //删除图片
       deleteFile(i, key) {
         this.filesArr.splice(i, 1);
@@ -139,6 +134,11 @@
 
 <style lang="less" scoped>
   .exhibition-file {
+    .icon-download1:hover {
+      color: #409eff;
+      cursor: pointer;
+    }
+
     .title {
       /*border-left: 8px solid black;*/
       margin: 10px;
@@ -191,6 +191,9 @@
         width: 19%;
         height: 100%;
         overflow: hidden;
+        a:hover {
+          color: #409eff !important;
+        }
       }
     }
 

+ 8 - 5
src/components/ready/buildfloor/addBuild.vue

@@ -117,7 +117,7 @@
       class="dialog-footer"
       slot="footer">
     <el-button @click="buildDialogVis = false">取 消</el-button>
-    <el-button @click="submitForm('ruleForm')" type="primary">确 定</el-button>
+    <el-button @click="submitForm('ruleForm')" type="primary" :disabled="buildDisabled">确 定</el-button>
   </span>
     <el-dialog :visible.sync="dialogVisible">
       <img width="100%" :src="dialogImageUrl" alt="">
@@ -171,16 +171,17 @@
           ]
         },
         buildData: {},
+        buildDisabled: false,
       }
     },
     components: {uploadFiles, uploadImgs},
     props: ['buildTitle', 'buildMessage', 'currentBuild'],
-    computed: {
-    },
+    computed: {},
     mounted() {
 
 
     },
+    watch: {},
     methods: {
       deepCopy(obj) {
         return JSON.parse(JSON.stringify(obj))
@@ -224,7 +225,7 @@
       submitForm(formName) {
         this.$refs[formName].validate((valid) => {
           if (valid) {
-            console.log(this.form);
+            this.buildDisabled = true
             for (let key in this.buildMessage) {
               let arr = this.buildMessage[key];
               if (Array.isArray(arr)) {
@@ -239,7 +240,9 @@
               }
             }
             this.$emit('handleBuild', this.form)
-
+            setTimeout(() => {
+              this.buildDisabled = false
+            }, 2500)
           } else {
             return false;
           }

+ 6 - 1
src/views/ledger/spacelist/spaceDetail/index.vue

@@ -62,7 +62,7 @@
 <script>
   import {mapGetters} from "vuex";
   import tools from "@/utils/scan/tools";
-  import {zoneDelete, getDataDictionary, zoneQuery} from '@/api/scan/request';
+  import {getDataDictionary, zoneDelete, zoneQuery} from '@/api/scan/request';
 
   import eqToSpaceTable from '@/components/business_space/newTables/eqToSpaceTable';
   import syInSpaceTable from '@/components/business_space/newTables/syInSpaceTable';
@@ -314,13 +314,17 @@
       //处理数据格式
       arr.map(i => {
         if (i.InputMode == 'F2') {
+          console.log(i.Path)
           switch (i.Path) {
             case 'LedgerParam.PhotoDoc.Drawing':
             case 'LedgerParam.Siteinstall.InstallPic':
             case 'LedgerParam.Siteinstall.InstallDrawing':
             case 'LedgerParam.PhotoDoc.Nameplate':
+            case 'Pic' :
+
               if (this.instance.hasOwnProperty(i.Path)) {
                 i.PicList = this.instance[i.Path]
+
               }
               if (picObject[i.InfoPointName]) {
 
@@ -338,6 +342,7 @@
       })
       //展示图片
       this.exhibitionImage.list = picObject
+
       let isArray = [] //获取图片数组
       for (let i in picObject) {
         if (Array.isArray(picObject[i])) {

+ 20 - 16
src/views/ready/buildfloor/addFloor/index.vue

@@ -5,26 +5,26 @@
     </el-row>
     <span slot="footer" class="dialog-footer">
       <el-button size="small" @click="dialogVisible=false">取消</el-button>
-      <el-button size="small" type="primary" @click="confirm">确认</el-button>
+      <el-button size="small" type="primary" @click="confirm" :disabled="disabled">确认</el-button>
     </span>
   </el-dialog>
 </template>
 <script>
-    import {manageCreateFloor, manageUpdateFloor} from "@/api/scan/request";
-    import formItems from "@/components/ready/buildfloor/formItems";
-    import tools from "@/utils/buildfloor/tools";
+  import {manageCreateFloor, manageUpdateFloor} from "@/api/scan/request";
+  import formItems from "@/components/ready/buildfloor/formItems";
+  import tools from "@/utils/buildfloor/tools";
 
-    export default {
-      props: {
-        title: {
-          default: '提示'
-        },
-        type: {
-          default: 'Floor'
-        },
-        curBuildId: {
-          default: ''
-        },
+  export default {
+    props: {
+      title: {
+        default: '提示'
+      },
+      type: {
+        default: 'Floor'
+      },
+      curBuildId: {
+        default: ''
+      },
         curFloorId: {
           default: ''
         }
@@ -35,7 +35,8 @@
       data() {
         return {
           dialogVisible: false, //弹窗显示与隐藏
-          floorData: {}
+          floorData: {},
+          disabled: false
         };
       },
       methods: {
@@ -61,6 +62,7 @@
         handleClose() { },
         //创建
         confirm() {
+          this.disabled = true
           this.$refs.formItems.submitForm(this.save)
         },
         save() {
@@ -75,12 +77,14 @@
               this.$message.success('更新成功')
               this.$emit('refresh')
               this.dialogVisible = false;
+              this.disabled = false
             })
           } else {
             manageCreateFloor(Param, res => {
               this.$message.success('创建成功')
               this.$emit('refresh')
               this.dialogVisible = false;
+              this.disabled = false
             })
           }
         }

+ 16 - 6
src/views/ready/buildfloor/index.vue

@@ -105,11 +105,18 @@
       @handleBuild="handleBuild"
     />
     <!-- 删除建筑-删除楼层 -->
-    <el-dialog :visible.sync="delDialogVis" @close="handleClose" id="messageDialog" title="提示" width="20%">
+    <el-dialog
+      :visible.sync="delDialogVis"
+      @close="handleClose"
+      id="messageDialog"
+      title="提示"
+      width="20%"
+
+    >
       <div>确定要删除该{{delText}}?</div>
       <span class="dialog-footer" slot="footer">
         <el-button @click="delDialogVis=false" size="small">取消</el-button>
-        <el-button @click="confirmDel" size="small" type="primary">确认</el-button>
+        <el-button @click="confirmDel" size="small" type="primary"  :disabled="buildDisabled">确认</el-button>
       </span>
     </el-dialog>
     <!-- 添加贯通关系弹窗 -->
@@ -151,6 +158,7 @@
         floorTitle: "添加楼层",
         buildTitle: "添加建筑",
         delDialogVis: false,
+        buildDisabled: false,
         delText: "建筑",
         headerStyle: {
           backgroundColor: "#d9d9d9",
@@ -354,10 +362,12 @@
       },
       // 确认删除(删除建筑-楼层公用)
       confirmDel() {
+        this.buildDisabled = true
         if (this.delText == "楼层") {
           let delParam = [{FloorID: this.curFloorId}];
           manageDeleteFloor(delParam, res => {
             this.$message.success("删除成功");
+            this.buildDisabled = false
             this.delDialogVis = false;
             this.init();
           });
@@ -367,14 +377,14 @@
           if (this.tableData && this.tableData.length) {
             this.$message.error("当前建筑中包含楼层,不可删除");
             this.delDialogVis = false;
+            this.buildDisabled = false
           } else {
             let param = [{BuildId: this.curBuildId}];
             objectDeleteBuild(param, res => {
-              setTimeout(() => {
-                this.handleBuildQuery()
-                this.init()
-              })
+              this.handleBuildQuery()
+              this.init()
               this.$message.success("删除成功");
+              this.buildDisabled = false
               this.delDialogVis = false;
             })
           }