Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2010-03-29 Thread Ulrich Stärk
Unless someone modifies the DOM and sets it to true. So in your page class you also want to make sure that the value is not updated when readonly is set to true. Uli On 29.03.2010 23:13, aash wrote: i spent hours and hours trying to figure out why TextField didn't simply have a 'readonly' par

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2010-03-29 Thread aash
i spent hours and hours trying to figure out why TextField didn't simply have a 'readonly' parameter, which would fix this issue. the answer was pretty simple, and caused me to utter a heartfelt "UGH!" you CAN use readonly. it just gets passed from the TextField thing to the tag.

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread manuel aldana
Thiago H. de Paula Figueiredo schrieb: Em Sat, 18 Apr 2009 13:00:19 -0300, manuel aldana escreveu: Yes, but as you said it is a workaround and looks not good inside the template. I think it is quite a common formular use-case, that some data columns are displayed but are read only during edi

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread Thiago H. de Paula Figueiredo
Em Sat, 18 Apr 2009 13:00:19 -0300, manuel aldana escreveu: Yes, but as you said it is a workaround and looks not good inside the template. I think it is quite a common formular use-case, that some data columns are displayed but are read only during editing a data-item (e.g. id, email, use

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread manuel aldana
Thiago H. de Paula Figueiredo schrieb: I see, but how do I set a property to be read only? Sorry, I misundestood your question. Answer: you don't set a property to be read only. The workaround is to override an edition block with . Yes, but as you said it is a workaround and looks not good insi

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread Thiago H. de Paula Figueiredo
Em Sat, 18 Apr 2009 12:42:33 -0300, manuel aldana escreveu: I see, but how do I set a property to be read only? Sorry, I misundestood your question. Answer: you don't set a property to be read only. The workaround is to override an edition block with . Maybe it would be cool to add a ne

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread manuel aldana
Thiago H. de Paula Figueiredo schrieb: Em Sat, 18 Apr 2009 07:38:53 -0300, manuel aldana escreveu: Generally I would need something more flexible how to tell whether a parameter is read-only or editable inside the form. For my current problem the read-only vs. editable depends on roles (i.e.

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread Thiago H. de Paula Figueiredo
Em Sat, 18 Apr 2009 07:38:53 -0300, manuel aldana escreveu: Generally I would need something more flexible how to tell whether a parameter is read-only or editable inside the form. For my current problem the read-only vs. editable depends on roles (i.e. different roles have different acces

Re: [bean-edit-form] make a sub-set of parameters visible but not editable

2009-04-18 Thread Ulrich Stärk
Add a block for the cell you want to have non-editable and just output its value. Something along ${foo.bar} public boolean isHasEditRights() { return user.inRole(FOO_ROLE) || user.inRole(BAR_ROLE); } HTH, Uli manuel aldana schrieb: H