[ http://jira.codehaus.org/browse/DISPL-501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
allan flatoff resolved DISPL-501. --------------------------------- Resolution: Fixed Fix Version/s: 1.1.1 There is a workaround - posted in comments > Column sorting is broken with a decorator > ----------------------------------------- > > Key: DISPL-501 > URL: http://jira.codehaus.org/browse/DISPL-501 > Project: DisplayTag > Issue Type: Bug > Components: Paging/Sorting > Affects Versions: 1.1.1 > Reporter: allan flatoff > Fix For: 1.1.1 > > > I created a column called "Document Title". I created a Table Decorator so I > could wrap a URL around the data (since the current linking implementation > does not support target="" in the hyperlink). > Example Decorator: > public String getDocumentTitle() { > Row currentRow = (Row)getCurrentRowObject(); > String pidString = currentRow.getPidString(); > String documentTitle = currentRow.getDocumentTitle(); > return "<a href=\"/BPView/docOpener.jsp?pid=" + pidString + "\" > target=\"_blank\" class=\"doclinks\"><nobr>" + documentTitle + "</nobr></a>"; > } > After doing this, the column no longer sorted on the data that was in my > "documentTitle" property, instead it sorted on the TEXT that was put into the > documentTitle after the decorator had been applied - so effectively I was > sorting on "pidString" instead. > Note that in the current URL linking mechanism, applying a URL does not alter > the Sorting. It still sorts on the data from the column instead of the URL > that was wrapped around the hyperlink. > Similarly, adding a decoration to a column should not have an effect on the > sort. Perhaps there could be an optional parameter sortOnDecoratedColumn or > something which would allow you to specify to sort on the actual data or the > "decorated data" for the column. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ displaytag-devel mailing list displaytag-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/displaytag-devel