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

如果无文件隐藏批量下载按钮

SanHQin 1 год назад
Родитель
Сommit
043e55b9b8
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/components/pages/test/check/index.vue

+ 1 - 1
src/components/pages/test/check/index.vue

@@ -95,7 +95,7 @@
                     :class="{ test_icon_check: item.type == 1 && item.atype == 2, test_icon_checkO: item.type == 1 && item.atype == 1, test_icon_gap: item.type == 3, test_icon_file: item.type == 5, test_course_file: item.type == 6, test_eva_file: item.type == 7 }"></span>
                 </el-tooltip>
                 <span>{{ item.title }}</span>
-								<el-button v-if="item.type == 5" class="title_downBtn" type="primary" size="small" @click.stop="downloadFileType5(item.array,item.title)">批量下载附件</el-button>
+								<el-button v-if="item.type == 5 && item.array.length>0" class="title_downBtn" type="primary" size="small" @click.stop="downloadFileType5(item.array,item.title)">批量下载附件</el-button>
               </div>
               <div class="detail" v-if="item.detail">{{ item.detail }}</div>
               <div class="content1" v-if="item.type == 1">