/** * Ensure type of item * * @inheritdoc */ public function beforeSave($insert) { $this->type = static::ITEM_TYPE; return parent::beforeSave($insert); }