This commit is contained in:
2020-12-02 15:54:44 +08:00
parent ff3b942268
commit 6e43fe13eb
4 changed files with 46 additions and 39 deletions

View File

@@ -26,6 +26,10 @@ class Category extends Model
public function getLinkAttribute()
{
if ($this->url) {
return $this->url;
}
return route('category.show', $this);
}