Jelajahi Sumber

Update Story Model

Daniel Supernault 6 tahun lalu
induk
melakukan
d7d1303a63
1 mengubah file dengan 7 tambahan dan 0 penghapusan
  1. 7 0
      app/Story.php

+ 7 - 0
app/Story.php

@@ -6,6 +6,13 @@ use Illuminate\Database\Eloquent\Model;
 
 class Story extends Model
 {
+	protected $visible = ['id'];
+	
+	public function profile()
+	{
+		return $this->belongsTo(Profile::class);
+	}
+
 	public function items()
 	{
 		return $this->hasMany(StoryItem::class);