add bookmark back

This commit is contained in:
2020-05-09 18:37:31 +02:00
parent 2f8e8ca378
commit a1b8962fe6
12 changed files with 520 additions and 0 deletions

View File

@@ -2,6 +2,7 @@
namespace App;
use App\Models\Bookmark;
use App\Models\Image;
use App\Models\Memo;
use App\Models\ToDoList;
@@ -64,6 +65,11 @@ class User extends Authenticatable
return $this->hasMany(ToDoList::class);
}
public function bookmarks() : HasMany
{
return $this->hasMany(Bookmark::class);
}
public function images(): MorphMany
{
return $this->morphMany(Image::class, 'imageable');