Skip to content

Explain how to properly override choices #7990

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 10, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions reference/forms/types/country.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@ choices
The country type defaults the ``choices`` option to the whole list of countries.
The locale is used to translate the countries names.

.. caution::

If you want to override the built-in choices of the country type, you
will also have to set the ``choice_loader`` option to ``null``. Not doing
so is deprecated since Symfony 3.3.

Inherited Options
-----------------

Expand Down
6 changes: 6 additions & 0 deletions reference/forms/types/currency.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ choices

The choices option defaults to all currencies.

.. caution::

If you want to override the built-in choices of the currency type, you
will also have to set the ``choice_loader`` option to ``null``. Not doing
so is deprecated since Symfony 3.3.

Inherited Options
-----------------

Expand Down
6 changes: 6 additions & 0 deletions reference/forms/types/language.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ choices
The choices option defaults to all languages.
The default locale is used to translate the languages names.

.. caution::

If you want to override the built-in choices of the language type, you
will also have to set the ``choice_loader`` option to ``null``. Not doing
so is deprecated since Symfony 3.3.

Inherited Options
-----------------

Expand Down
6 changes: 6 additions & 0 deletions reference/forms/types/locale.rst
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ choices
The choices option defaults to all locales. It uses the default locale to
specify the language.

.. caution::

If you want to override the built-in choices of the locale type, you
will also have to set the ``choice_loader`` option to ``null``. Not doing
so is deprecated since Symfony 3.3.

Inherited Options
-----------------

Expand Down
6 changes: 6 additions & 0 deletions reference/forms/types/timezone.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,12 @@ choices
The Timezone type defaults the choices to all timezones returned by
:phpmethod:`DateTimeZone::listIdentifiers`, broken down by continent.

.. caution::

If you want to override the built-in choices of the timezone type, you
will also have to set the ``choice_loader`` option to ``null``. Not doing
so is deprecated since Symfony 3.3.

Inherited Options
-----------------

Expand Down