|
[
Permalink
| « Hide
]
Jorge L. Barroso added a comment - 22/Feb/06 07:24 AM
I'll have a look.
I am also having this problem. I verified that adding the export filter does not help. This is a big problem, as I am currently writing a story about Displaytag for an online magazine, and I planned to highlight the export feature in the article. Please give this problem your highest attention.
Much thanks! Stephen I'll have a solution soon.
The conflict lies in that the new Excel, PDF, and RTF table writers are meant to behave just as the HTML table writer does. So it defaults to observing the list size, sorting, and grouping of the html page to suport WYSIWYG exports. But the "legacy" exporting configuration properties should definitely be supported. Perhaps, adding the following kind of functionality would be the best solution in the end. From: http://jira.codehaus.org/browse/DISPL-245 ======================================================= 4. Export just the current page, a page range, or all data, especially if paging is used. The ui may look like this: Export options: Excel | PDF | RTF | From: [1] To: [1] (default to this page Export options: Excel | PDF | RTF | From: [1] To: [max] (default to all) Defaults to exporting what's on the page currently. Default would be configurable through property. ======================================================= But for now the easiest solution might be to introduce non-WYSIWYG Excel, PDF, and RTF exports that simply obey all the "legacy" exporting config properties. Users can then choose one or the other. > But for now the easiest solution might be to introduce non-WYSIWYG Excel, PDF, and RTF exports that simply obey all the "legacy" exporting config properties. Users can then choose one or the other.
I am afraid that I don't know how to do this. Do you have any examples that I could mimic? Stephen This patch makes WYSIWYG exports observe the export.amount config setting.
The distrubution default setting for export.amount is list. To export just the current page, change this setting to export.amount=page. The line numbers in the patch I submitted depend on the the patch for http://jira.codehaus.org/browse/DISPL-298 .
I need this fix to export the whole list to excel. When will 1.1.1 version be released? I need the displaytag1.1.1.jar please.
Thanks -S Hi to all,
Jorge, is the jar file you have posted compiled with a 5.0 JVM? I tried to replace the displaytag distribution with the jar you posted nad i got version incompatibilities issues. Most exactly, this error: "java.lang.UnsupportedClassVersionError:(Unsupported major.minor version 49.0)" Maybe I'm doing something wrong. thanks in advance Jorge Sorry, it seems Celso posted the jar but was not able to see his message.
Hi.
i also have this error "java.lang.UnsupportedClassVersionError:(Unsupported major.minor version 49.0)", i need a jar that work with minor version that 49.0. i have a 1.4 java version, i think that the version of jvm is 48.0. thanks Javi Fixed by Jaume,
This jar show all list in pdf work with j2sdk1.4.2_07 and Tomcat 4.1 thanks Jaume + 1 for this patch. I've tested also on the trunk version and it seems to works...
Hi All,
I've just started using display tag Libraries. I successfully managed to do everything with the libraries. But now I'm having the same export problem as mentioned above. Can you please let me know how to handle this problem. Should I download the patch, that's mentioned here and then change my displaytag library jar version 1.1.1 to this jar file. Please advice. The jar file that I'm using is more recent then the patch jar file mentioned here. Thanks, Harry Hi Harry,
Just download my patch file. I'm using java 1.5 and runs fine. Best regards. Jaume Guillamon,
Still unable to fix this issue. I cannot export all records when the display pages are paginated. I have deleted the jar files for 1.1.1 that I downloaded from the sourceforge.net web site and replaced them with that of yours (two jar files that you provide above, when I try to use only just one of the jar files, the pages don't even open up). There were no issues until here. I changed the jsp's as <display:table name="someSessionList" export="true" class="dataTable" defaultorder="ascending" cellspacing="1" pagesize="100"> <display:setProperty name="export.excel.export_amount" value="list"></display:setProperty> <display:setProperty name="export.pdf.export_amount" value="list"></display:setProperty> <display:column title="someTitle" property="someProperty" ... I am displaying 1000 records paginated as 100 per page. When I click pdf or excel export, I get only 100 records? Here is my displaytag.properties file # sort.behavior=list # sort.amount=list #basic.empty.showtable=true basic.msg.empty_list=No results matched your criteria. paging.banner.placement=top #paging.banner.onepage=<span class="pagelinks"></span> export.types=csv excel xml pdf rtf export.excel=true export.csv=true export.xml=true export.pdf=true export.rtf=true export.excel.class=org.displaytag.export.excel.DefaultHssfExportView export.pdf.class=org.displaytag.export.DefaultPdfExportView export.rtf.class=org.displaytag.export.DefaultRtfExportView # if set, file is downloaded instead of opened in the browser window #export.[mymedia].filename= export.banner=</div><div class="exportlinks">Export options: {0}</div> Any suggestions why I am unable to export all the records? By the way, I see verions 1.2, 1.3, and 1.4. Where do I get these? Thanks Krishna Sorry about my previous post, it was confusing. Anyways, for others, I think just copying your TableTag.java patch into your own TableTag.java will do the work!!!
Now I get the java heap space error when exporting decorated. Any work around for this I believe I have to look up my Tomcat and not displayTag libraries? wonder if there is anything in displayTag that I can optimize for memory?? I am using my custom decorators to include the header, footer, images, and most importantly grouping, sorting, and sub totaling on any of the fields in the pdf, excel exports!!!. Will put this up here for others to comment and use very soon!!! By the way, I see verions 1.2, 1.3, and 1.4. Where do I get these? Cheers Krishna Hi, all
Sorry about my poor english, it's not my natural language. The problem with "DISPL-292 Export to Excel, PDf y RTF doesn't export all the LIST" in version 1.2 is caused for the class PaginationHelper, and also is necesary the path proposed "DISPL-292-displaytag-patch.txt" by "Jorge L. Barroso". The problem with class PaginationHelper is that in the constructor of the class, it haven't got any parameter refer to "especial pagination relation with export", by default always is the same "size of pagination". Then the Iterator that return the method "getIterator()" is minor of the size o all my list to export. I can't publish my solution, because it's a concrete solution for my problem, but the only I did it was to include the parameter boolean "export.amount" (this.properties.getExportFullList()) in the construtor for build the correct Iterator of my List with all values, if it is a export table. The call to the class PaginationHelper, in the class TableTag, is in the line 1098: ------------------------------------------------------------- 1098: PaginationHelper paginationHelper = new PaginationHelper(pageNumber, pagesize); ------------------------------------------------------------- Cheers. Carlos I solved this problems without patches by simply doing something like
if (null != request.getParameter(TableTagParameters.PARAMETER_EXPORTING)) { paginatedList.setObjectsPerPage(paginatedList.getFullListSize()); } Hope this helps. Ops. "paginatedList" above is of course my own implementation of org.displaytag.pagination.PaginatedList
Hi!
I have the same problem too - exporting with partial list -. I solved it modifying TableTag class, leave the assign of variable "tableIterator" as version 1.1.1 (always this.tableIterator = IteratorUtils.getIterator(this.list) ). ¿What 's the function of PaginationHelper? The partial list just have all the items to render o to export. Sorry for my bad english :-( Germán Hi,
Even I have the same problem - exporting only 10 records per page (as I've listed only 10 records per page). Can someone help me to sort this issue. Pls. also tell the list of all jars that need to be included. thanx in advance |
|||||||||||||||||||||||||||||||||||||||||||||