dao

package
v0.0.0-...-bd2a5d7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 30, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckIsFavorite

func CheckIsFavorite(ctx context.Context, videoID int64, userID int64) (bool, error)

判断当前视频是否被当前用户点赞

func CheckIsFollow

func CheckIsFollow(ctx context.Context, userID int64, followerID int64) (bool, error)

判断某用户是否被当前用户关注

func CheckIsFollowUser

func CheckIsFollowUser(ctx *gin.Context, checkUserId int64) bool

func CreateUser

func CreateUser(user *models.User) error

CreateUser 增

func DeleteUser

func DeleteUser(user *models.User) error

DeleteUser 删

func GetUserByID

func GetUserByID(id uint64) (*models.User, error)

GetUserByID 查

func GetUserByUsername

func GetUserByUsername(username string) (*models.User, error)

GetUserByUsername 通过用户名查找用户

func QueryFeedVideo

func QueryFeedVideo(ctx context.Context, limit int, latestTime int64) ([]*video.Video, error)

获取视频流

func QueryPublishList

func QueryPublishList(ctx context.Context, userID int64) ([]*video.Video, error)

查询发布列表

func RealTimeUser

func RealTimeUser(ctx context.Context, u *models.User) error

获取实时用户信息

func RealTimeVideo

func RealTimeVideo(ctx context.Context, v *models.Video) error

获取实时视频信息

func SaveVideo

func SaveVideo(ctx context.Context, downUrl, title string, userId int64) error

保存用户发布的视频

func UpdateUser

func UpdateUser(user *models.User) error

UpdateUser 改

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL