change templates
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 6s
Gitea Actions Demo / build-and-test (push) Failing after 2m49s

This commit is contained in:
Thomas Peetz
2026-10-25 04:05:11 +01:00
parent 05555a7750
commit 2889927416
15 changed files with 255 additions and 139 deletions
+4 -2
View File
@@ -37,13 +37,15 @@ func (handler *MediaVideoHandler) List(c *gin.Context) {
func (handler *MediaVideoHandler) ListPage(c *gin.Context) {
session := sessions.Default(c)
user := session.Get(globals.UserKey)
logger := slog.Get(c)
videos, err := handler.Service.List(c.Request.Context())
if err != nil {
c.JSON(http.StatusInternalServerError, gin.H{"error": err.Error()})
return
}
data := globals.GetDefaultValues(user, "MediaFiles...")
data["title"] = "Kontor MediaFiles"
logger.Info("MediaLoFiHandler#ListPage", "videos count", len(videos))
data := globals.GetDefaultValues(user, "MediaVideos...")
data["title"] = "Kontor MediaVideos"
data["mediavideos"] = videos
c.HTML(http.StatusOK, "mediavideos", data)