mirror of
https://github.com/yiisoft/yii2.git
synced 2026-03-22 23:17:12 +01:00
Make validator getClientOptions public
This allows implementing custom client-side validation without extending every validator. Fixes #11163 close #13145
This commit is contained in:
committed by
Carsten Brandt
parent
0e5efb91eb
commit
f5beaf3edf
@@ -159,7 +159,7 @@ class StringValidator extends Validator
|
||||
return 'yii.validation.string(value, messages, ' . json_encode($options, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE) . ');';
|
||||
}
|
||||
|
||||
protected function getClientOptions($model, $attribute)
|
||||
public function getClientOptions($model, $attribute)
|
||||
{
|
||||
$label = $model->getAttributeLabel($attribute);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user