<
Depuis la version < 7.6 >
modifié par Paul Libbrecht (admin)
sur 2016/08/19 21:35
À la version < 7.2 >
modifié par Paul Libbrecht (admin)
sur 2016/08/19 20:52
>
Commentaire de modification : Il n'y a aucun commentaire pour cette version

Résumé

Détails

Icon Propriétés de la Page
Contenu
... ... @@ -29,14 +29,12 @@
29 29   for(Attachment att in pageDoc.getAttachmentList()) {
30 30   System.err.println("Outputting " + att.filename);
31 31   ZipEntry entry = new ZipEntry(att.filename);
32 - if(uncompressedMimes.contains(att.mimeType))
32 + entry.setTime(att.getDate().getTime());
33 + entry.setSize(att.filesize);
34 + if(uncompressedMimes.contain(att.mimeType))
33 33   entry.setMethod(ZipEntry.STORED);
34 34   else
35 35   entry.setMethod(ZipEntry.DEFLATED);
36 - entry.setTime(att.getDate().getTime());
37 - System.err.println("Size: " + att.filesize);
38 - entry.setSize(att.filesize);
39 -
40 40   out.putNextEntry(entry);
41 41   IOUtils.copy(att.contentInputStream, out, 5*1024*1024);
42 42   }
... ... @@ -51,7 +51,7 @@
51 51  } else {
52 52   println("""
53 53  = Download Attachments Macro =
54 -Use as ((({{downloadAttachments/}}))) so see a list of attachments.
52 +Use as ~{~{downloadAttachments/~}~} to see a link to a zip of all attachments.
55 55  """);
56 56  }
57 57  
This wiki is licensed under a Creative Commons 2.0 license
XWiki 13.10 - Documentation - Conditions