Skip to content

Commit

Permalink
Add getShortDescription method in Page model
Browse files Browse the repository at this point in the history
  • Loading branch information
thecodeholic committed Feb 21, 2018
1 parent fe62448 commit 374b620
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions models/Page.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,10 +179,16 @@ public function getTitle()
return $this->getTranslation() ? $this->getTranslation()->title : '';
}

public function getShortDescription()
{
return $this->getTranslation() ? $this->getTranslation()->getShortDescription() : '';
}

public function getBody()
{
return $this->getTranslation() ? $this->getTranslation()->getBody() : '';
}

public function getTranslation()
{
return $this->activeTranslation ?: $this->defaultTranslation;
Expand Down

0 comments on commit 374b620

Please sign in to comment.