Browse Source

fix: 计量附件当前节点和所有附件checkbox选中状态的逻辑bug

lanjianrong 4 years ago
parent
commit
dfb2089a39
1 changed files with 1 additions and 18 deletions
  1. 1 18
      app/public/js/stage.js

+ 1 - 18
app/public/js/stage.js

@@ -3451,32 +3451,15 @@ $(document).ready(() => {
     // 批量下载
     $('#bach-download').click(function() {
         const fileIds = []
-        $('.tab-pane.active .list-table .check-file:checked').each(function() {
+        $('.tab-pane.active.show .list-table .check-file:checked').each(function() {
             const fileId = $(this).attr('file-id')
             fileId && fileIds.push(fileId)
         })
-        console.log('fileIds', fileIds)
 
         if (fileIds.length) {
             const url = `/tender/${tender.id}/measure/stage/${stage.order}/download/compresse-file?fileIds=${JSON.stringify(fileIds)}`
             $('#zipDown').attr('href', url)
             $("#zipDown")[0].click()
-            // 执行请求
-            // postData('/tender/' + tender.id + '/measure/stage/' + stage.order + '/download/compresse-file', { fileIds }, function(data) {
-            //     console.log(data)
-            // })
-            // $.ajax({
-            //     type:"get",
-            //     // url: '/tender/' + tender.id + '/measure/stage/' + stage.order + '/download/compresse-file',
-            //     url: `/tender/${tender.id}/measure/stage/${stage.order}/download/compresse-file?fileids=${JSON.stringify(fileids)}`,
-            //     dataType: 'json',
-            //     cache: false,
-            //     // 告诉jQuery不要去设置Content-Type请求头
-            //     contentType: false,
-            //     // 告诉jQuery不要去处理发送的数据
-            //     processData: false,
-            //     timeout: 60000,
-            // })
         }
     });