On Wed, 16 Jun 2010 16:18:12 -0300, Jim O'Callaghan <jc1000...@yahoo.co.uk> wrote:

Thiago, given that approach, where an entity with structure (Long id, String desc) is being translated, would you mind suggesting the best approach to access the id of my entity <not the field id or tapestry id> from within the parseClient method of the relevant translator?

I would attempt to use the Environmental service to do that.

even putting something in a threadlocal, but if there is a better / safer way I would be interested to hear it, or to hear if this approach is not suitable for my use case. Getting the client value (the entity's desc field) back in parseClient is working correctly, but if I don’t have the existing entity id my persistence layer assigns a new one.

Why don't you create a single form field component that edits this entity class, put all this logic there and then use it inside your edition block?

--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to