I am working on a "ExtendedFormManager" which groups a form, several bindings and data models together. The use case is to specify e.g. a form which initializes from a "database model" with binding A and upon submit stores itself into the "database model" with binding B and additionally into a "mailto model" with binding C, thus storing and sending an email. The "ExtendedFormManager" should manage the whole thing together as painlessly as possible, it should be a Service, and should be created from a configuration file automatically when a form is needed.
One Situation is in the form template, where you get the form through a JXPath expression. Something like the following would be nice there: <ft:form-template location="ExtendedFormManagerHelper.getForm($request, 'MyExtendedForm')"> where ExtendedFormManagerHelper.getForm is a static method that does the Service lookup and initialization. For this to work, I need to get the ServiceManager in order to get to my ExtendedFormManager Service. According to the code (FormsPipelineConfig.createConfig), the JXPath context only has variables for continuation, request, session and parameters. Leszek Gawron <[EMAIL PROTECTED]> 22.07.2004 15:13 Please respond to [EMAIL PROTECTED] To [EMAIL PROTECTED] cc Subject Re: Getting the ServiceManager from Request? Jochen Kuhnle wrote: > I need it in a JXPath expression, where the JX context ist created by > cocoon (cform's binding manager), and this context does not contain the > service manager. are you talking about custom binding? if so you can implement it in javascript and you do not need a service manager because you could do cocoon.getComponent but I may be wrong -- Leszek Gawron [EMAIL PROTECTED] Project Manager MobileBox sp. z o.o. +48 (61) 855 06 67 http://www.mobilebox.pl mobile: +48 (501) 720 812 fax: +48 (61) 853 29 65
