-
1. Re: dataTable column width problem oddity
nbelaevski Apr 23, 2010 4:47 PM (in response to peterlen)Hi Peter,
Try "columnsWidth" attribute.
-
2. Re: dataTable column width problem oddity
peterlen Apr 23, 2010 6:52 PM (in response to nbelaevski)Nick,
Thanks for the reponse. Yeah, I tried the columnsWidth attribute as well. That works if my table was not in the modalPanel. I think the issue is really tied to having the table in a modalPanel that is autosized. When the modalPanel is sized based on a pre-determined height/width, you seem to be able to have more of the column/table attibutes triggered, but not when it is autosized. Still trying to figure it out.
- Peter
-
3. Re: dataTable column width problem oddity
ilya_shaikovsky Apr 26, 2010 10:47 AM (in response to peterlen)width attribute of rich:column and dataTable should works for that.
I checked without any width's declarations and result attached.
-
1.jpg 154.4 KB
-
-
4. Re: dataTable column width problem oddity
ilya_shaikovsky Apr 26, 2010 10:48 AM (in response to ilya_shaikovsky)show please your code. and check also css applied.
-
5. Re: dataTable column width problem oddity
peterlen Apr 26, 2010 12:58 PM (in response to ilya_shaikovsky)Ilya,
Thanks for the repsone. The behavior I am seeing in IE7 and FF2 is that the width and columnsWidth attributes are only executed if the modalPanel has a defined height and width. If it is defines with "autosized='true'", then the extra width is not rendered. Here is my code:
<rich:modalPanel id="result_table2_panel" autosized="true" styleClass="noMaskClass">
<h:panelGrid>
<rich:dataTable id=
"rt2" rows="10" value="#{Planning.resultsTable}" var="results">
<rich:column sortBy=
"#{results.name}" width="300">
<f:facet name=
"header" width="300px">
<h:outputText value
"Name" />
</f:facet>
<h:outputText value=
"#{results.name}" />
</rich:column>
<rich:column sortBy="#{results.date}" >
<f:facet name=
"header">
<h:outputText value="Date"/>
</f:facet>
<h:outputText value=
"#{results.date}"/>
</rich:column>
</rich:dataTable>
</h:panelGrid>
</rich:modalPanel>
When I switched the above the have a fixed width and height for the modalPanel, the column width attribute worked. Once I used the autosized attribute it would not work.
- Peter
-
6. Re: dataTable column width problem oddity
ilya_shaikovsky Apr 27, 2010 5:40 AM (in response to peterlen)Yes.. it was a bad test on my side.. There are stings without spaces so things was ok.. Now able to see that. And next workaround helped me:
<rich:column> <f:facet name="header"> <h:outputText value="a" /> </f:facet> <div style="width: 300px"> <h:outputText value="#{category.make} test" id="make" /> </div> </rich:column>