feat(kol): workspace KOL cards + article source type
This commit is contained in:
@@ -41,6 +41,7 @@ func RegisterRoutes(app *bootstrap.App) {
|
||||
workspace.GET("/recent-articles", wsHandler.RecentArticles)
|
||||
workspace.GET("/quota-summary", wsHandler.QuotaSummary)
|
||||
workspace.GET("/template-cards", wsHandler.TemplateCards)
|
||||
workspace.GET("/kol-cards", wsHandler.KolCards)
|
||||
|
||||
templates := protected.Group("/tenant/templates")
|
||||
tplHandler := NewTemplateHandler(app)
|
||||
|
||||
@@ -60,3 +60,12 @@ func (h *WorkspaceHandler) TemplateCards(c *gin.Context) {
|
||||
}
|
||||
response.Success(c, data)
|
||||
}
|
||||
|
||||
func (h *WorkspaceHandler) KolCards(c *gin.Context) {
|
||||
data, err := h.svc.KolCards(c.Request.Context())
|
||||
if err != nil {
|
||||
response.Error(c, err)
|
||||
return
|
||||
}
|
||||
response.Success(c, data)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user