[ 
https://issues.apache.org/jira/browse/WICKET-4153?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Sander Plas updated WICKET-4153:
--------------------------------

    Attachment: addCenterToolbar.patch

@Bertrand: a toolbar does not add itself, but it is explicitly added to the 
DataTable by the user by calling the addTopToolbar or addBottomToolbar methods 
on the DataTable. 

So if we want to be able to add toolbars to the tbody, we'll have to modify 
DataTable. 

It's quite easy to add a third ToolbarContainer besides topToolbars and 
bottomToolbars (centerToolbars or something) to DataTable, located between the 
tbody tags. 

I don't know whether this would be considered a desirable change though? 

I have attached a patch for this change to DataTable (+ the call to 
addCenterToolbar in DefaultDataTable). 
                
> The tbody section of a DataTable is empty when no records are returned by the 
> provider.
> ---------------------------------------------------------------------------------------
>
>                 Key: WICKET-4153
>                 URL: https://issues.apache.org/jira/browse/WICKET-4153
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-extensions
>    Affects Versions: 1.5.1
>            Reporter: Bertrand Guay-Paquet
>            Priority: Trivial
>              Labels: datatable
>             Fix For: 1.5.3
>
>         Attachments: DataTable-usePlainTR.diff, DataTable.patch, 
> DataTableTest-usePlainTR.diff, addCenterToolbar.patch, good.png, 
> with_patch.png, without_patch.png
>
>
> When a DataTable is rendered without records, the tbody section is empty. 
> This violates the html spec.
> From the spec:
> "When present, each THEAD, TFOOT, and TBODY contains a row group. Each row 
> group must contain at least one row, defined by the TR element."
> and
> "The THEAD, TFOOT, and TBODY sections must contain the same number of 
> columns."

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to