-
Notifications
You must be signed in to change notification settings - Fork 27
allow KeyValueContainer objects to be passed as key-value arrays #158
allow KeyValueContainer objects to be passed as key-value arrays #158
Conversation
Nice, i will delete my PR :-), yours is better and recognized the the form option too. |
->add('extraHttp', 'burgov_key_value', array('required' => false, 'value_type' => 'text')) | ||
->add('extraProperties', 'burgov_key_value', array('required' => false, 'value_type' => 'text', 'use_container_object' => true)) | ||
->add('extraNames', 'burgov_key_value', array('required' => false, 'value_type' => 'text', 'use_container_object' => true)) | ||
->add('extraHttp', 'burgov_key_value', array('required' => false, 'value_type' => 'text', 'use_container_object' => true)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you change to one parameter per line for the options array, please. getting longer now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated
I decided to keep it D.R.Y. ;)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
even better :-)
@@ -79,19 +81,19 @@ public function setTitle($title); | |||
public function getTitle(); | |||
|
|||
/** | |||
* @param array | |||
* @param array|KeyValueContainer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it OK like this, or should I remove the use statement and use FQDN's for all three methods?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, you did it the correct way :)
thx, I've updated the commit |
allow KeyValueContainer objects to be passed as key-value arrays
thanks a lot for finding this solution! |
created a follow-up PR in #159 about the traversable topic - i understood it does not work with the form layer, but it could be useful elsewhere. |
fixed issues described in #255