Skip to content

Commit

Permalink
docs: add link to list of validation rules
Browse files Browse the repository at this point in the history
  • Loading branch information
kenjis committed Aug 2, 2024
1 parent 7938cf3 commit 0630332
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 2 additions & 0 deletions user_guide_src/source/libraries/validation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -877,6 +877,8 @@ Or you can use the following parameters:
.. literalinclude:: validation/047.php
:lines: 2-

.. _validation-available-rules:

***************
Available Rules
***************
Expand Down
8 changes: 6 additions & 2 deletions user_guide_src/source/models/model.rst
Original file line number Diff line number Diff line change
Expand Up @@ -676,8 +676,12 @@ prior to saving to the database with the ``insert()``, ``update()``, or ``save()
Setting Validation Rules
------------------------

The first step is to fill out the `$validationRules`_ class property with the fields and rules that should
be applied. If you have custom error message that you want to use, place them in the `$validationMessages`_ array:
The first step is to fill out the `$validationRules`_ class property with the
fields and rules that should be applied.

.. note:: You can see the list of built-in Validation rules in :ref:`validation-available-rules`.

If you have custom error message that you want to use, place them in the `$validationMessages`_ array:

.. literalinclude:: model/027.php

Expand Down

0 comments on commit 0630332

Please sign in to comment.