Browse Source

Update Story Model

Daniel Supernault 6 years ago
parent
commit
ae78addab4
1 changed files with 14 additions and 1 deletions
  1. 14 1
      app/Story.php

+ 14 - 1
app/Story.php

@@ -6,5 +6,18 @@ use Illuminate\Database\Eloquent\Model;
 
 class Story extends Model
 {
-    //
+	public function items()
+	{
+		return $this->hasMany(StoryItem::class);
+	}
+
+	public function reactions()
+	{
+		return $this->hasMany(StoryReaction::class);
+	}
+
+	public function views()
+	{
+		return $this->hasMany(StoryView::class);
+	}
 }