public function setCurrentRef() { if (!$this->getRef()) { return $this->setRef(\Yii::$app->request->getUrl()); } return $this; }