🎱
Size: a a a
🎱
v
VT
public function behaviors()
{
$behaviors = parent::behaviors();
// remove authentication filter
$auth = $behaviors['authenticator']; // re-add authentication filter
$behaviors['authenticator'] = $auth; // avoid authentication on CORS-pre-flight requests (HTTP OPTIONS method)
$behaviors['authenticator']['except'] = ['options'];
$behaviors['authenticator']['authMethods'] = [
HttpBasicAuth::class,
HttpBearerAuth::class,
];
return $behaviors;
}
И
перенос CORS перед Auth методами решило проблему )🎱
VT
IS
a
Д
a
IS
V
['schedule', function($attribute, $value) {
return false;
}];
Почему не работает вот эта валидация? Подозревают из за того что поле - массив, но 'skipOnArray' => false выдаёт ошибку Setting unknown property: yii\validators\InlineValidator::skipOnArray
ПА
V
VT
V
V
VT
K
K
А