Download the PHP package evolutto/gregwar-form without Composer
On this page you can find all versions of the php package evolutto/gregwar-form. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download evolutto/gregwar-form
More information about evolutto/gregwar-form
Files in evolutto/gregwar-form
Package gregwar-form
Short Description Provides the "entity_id" type (read "entity identifier")
License MIT
Informations about the package gregwar-form
Gregwar's FormBundle
GregwarFormBundle
provides the form type "entity_id"
Installation
To install GregwarFormBundle
, run composer require evolutto/gregwar-form
.
Then, register the bundle in the application kernel :
Finally, add the following block to the configuration :
# app/config/config.yml
gregwar_form: ~
Usage
The entity_id is a field that contains an entity id, this assumes you set up javascripts or any UI logics to fill it programmatically.
The usage look like the entity field type one, except that the query builder have to returns one unique result. One full example :
Note that if you don't provide any query builder, ->find($id)
will be used.
You can also chose to show the field, by passing the hidden
option to false
:
Using the property
option, you can also use another identifier than the primary
key:
Notes
There is maybe bugs in this implementations, this package is just an idea of a form field type which can be very useful for the Symfony2 project.
License
This bundle is under MIT license
All versions of gregwar-form with dependencies
symfony/form Version ~2.3|~3.0
symfony/validator Version ~2.3|~3.0
symfony/property-access Version ~2.3|~3.0
doctrine/orm Version ~2.2,>=2.2.3