myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Leonardo Uribe <lu4...@gmail.com>
Subject Re: Tomahawk Partial rerender datatable column
Date Fri, 26 Oct 2012 15:53:46 GMT
Hi

I think in this case the problem is related to richfaces. In this page:

http://docs.jboss.org/richfaces/latest_3_3_X/en/devguide/html/a4j_region.html

Says this:

"... Starting from RichFaces 3.2.0 the <a4j:region> can be used together
with iterative components (e.g. <rich:column> or <rich:scrollableDataTable>
 , etc.). It became possible to re-render a particular row in a table without
updating the whole table and without any additional listeners. ..."

In JSF 2.0, f:ajax works well with tomahawk, and the code between tomahawk
1.2 and 2.0 is very similar, so I would assume the limitation is related to
a4j:region tag.

Maybe write the code without wrap the t:outputText inside a a4j:region could
work.

regards,

Leonardo Uribe

2012/10/26 daniel ccss <danielccss2@gmail.com>:
> Thanks Michael,
>
> I want to update the outputtext value that is in the same row of the
> selectBooleanCheckbox inside a datatable, yes in RichFaces is easy to do
> this, partial update of the datapage, but I'm using Tomahawk JSF 1.2, and
> right now we can´t migrate.
>
> Yes as a matter of fact I put the region around the outputtext as a test,
> sorry about that.
>
> I don´t want to update the hole datatable, if I rerender the hole datatable
> using this <a4j:support event="onchange" reRender="*data*"/> it works, the
> value of the outputtext is updated on the change event of the
> selectBooleanCheckbox because the hole datatable is rerender, but I dont
> want to rerender the hole datatable, I only want to update the the
> outputtext that is in the same row of the selectBooleanCheckbox that was
> checked.
>
> Really hope you can help me
>
>
>
> On Fri, Oct 26, 2012 at 1:07 AM, Michael Heinen <mhn4dev@googlemail.com>wrote:
>
>> Do you want to update a complete column or a single cell in the same row?
>> Which versions (MyFaces, Richfaces) do you use?
>>
>> Richfaces doesn't like the forceId attribute in many cases. Try to remove
>> it from the datatable.
>> And the region around the outputtext with textVehiclename does not make
>> any sense.
>>
>> Michael
>>
>>
>> Am 26.10.2012 04:23, schrieb daniel ccss:
>>
>>> Anybody????
>>>
>>> On Thu, Oct 25, 2012 at 8:54 AM, daniel ccss <danielccss2@gmail.com>
>>> wrote:
>>>
>>>  Hi, hope you can help me, Is there a way of update only one column of the
>>>> datatable using a4j, not updating all the datatable.
>>>>
>>>> Im Using myfaces (Tomahawk)
>>>>
>>>>
>>>> This is what I have, a <h:selectBooleanCheckbox that when is clicked the
>>>> onchange event is fire and rerender an <h:outputText
>>>>
>>>>
>>>>   <t:dataTable id="data" forceId="true"
>>>> binding="#{VehicleBean.**dataTableVehicle}"
>>>>                           var="vehicleTable"
>>>> value="#{VehicleBean.**vehicleList}" preserveDataModel="false"
>>>>  rows="10">
>>>>                <t:column>
>>>>                       <a4j:region>
>>>>                          <h:selectBooleanCheckbox .....>
>>>>                            <a4j:support event="onchange" reRender="*
>>>> textVehicleName*"/>
>>>>
>>>>                          </h:selectBooleanCheckbox>
>>>>                      </a4j:region>
>>>>             </t:column>
>>>>
>>>>            <t:column>
>>>>                        <a4j:region>
>>>>                              <t:outputText id="*textVehicleName*"
>>>>
>>>> value="#{vehicleTable.name}"/>
>>>>                        </a4j:region>
>>>>          </t:column>
>>>> </t:dataTable>
>>>>
>>>> That code doesn´t work, If I put the outputText outside the datatable or
>>>> if i refresh al the datatable it works, but I don´t want to update all
>>>> the
>>>> datatable, I want a partial rerender of only one column, hope you can
>>>> help
>>>> me thanks!!!
>>>>
>>>>
>>

Mime
View raw message