You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was having a really hard time figuring out why my custom ElementType would not save. Figured out the generated element overrides the public function rules() of the \yii\base\Model::validate, but does not call the parent::rules().
Exception thrown was: [error][yii\base\InvalidArgumentException] yii\base\InvalidArgumentException: Unknown scenario: essentials in [redacted]/vendor/yiisoft/yii2/base/Model.php:357
I was having a really hard time figuring out why my custom ElementType would not save. Figured out the generated element overrides the
public function rules()
of the\yii\base\Model::validate
, but does not call theparent::rules()
.Exception thrown was:
[error][yii\base\InvalidArgumentException] yii\base\InvalidArgumentException: Unknown scenario: essentials in [redacted]/vendor/yiisoft/yii2/base/Model.php:357
Generated
\modules\somemodule\elements\CustomElement::rules
was:should be:
The text was updated successfully, but these errors were encountered: