engagement system
This commit is contained in:
@@ -120,4 +120,28 @@ class User extends Authenticatable
|
||||
{
|
||||
return $this->hasMany(Product::class);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the upvotes for the user.
|
||||
*/
|
||||
public function upvotes(): HasMany
|
||||
{
|
||||
return $this->hasMany(Upvote::class);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the comments for the user.
|
||||
*/
|
||||
public function comments(): HasMany
|
||||
{
|
||||
return $this->hasMany(Comment::class);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the bookmarks for the user.
|
||||
*/
|
||||
public function bookmarks(): HasMany
|
||||
{
|
||||
return $this->hasMany(Bookmark::class);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user