-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Hint Error Bubbling for Collections Edit #3341
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
Conversation
By default the :doc:`collection Field Type </reference/forms/types/collection>` has enabled the option ``error_bubbling`` | ||
which passes the errors to the parent form. If you want to attach the errors | ||
to the locations where they actually occure you have to set ``error_bubbling`` | ||
to ``false``. |
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.
the content of the tip should be indented by 4 spaces
Updated according to the comments. |
By default the ``error_bubbling`` option is enabled for the | ||
:doc:`collection Field Type </reference/forms/types/collection>` which passes the errors to the parent form. | ||
If you want to attach the errors to the locations where they | ||
actually occure you have to set ``error_bubbling`` to ``false``. |
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.
Wrap lines after the first word that crosses the 72nd character. Thus, the entire tip would look like this:
.. tip::
By default the ``error_bubbling`` option is enabled for the
:doc:`collection Field Type </reference/forms/types/collection>` which
passes the errors to the parent form. If you want to attach the errors
to the locations where they actually occure you have to set ``error_bubbling``
to ``false``.
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 when it is just a link? I took care not to be longer than 72 characters excluding the meta information.
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.
Yes, the line length is not meaned for rendering, Sphinx just removes all line feeds from a file. It's meaned to be easier to read when reading the source code and reviewing patches.
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.
Yes, this is mainly related to horizontal scrollbars in editors. And those are there regardless if it is meta information or "real" text. :)
Okay, fixed :) |
👍 nice work! |
Added hint regarding the error bubbling default setting on collection entities based on the discussion in #2559.
I have added it to the Valid constraint as well as the cascade_validation setting since you need either setting when validating embedded collections.