Jelajahi Sumber

修改文件预览

zhuliu 2 tahun lalu
induk
melakukan
2d27ed999b

+ 1 - 1
RMS-FrontEnd/src/App.vue

@@ -70,7 +70,7 @@ export default {
   mounted() {
     var time = new Date(this.$c.updateTime).getTime()
     var time2 = new Date().getTime()
-    if(time2 < time){
+    if(time2 < time && !localStorage.canShow){
         this.$router.push({path: '/'})
         return false
     }

+ 1 - 1
RMS-FrontEnd/src/config/index.js

@@ -1,7 +1,7 @@
 const doname = /^([\w-]+\.)+((com)|(net)|(org)|(gov\.cn)|(info)|(cc)|(com\.cn)|(net\.cn)|(org\.cn)|(name)|(biz)|(tv)|(cn)|(mobi)|(name)|(sh)|(ac)|(io)|(tw)|(com\.tw)|(hk)|(com\.hk)|(ws)|(travel)|(us)|(tm)|(la)|(me\.uk)|(org\.uk)|(ltd\.uk)|(plc\.uk)|(in)|(eu)|(it)|(jp))$/;
 export default {
     baseURL: "/api",
-    updateTime:'2023-08-04 08:00:00',
+    updateTime:'2023-08-16 13:48:00',
     host: window.location.host,
     hostname: window.location.hostname,
     staticURL: process.env.NODE_ENV === 'production' ? window.location.protocol+'//'+window.location.hostname+':8084' : (process.env.NODE_ENV === 'test'?'http://139.224.24.90:8083':'http://192.168.1.24:8084'),

+ 1 - 1
RMS-FrontEnd/src/views/components/articles/components/history/HistoryOfInvalidEvidence.vue

@@ -33,7 +33,7 @@
         <el-table-column label="附件" prop="files" align="center">
             <template slot-scope="scope">
                 <span>
-                    <span v-if="scope.row.files">
+                    <span v-if="scope.row.files  && scope.row.files.length>0">
                         <div v-for="item in scope.row.files" style="margin:0;display:flex;justify-content:space-around;align-items:center;">
                             <p style="margin:0;width:calc(100% - 40px);overflow: hidden;white-space: nowrap;text-overflow:ellipsis;cursor: pointer">{{item.name?item.name+'.'+item.suffix:item.fileName}}</p> 
                             <Menu :data="item" @delFile="delFile(scope.row,item.id,1)"></Menu>

+ 4 - 1
RMS-FrontEnd/src/views/components/common/menu/component/checkFile.vue

@@ -42,7 +42,7 @@ export default {
     },
     mounted(){
         this.FileName = this.row.name?this.row.name+'.'+this.row.suffix:this.row.fileName
-        if(this.isPicture){
+        if(this.isPicture == 1){
             this.srcList = [this.FileUrl]
         }else{
             var that = this
@@ -51,6 +51,9 @@ export default {
                 a.onload = function() {
                     that.loadLoading = false
                 };
+                if(a.contentDocument.readyState == 'complete'){
+                    that.loadLoading = false
+                }
             })
         }
         

+ 1 - 1
RMS-FrontEnd/src/views/components/common/menu/mixins.js

@@ -36,7 +36,7 @@ export const File = {
                     var FileUrl = item.url
                     var isPicture = 0
                 }else{
-                    var FileUrl =  `http://${this.$c.hostname}:8012/onlinePreview?url=`+ btoa(encodeURIComponent(item.url))
+                    var FileUrl =  `http://${this.$c.hostname}:8012/onlinePreview?url=`+ btoa(encodeURIComponent(item.url+ '&fullfilename=test.'+item.suffix))
                     var isPicture = 0
                 }
                 const router = this.$router.resolve({

+ 4 - 0
RMS-FrontEnd/src/views/index/index.vue

@@ -26,6 +26,7 @@ export default {
             if(that.input == 'xiaoshi'){
               that.show = false
               clearInterval(that.timer)
+              localStorage.canShow = true
               that.$router.push(
                 {
                   name: 'Login',
@@ -46,6 +47,9 @@ export default {
     var time2 = new Date().getTime()
     if(time2>=time){
       this.show = false
+      if(localStorage.canShow){
+        localStorage.canShow = false
+      }
       this.$router.push({path: '/admin/login'})
     }else{
       this.show = true