Commit Graph

1565 Commits

Author SHA1 Message Date
Bernhard Schussek
7c557d0d6e [Form] Made and parameter in the constructor optional 2010-12-16 10:18:31 +01:00
Bernhard Schussek
b8ef7e7332 [Form] Improved semantics of property paths and removed FieldGroup::merge() for now
The semantics of property paths are now:

   (1) if a property path is set, it is _always_ respected (relative to the object
       of the parent field)
   (2) if no property path is set, the object of the parent field is _always_ ignored

Fact (2) allows us to set data into fields that is updated independently of the parent
field (like CSRF tokens, subforms with different objects etc.)

What is missing now is support for subfields that pass the object of the parent field
through to their own subfields. This functionality would be needed for GoogleMapFields,
DateRangeFields etc., which are compositions of individual fields that update the
parent object of the FieldGroup.

There are several alternatives for the latter functionality that should be discussed
in a RFC.
2010-12-16 10:18:31 +01:00
Bernhard Schussek
242be933d5 [Form] Added proper error handling to FileField 2010-12-16 10:18:31 +01:00
Kris Wallsmith
fd3f4f86a5 [FrameworkBundle] fixed classname collision 2010-12-15 22:29:21 +01:00
Johannes M. Schmitt
bd7e9b022b variable name fix 2010-12-15 21:24:37 +01:00
Henrik Bjørnskov
c543626cf5 [DoctrineMongoDBBundle] Fixed DoctrineMongoDBExtension::loadConnections to follow the new constructor signature introduced with the Doctrine\\MongoDB access layer refactoring so that Doctrine MongoDB logging works againg with the WebProfilerBundle 2010-12-15 20:58:36 +01:00
Johannes Schmitt
3c692bd160 fixed user refreshing after unserialization 2010-12-15 17:38:30 +01:00
Fabien Potencier
c9f08c0a68 changed all XML attribute names to take - instead of _ (everything should be consistent now) 2010-12-14 16:30:20 +01:00
Fabien Potencier
6970a46b84 updated Twig templates for the new hash syntax 2010-12-14 09:46:24 +01:00
Fabien Potencier
9f5253e460 fixed typo 2010-12-14 07:49:55 +01:00
Bulat Shakirzyanov
ff9e9ac315 [DependencyInjection] fixed a typo in PhpDumper 2010-12-13 18:55:37 +01:00
Jordi Boggiano
bbc87b6d11 [DoctrineBundle] Fixed regression in proxy cache dir 2010-12-13 14:13:56 +01:00
Johannes M. Schmitt
b3081c79e9 CS fixes 2010-12-13 11:10:55 +01:00
Jordi Boggiano
583340db7b [HttpFoundation] Added a way to grab the request body as a resource 2010-12-13 07:55:40 +01:00
Jordi Boggiano
9fef10f67d [HttpFoundation] Fixed indenting 2010-12-13 07:53:09 +01:00
Jordi Boggiano
ac7e0bc35f [DependencyInjection] Fixes a loading order issue
ab7ad4808b introduced a regression when using a parameter in an extension config that is defined in the same file, the ParameterBag can not resolve it
2010-12-13 07:52:09 +01:00
Jordi Boggiano
84c7496565 [DoctrineBundle] Fix createOrmProxyDirectory method 2010-12-13 07:50:25 +01:00
Fabien Potencier
02a92ec297 [TwigBundle] added autoescape option in Twig configuration 2010-12-12 14:41:00 +01:00
Fabien Potencier
9644fcbb71 [FrameworkBundle] changed default name of Routing matcher class to be consistent with the generator class in cache 2010-12-12 14:24:27 +01:00
jeff
e6d0385778 [HttpFoundation] fixed Request::create() when using HTTPS and getUri()/getPathForUri() when script name should be removed.
Original explanation from pull request:

I'm Using symfony2 with URL Rewriting to 'hide' index.php.
On form authentication, symfony2 redirect to http://host:port/index.php/login_path instead of http://host:port/login_path. I do understand that, in my case, redirect is set into one of :
FormAuthenticationEntryPoint with getUriForPath()
FormAuthenticationListener with getUriForPath()
Security/Firewal/ExceptionListener with getUri()

This path modify getUri and getUriForPath to :
remove default port from URI
remove script name if not initially present
2010-12-12 14:08:35 +01:00
Lukas Kahwe Smith
30f231deaf moved default form template to the DIC config 2010-12-12 13:52:01 +01:00
Johannes Schmitt
abe8047262 added authentication trust resolver 2010-12-12 10:49:43 +01:00
Johannes Schmitt
763bba9b89 bug fix 2010-12-12 10:27:15 +01:00
Fabien Potencier
a7c81577c7 [HttpFoundation] added a way to retrieve raw body from a request 2010-12-12 09:05:03 +01:00
Fabien Potencier
5857576024 [Routing] added . as a valid character in route names 2010-12-12 08:53:49 +01:00
Fabien Potencier
7cb8dca04d [Routing] added . as a valid character in route names 2010-12-12 08:53:18 +01:00
Fabien Potencier
504463c307 [Routing] refactored code 2010-12-12 08:50:46 +01:00
Fabien Potencier
48e30537c4 added exception when a loaded YAML resource is not an array 2010-12-12 08:39:37 +01:00
Fabien Potencier
9944542811 [Security] fixed method visibility 2010-12-12 08:02:13 +01:00
mwsaz
ddd05cfce4 [FrameworkBundle] fixed 404 exception class name 2010-12-12 07:36:41 +01:00
Francis Besset
c64f331de5 [Console] Symfony 2 or Symfony2 ? 2010-12-11 22:06:47 +01:00
Johannes Schmitt
e49cc36339 This commit fixes two bugs:
- interfaces can now also be defined on containers which are built with an Extension
- interface injection can also be used on classes that require constructor arguments
2010-12-10 17:15:04 +01:00
Johannes Schmitt
cc3a783890 removed dead code 2010-12-10 16:34:20 +01:00
Bernhard Schussek
1b2ca259f1 [Validator] Fixed string-based constraint validators to accept empty values 2010-12-10 14:28:11 +01:00
Gustavo Falco
af291bb0f1 [Validator] Fixed UrlValidator to accept empty strings (closes #9297) 2010-12-10 14:28:07 +01:00
GordonsLondon
f73b6b4e1c [PropertyPath] Fixed usage of __get() and __set() when accessing properties that exist in the object but are not public 2010-12-10 14:28:04 +01:00
Bernhard Schussek
b4c359357f [FrameworkBundle] Fixed choice_field.php template to use isChoiceGroup() 2010-12-10 14:28:00 +01:00
Bernhard Schussek
e80aa9a5ab [Form] Fixed: The data in a CollectionField is resized down if fields are removed 2010-12-10 14:27:57 +01:00
Bernhard Schussek
131b3fe373 [Form] Refactored Field and FieldGroup to facilitate modifications in subclasses 2010-12-10 14:27:54 +01:00
pablodip
984a857a96 [Validator] fixed the static method loader to not repeat the loading when the static method is in the parent classes 2010-12-10 14:27:49 +01:00
Jeremy Mikola
c8c9fba7d9 [Routing] Add optional "type" param for loader hinting when resource strings are ambiguous
Currently, ambiguities only arise for PHP files, as PhpFileLoader and AnnotationFileLoader would both claim support.  Future conflicts may occur if the XML, YAML, or PHP loaders were to receive Directory and Glob loaders (as annotations have).

Since the "type" parameter is optional, loader resolution will default to awarding resolution to the first loader to claim support.  A previous hack in PhpFileLoader to avoid an AnnotationFileLoader conflict was removed, so that should be the only lost backwards compatibility with this patch.  Unit tests were also created for the various loader classes, although only the supports() method is being tested.

This implementation was proposed on the symfony-dev mailing list in response to Fabien's RFC for custom loader notation: http://groups.google.com/group/symfony-devs/browse_thread/thread/3104c1a9e45799d2/20fbe393c1afe088
2010-12-10 09:48:10 +01:00
Fabien Potencier
0c0853c636 fixed unit tests 2010-12-10 09:30:44 +01:00
Fabien Potencier
b3149a235b [HttpKernel] fixed request management in HttpKernel 2010-12-10 09:30:32 +01:00
Fabien Potencier
bff58d14d7 [HttpKernel] fixed request management in HttpKernel 2010-12-10 09:24:14 +01:00
Fabien Potencier
da26584735 [HttpKernel] fixed request management in HttpKernel 2010-12-10 09:21:31 +01:00
Fabien Potencier
55bed307f1 removed HttpException base class, refactored FlattenException class 2010-12-10 09:16:42 +01:00
Fabien Potencier
23fbd87164 [HttpKernel] removed UnauthorizedHttpException as this should be handled by the Security component 2010-12-10 09:02:26 +01:00
Fabien Potencier
131776001f removed ForbiddenHttpException
Both HttpKernel and Security define a 403 exception:

* Symfony\Component\HttpKernel\Exception\ForbiddenHttpException
* Symfony\Component\Security\Exception\AccessDeniedException

The one in HttpKernel has been removed in favor of the Security one.
2010-12-10 09:00:06 +01:00
Fabien Potencier
d036448542 [HttpKernel] simplified code 2010-12-10 08:50:45 +01:00
Ryan Weaver
be94daba66 [HttpKernel] Reworking the HttpException class constructor to be more consistent with normal OO classes. Additionally, the base HttpException constructor was changed to require a code argument as it doesn't make sense to create an exception that will translate into a status code of 0 (in fact it'll cause a strange error). 2010-12-10 08:47:25 +01:00