add like functionality with Like model, implement like/unlike methods, and update Post and Comment models to track like counts

This commit is contained in:
2025-07-22 22:45:55 +08:00
parent cbe73121f2
commit 562b9bd17f
15 changed files with 216 additions and 33 deletions

View File

@ -126,8 +126,10 @@ func migrate() error {
return GetDB().AutoMigrate(
&model.Comment{},
&model.Label{},
&model.Like{},
&model.OidcConfig{},
&model.Post{},
&model.Session{},
&model.User{})
&model.User{},
&model.UserOpenID{})
}