Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 1.1
-
Fix Version/s: 1.3
-
Component/s: HTML Generation
-
Labels:None
-
Application server:Websphere 5.1
Description
The caption of a table is not rendered correctly in version 1.1. No attributes of the caption tag is rendered. This works in version 1.0. I have debugged the code, and it seems that the ELCaptionTag is released, in which the attributeMap is cleared, before the tableTag has written the html.
So the captionTag is set on the tableTag, but is cleared before it is used by the tableTag for rendering html.
The following code:
<div class="adresse">
<display:table id="item" name="sessionScope.sessionScopePerson.adresser" sort="list" class="tabell-helskjermbredde">
<display:setProperty name="basic.msg.empty_list_row">
<tr>
<td class="standard_data_tabell_data_venstre" colspan="{0}">
<fmt:message key="tabell.tomliste" />
</td>
</tr>
</display:setProperty>
<display:caption class="overskrift">
<fmt:message key="ord.adresse" />
</display:caption>
<display:column titleKey="ord.adresselinje" headerStyleClass="beskrivelse" class="standard_data_tabell_data" sortable="false" property="adresselinje" decorator="no.nav.personkort.web.formatter.CapitalizeDecorator" />
</display:table>
</div>
renders the following html:
<div class="adresse">
<table class="tabell-helskjermbredde" id="item">
<caption class="overskrift">
Adresse
</caption>
<thead>
<tr>
<th class="beskrivelse">
Adresselinje
</th>
<tbody>
<tr>
<td class="standard_data_tabell_data_venstre" colspan="1">
Søket ga ingen treff
</td>
</tr>
</tbody>
</table>
</div>
The class attribut of the captionTag is not rendered at all.
This is a bug, right?
So the captionTag is set on the tableTag, but is cleared before it is used by the tableTag for rendering html.
The following code:
<div class="adresse">
<display:table id="item" name="sessionScope.sessionScopePerson.adresser" sort="list" class="tabell-helskjermbredde">
<display:setProperty name="basic.msg.empty_list_row">
<tr>
<td class="standard_data_tabell_data_venstre" colspan="{0}">
<fmt:message key="tabell.tomliste" />
</td>
</tr>
</display:setProperty>
<display:caption class="overskrift">
<fmt:message key="ord.adresse" />
</display:caption>
<display:column titleKey="ord.adresselinje" headerStyleClass="beskrivelse" class="standard_data_tabell_data" sortable="false" property="adresselinje" decorator="no.nav.personkort.web.formatter.CapitalizeDecorator" />
</display:table>
</div>
renders the following html:
<div class="adresse">
<table class="tabell-helskjermbredde" id="item">
<caption class="overskrift">
Adresse
</caption>
<thead>
<tr>
<th class="beskrivelse">
Adresselinje
</th>
<tbody>
<tr>
<td class="standard_data_tabell_data_venstre" colspan="1">
Søket ga ingen treff
</td>
</tr>
</tbody>
</table>
</div>
The class attribut of the captionTag is not rendered at all.
This is a bug, right?
I see that I have posted something wrong in this issue. In the generated html I have submitted, the caption tag has a class attribute. This is of cource wrong. The point of the defect is that this class attribute og the caption tag is NOT rendered. :-)
When is version 1.1.1 due for release? We need this fix in my project :-)