ソースを参照

feat: 1. FileUpload组件默认去掉删除供能 2. log组件bug fix 3. 可见光转红外优化

WANGKANG 8 ヶ月 前
コミット
bcc31d9f65

+ 4 - 2
src/components/Upload/File.vue

@@ -37,7 +37,7 @@
             {{ file.name }}
           </span>
         </el-link>
-        <div class="ele-upload-list__item-content-action">
+        <div class="ele-upload-list__item-content-action" v-if="canRemove">
           <el-link :underline="false" @click="handleRemove(index)" type="danger">删除</el-link>
         </div>
       </li>
@@ -66,6 +66,7 @@ interface UploadFileProps {
   icon?: string
   fileType?: Array<string>
   uploadApiPath?: string // 上传文件服务器地址
+  canRemove: boolean // 是否显示删除按钮
 }
 
 // 默认值
@@ -79,7 +80,8 @@ const props = withDefaults(defineProps<UploadFileProps>(), {
   text: '文件上传',
   isShowTip: true,
   uploadApiPath: '/common/upload',
-  icon: 'upload-filled'
+  icon: 'upload-filled',
+  canRemove: false
 })
 
 const baseUrl = import.meta.env.VITE_API_URL

+ 2 - 1
src/views/demo/components/ViewLog.vue

@@ -68,11 +68,12 @@ const handleOpen = id => {
 }
 
 const eventWheel = event => {
-  console.log(event)
+  // console.log(event)
   // event.preventDefault()
   if (event.deltaY < 0) {
     // console.log('检测到向上滚轮,停止自动滚动')
     isAutoScroll.value = false
+    stopScroll()
   }
 }
 const handleClose = () => {

+ 1 - 1
src/views/demo/toInfrared/index.vue

@@ -64,7 +64,7 @@
           link
           icon="View"
           v-auth="['demo:ToInfrared:download']"
-          v-if="scope.row.status == '2'"
+          v-if="scope.row.status == '2' && scope.row.type == AlgorithmType2['训练']"
           @click="showToInfraredModel(scope.row.id)"
         >
           模型