Skip to content

Commit

Permalink
feature #11314 document the input option of the NumberType (xabbuh)
Browse files Browse the repository at this point in the history
This PR was merged into the master branch.

Discussion
----------

document the input option of the NumberType

see symfony/symfony#30893

#FOSSHackathons #EUFOSSA

Commits
-------

c004dc5 document the input option of the NumberType
  • Loading branch information
wouterj committed Apr 7, 2019
2 parents 0cba12e + c004dc5 commit d403f97
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions reference/forms/types/number.rst
Expand Up @@ -13,6 +13,7 @@ that you want to use for your number.
+-------------+----------------------------------------------------------------------+
| Options | - `grouping`_ |
| | - `html5`_ |
| | - `input`_ |
| | - `scale`_ |
| | - `rounding_mode`_ |
+-------------+----------------------------------------------------------------------+
Expand Down Expand Up @@ -59,6 +60,21 @@ html5
If set to ``true``, the HTML input will be rendered as a native HTML5 ``type="number"``
form.

input
~~~~~

**type**: ``string`` **default**: ``number``

.. versionadded:: 4.3

The ``input`` option was introduced in Symfony 4.3.

The format of the input data - i.e. the format that the number is stored on
your underlying object. Valid values are ``number`` and ``string``. Setting
this option to ``string`` can be useful if the underlying data is a string
for precision reasons (for example, Doctrine uses strings for the ``decimal``
type).

scale
~~~~~

Expand Down

0 comments on commit d403f97

Please sign in to comment.