File tree Expand file tree Collapse file tree 1 file changed +28
-0
lines changed
Expand file tree Collapse file tree 1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -76,6 +76,20 @@ The actual default value of this option depends on other field options:
7676
7777.. include :: /reference/forms/types/options/form_attr.rst.inc
7878
79+ ``getter ``
80+ ~~~~~~~~~~
81+
82+ **type **: ``callable `` **default **: ``null ``
83+
84+ When provided, this callable will be invoked to read the value from
85+ the underlying object that will be used to populate the form field.
86+
87+ More details are available in the section on :doc: `/form/data_mappers `.
88+
89+ .. versionadded :: 5.2
90+
91+ Form mapping callbacks were added in Symfony 5.2.
92+
7993.. include :: /reference/forms/types/options/help.rst.inc
8094
8195.. include :: /reference/forms/types/options/help_attr.rst.inc
@@ -112,6 +126,20 @@ The actual default value of this option depends on other field options:
112126
113127.. include :: /reference/forms/types/options/required.rst.inc
114128
129+ ``setter ``
130+ ~~~~~~~~~~
131+
132+ **type **: ``callable `` **default **: ``null ``
133+
134+ When provided, this callable will be invoked to map the form value
135+ back to the underlying object.
136+
137+ More details are available in the section on :doc: `/form/data_mappers `.
138+
139+ .. versionadded :: 5.2
140+
141+ Form mapping callbacks were added in Symfony 5.2.
142+
115143.. include :: /reference/forms/types/options/trim.rst.inc
116144
117145.. include :: /reference/forms/types/options/validation_groups.rst.inc
You can’t perform that action at this time.
0 commit comments