i'll go ahead with allowing customization and overriding of FormSupport it'll be easier to try and test several probable solutions then
Jesse Kuhnert wrote: > I started implementing a solution for this but reverted it as I felt > like I > was attacking too much at once. > > If you did something like this it would probably solve the problem: > > -) Don't change Form's method of generating unique id. (it already > uses the > global IRequestCycle IdAllocator + special logic for portlets. > > -) Initialize the FormSupportImpl IdAllocator instance with a namespace > value of the Form's clientId/name . > > -) Create a new reserved hidden input field parameter to store the unique > form id in so that you can properly initialize the IdAllocator in > FormSupport during rewind. > > -) Your factory idea for FormSupport sounds good to me. > > On 11/14/06, andyhot <[EMAIL PROTECTED]> wrote: >> >> Recent updates on clientId generation look quite good so far! >> >> http://issues.apache.org/jira/browse/TAPESTRY-1131 >> "Hidden Component (maybe all FormComonents?) don't get ids assigned on a >> page basis" >> still occurs. >> >> It's the case where a page has many forms, and since every form item >> gets >> a name and id that is unique inside each form, we don't yet guarantee >> that >> it is also unique per page (we don't use the page idAllocator) >> >> So, apart from prefixing ids with the form clientId (as i had >> suggested), >> is there any other solution? >> >> Also, i find it odd that each Form creates its own FormSupport >> in protected FormSupport newFormSupport(IMarkupWriter writer, >> IRequestCycle cycle) >> >> This doesn't allow me to 'inject' a custom FormSupportImpl. I'd prefer >> having the >> Form delegating the process to a FormSupportFactory service that i can >> easily override. >> >> >> -- >> Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr >> Tapestry / Tacos developer >> Open Source / J2EE Consulting >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > -- Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr Tapestry / Tacos developer Open Source / J2EE Consulting --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
