new-support.webeffector.ru/common/components/user/models/UserPassword.php

33 lines
662 B
PHP
Raw Permalink Normal View History

2024-07-04 06:42:20 +03:00
<?php
namespace common\components\user\models;
use Yii;
use yii\base\Model;
/**
* @property string $password
* @property string $passwordConfirm
*/
class UserPassword extends Model
{
public $password;
public $passwordConfirm;
public function rules(): array
{
return [
[['password', 'passwordConfirm'], 'required'],
[['password', 'passwordConfirm'], 'string'],
];
}
public function attributeLabels(): array
{
return [
'password' => Yii::t('user', 'Пароль'),
'passwordConfirm' => Yii::t('user', 'Повторите пароль'),
];
}
}