public function afterSave($insert, $changedAttributes) { parent::afterSave($insert, $changedAttributes); if ($this->old_status_id != $this->status_id) { Log::add(Log::MODEL_ISSUE, $this->getPrimaryKey(), $this->status_id); } }