I'm sorry, read replacing "Simfony2" with "Symfony2" :-P
On Nov 20, 11:41 am, HTC <[email protected]> wrote: > Hi all, > I didn't find anything clear on how to use Forms and entities in > Simfony2. > > Currently I'm using Doctrine to persist entities but this could change > (for > example using another framework or whatever solution the customer want > to implement). > > I have just started with Simfony2 and looking to the simple Forms > documentation > on the web site. > > I have an entity MyProduct that is composed by some simple stuff > (date, strings, > numbers) and some reference to other application entities (like > ProductType and > ProductCategory). > > It's a good idea to extend the Form class in order to create a > MyProductForm (that > I can reuse in multiple places like Ajax controllers and others view > instead to re-instatiante > a basic Form and configure it on the fly) that is able to deal with my > own entities > (like MyProductType and MyProductCategory). > > It's a good idea implement MyProductTypeField and MyProductCategory > fields > in order to do check on database for validations and to customize the > ->render() of > > the form (that in entities reference case will have an hidden input > with the ID and > a title/name to show it to the user?). > > Thanks in advance for your feedbacks. > > Bye > -- > Alberto -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups "symfony users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
