Commit Graph

1234 Commits

Author SHA1 Message Date
Jordi Boggiano
b2bd7ce57d [Validator] Skipping AnnotationLoader tests if doctrine-common is not present 2010-11-18 06:59:09 +01:00
Jordi Boggiano
b3ae62e2c4 [Finder] Fixed tests on windows 2010-11-18 06:59:05 +01:00
Jordi Boggiano
a0f933163f [Console] Fixing tests breaking on windows 2010-11-18 06:59:01 +01:00
Fabien Potencier
69d2568339 [HttpKernel] fixed typo in a unit test 2010-11-17 17:10:50 +01:00
Bernhard Schussek
46145d8de7 [Validator] Fixed exception thrown in Valid constraint to be thrown only when the options are not empty 2010-11-17 10:55:48 +01:00
Bernhard Schussek
940ce9aedf [Validator] Group "Default" is now propagated to validated references when group sequences are validated
This conforms to JSR303 (see version 1.0 final, page 39).
2010-11-17 08:02:10 +01:00
Bernhard Schussek
6a148465da [Validator][Form] Removed support for match-all group "*"
The constraint "Valid" does not accept any options or groups anymore. As per
JSR303 1.0 final, section 3.5.1 "Object graph validation" (page 39),
properties  annotated with valid should be cascaded independent of the current
group (i.e. always). Thus the group "*" is not necessary anymore and was
removed from the "Valid" constraint in the Form validation.xml.
2010-11-17 08:02:06 +01:00
Bernhard Schussek
8df966f507 [Validator] Made class Constraint abstract because it must not be instantiated 2010-11-17 08:02:03 +01:00
Bernhard Schussek
1bbdb5ec07 [Form][FrameworkBundle][TwigBundle] Refactored the PHP and Twig templating layer
Support for theming in PHP templates has been dropped.

True theming should support theme inheritance, e.g. mytheme <- table <- default.
Currently, the Templating component does not support such inheritance. As the
only purpose of the themes so far was to style field groups with tables or
divs, and because automatic rendering of field groups/forms through the render()
method is discouraged and only recommended for rapid prototyping, themes are
dropped for now.
2010-11-16 22:26:35 +01:00
Fabien Potencier
23d7967f81 [FrameworkBundle] fixed phpunit when ran from the app directory directly without -c 2010-11-16 11:17:42 +01:00
Bernhard Schussek
3127312139 [Form] Added option 'value_transformer' and 'normalization_transformer' to Field class 2010-11-16 07:28:33 +01:00
Bernhard Schussek
ece9691d5a [Form] Fixed documentation typo 2010-11-16 07:28:29 +01:00
Jordi Boggiano
c6dbbb857a [Form] Removed dead code 2010-11-16 07:28:24 +01:00
Jordi Boggiano
fbc29f061c [Form] Coding style fixes 2010-11-16 07:28:20 +01:00
Jordi Boggiano
b8987e1bde [DoctrineBundle] Form transformers shouldn't explode if they're passed null as a value 2010-11-16 07:28:17 +01:00
Jordi Boggiano
0bdb271608 [Form] Added parent calls to all configure() methods of Fields and Transformers
The calls that were on top of the function have also been moved to the bottom for safety (see previous commit)
2010-11-16 07:28:12 +01:00
GordonsLondon
23ac47e011 [Form] Added support for __get and __set in PropertyPath 2010-11-16 07:28:07 +01:00
Benjamin Eberlei
5aeb358721 [Validator] Made the namespace prefix for annotations configurable
Modified the framework bundle to use validation => Symfony\Component\Validator\Validator defaults.
Enhanced Framework Extension validator configuration to allow to extend this configuration with
user-specified annotations, for example:

    validation:
        enabled: true
        annotations:
            namespaces:
                myprojectvalidator: MyProject\Validator\

to register @myprojectvalidator:Validator(...)
2010-11-16 07:28:02 +01:00
Fabien Potencier
0131ff21c5 [Translation] removed unneeded assignement 2010-11-16 07:22:39 +01:00
Jordi Boggiano
3cbc99c180 [Translation] Added flatten method on ArrayLoader
This allows the translations to be deeply nested arrays that will be flattened, allowing for namespacing of translations easily.

The following:
  'key' => array('key2' => array('key3' => 'value'))
Becomes:
  'key.key2.key3' => 'value'

This isn't applied to Xliff since it does not make sense within the scope of the XLIFF standard
2010-11-16 07:20:57 +01:00
Fabien Potencier
4e5c99dab0 [EventDispatcher] removed the possibility to remove one listener for an event 2010-11-15 23:14:36 +01:00
Jordi Boggiano
d9295058b1 [FrameworkBundle] Make the security context optional 2010-11-15 18:32:02 +01:00
Jordi Boggiano
aa1b2efb15 [TwigBundle] Base form templates now using div instead of tables 2010-11-15 15:04:56 +01:00
Jordi Boggiano
d45954af07 [Form][TwigBundle] Making sure all field types are rendered with the proper template 2010-11-15 14:54:11 +01:00
Fabien Potencier
f21c58c56b [FrameworkBundle] finished code migration after the removal of the ArrayAccess interface for the Container 2010-11-15 11:13:01 +01:00
Fabien Potencier
f6cc63c99c removed ArrayAccess interface for Container and Controller 2010-11-15 10:05:28 +01:00
Fabien Potencier
53dd4e39c7 [DependencyInjection] changed the YAML notation for optional services from @@ to @? 2010-11-15 10:00:59 +01:00
Fabien Potencier
92f3d9e7ec [DependencyInjection] removed the leading _ for anonymous service ids (the usage of strtr() in the conversion between ids and methods does not take leading _ into account like camelize() does) 2010-11-15 09:56:20 +01:00
Fabien Potencier
a45baed812 [HttpFoundation] removed optimization for setLocale() as it breaks when locale is not the default and the user wants to switch back to the default locale 2010-11-15 09:50:01 +01:00
Ryan Weaver
58a240baba [HttpFoundation] Allow the SERVER_PORT key of the server ParameterBag in Request to be a string value without confusing Request::getHttpHost().
The idea of a string port is probably semantically wrong, but it actually follows the convention of at least some web servers ($_SERVER['SERVER_PORT'] is actually a string). And since the $port variable is used as a string in getHttpHost(), it's correct to allow the types not to match.
2010-11-15 09:45:59 +01:00
Kris Wallsmith
6428544cd8 [DoctrineMongoDBBundle] added a phpdoc block 2010-11-15 09:43:39 +01:00
Kris Wallsmith
b932441ac9 [DoctrineMongoDBBundle] added ability to register global listeners and subscribers via the DIC 2010-11-15 09:43:32 +01:00
Kris Wallsmith
da188734d8 [DoctrineMongoDBBundle] added support for multiple event managers to the DIC extension 2010-11-15 09:42:45 +01:00
Kris Wallsmith
9ab33e4ae4 [DoctrineMongoDBBundle] added registration of event listeners and subscribers via service container tags 2010-11-15 09:40:28 +01:00
Fabien Potencier
519cc09488 [Translation] added some unit tests for the new YAML loader 2010-11-15 09:37:04 +01:00
Jordi Boggiano
3813eecf17 [Translation] Added YamlFileLoader 2010-11-15 09:33:00 +01:00
Jordi Boggiano
f2107e4b3a [Translation] Explicitly mark methods as public 2010-11-15 09:29:18 +01:00
Ryan Weaver
81272b22fa [HttpFoundation] Adding PHPDoc to the Request class and removing two unused variables. 2010-11-13 16:03:57 +01:00
Jordi Boggiano
7bf77cb500 [FrameworkBundle] Add comment to clarify the request service issue 2010-11-13 14:50:32 +01:00
Francis Besset
35148c5ac3 [FrameworkBundle] added routing internationalization
In your routing.yml:

homepage:
    pattern:  /:_locale
    defaults: { _controller: MyBundle:MyController:index, _locale: en }
    requirements: { _locale: (en|fr) }

In your PHP template:

<?php echo $view['session']->getLocale() ?>
2010-11-13 14:33:47 +01:00
Fabien Potencier
6f898a5008 [HttpKernel] made some tests more robust 2010-11-13 12:29:14 +01:00
Fabien Potencier
4aa5ef63f5 [HttpKernel] made some tests more robust 2010-11-13 12:22:38 +01:00
Fabien Potencier
98f3ac65f4 fixed configuration bugs 2010-11-12 20:11:22 +01:00
Fabien Potencier
7257571be4 [HttpFoundation] added missing code for last commit 2010-11-12 19:49:01 +01:00
Fabien Potencier
942104a5ff [HttpFoundation] added a setCache() method to ease setting the HTTP cache headers in one simple call 2010-11-12 19:46:39 +01:00
Fabien Potencier
f669674293 [HttpFoundation] added a missing phpdoc 2010-11-12 19:46:22 +01:00
Fabien Potencier
f6ddeeb36b [HttpFoundation] added Response::setPublic() and changed setPrivate() to not take any argument 2010-11-12 19:45:28 +01:00
Fabien Potencier
8b9e979118 [FrameworkBundle] changed configuration to always include the session service 2010-11-12 19:35:21 +01:00
jeff
69cd21d8be [Validator] Fixed annotation loader to not add parent constraints twice 2010-11-12 17:56:09 +01:00
Bernhard Schussek
48b3e92504 [Form] Fixed: parent::configure() should always be called after adding options to overrule options in the parent class 2010-11-12 17:55:52 +01:00