Documentation
¶
Index ¶
- func ListActiveWatchUserIDsAfter(articleId, afterUserId uint64, excludeUserIds []uint64, limit int) []uint64
- func SetBookmarked(userId, articleId uint64, bookmarked bool) bool
- func SetBookmarkedAt(userId, articleId uint64, bookmarkedAt *time.Time) bool
- func SetLiked(userId, articleId uint64, liked bool) bool
- func SetLikedAt(userId, articleId uint64, likedAt *time.Time) bool
- func SetWatched(userId, articleId uint64, watched bool) bool
- func SetWatchedAt(userId, articleId uint64, watchedAt *time.Time) bool
- type Entity
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetBookmarked ¶
func SetWatched ¶
Types ¶
type Entity ¶
type Entity struct {
Id uint64 `gorm:"primaryKey;column:id;autoIncrement;not null" json:"id"`
UserId uint64 `` /* 271-byte string literal not displayed */
ArticleId uint64 `` /* 167-byte string literal not displayed */
LikedAt *time.Time `gorm:"column:liked_at;index:idx_aus_user_like,priority:2" json:"likedAt"`
BookmarkedAt *time.Time `gorm:"column:bookmarked_at;index:idx_aus_user_bookmark,priority:2" json:"bookmarkedAt"`
WatchedAt *time.Time `gorm:"column:watched_at;index:idx_aus_user_watch,priority:2;index:idx_aus_watch_notify,priority:3" json:"watchedAt"`
CreatedAt time.Time `gorm:"column:created_at;autoCreateTime;<-:create" json:"createdAt"`
UpdatedAt time.Time `gorm:"column:updated_at;autoUpdateTime" json:"updatedAt"`
}
func GetByArticleId ¶
Click to show internal directories.
Click to hide internal directories.