| @@ 605-612 (lines=8) @@ | ||
| 602 | * |
|
| 603 | * @return $this |
|
| 604 | */ |
|
| 605 | public function rules($rules = null, $messages = []): self |
|
| 606 | { |
|
| 607 | $this->rules = $this->mergeRules($rules, $this->rules); |
|
| 608 | ||
| 609 | $this->setValidationMessages('default', $messages); |
|
| 610 | ||
| 611 | return $this; |
|
| 612 | } |
|
| 613 | ||
| 614 | /** |
|
| 615 | * Set the update validation rules for the field. |
|
| @@ 622-629 (lines=8) @@ | ||
| 619 | * |
|
| 620 | * @return $this |
|
| 621 | */ |
|
| 622 | public function updateRules($rules = null, $messages = []): self |
|
| 623 | { |
|
| 624 | $this->updateRules = $this->mergeRules($rules, $this->updateRules); |
|
| 625 | ||
| 626 | $this->setValidationMessages('update', $messages); |
|
| 627 | ||
| 628 | return $this; |
|
| 629 | } |
|
| 630 | ||
| 631 | /** |
|
| 632 | * Set the creation validation rules for the field. |
|