update ui, search, new api endpoint

This commit is contained in:
Tomas Dvorak
2025-12-01 10:05:27 +01:00
parent 025f5beef1
commit 6a9f25ffe9
19 changed files with 2082 additions and 121 deletions
+3 -2
View File
@@ -3,8 +3,8 @@ package main
import (
"database/sql"
"log"
"os"
"net/http"
"os"
"github.com/gin-contrib/cors"
"github.com/gin-gonic/gin"
@@ -46,7 +46,7 @@ func main() {
AllowHeaders: []string{"Origin", "Content-Type", "Accept", "Authorization", "X-Requested-With", "Range", "Accept-Language", "Accept-Encoding", "Cache-Control", "Pragma", "If-Modified-Since"},
ExposeHeaders: []string{"*"},
AllowCredentials: false,
AllowOriginFunc: func(origin string) bool { return true },
AllowOriginFunc: func(origin string) bool { return true },
}))
// Routes
@@ -89,6 +89,7 @@ func setupRoutes(r *gin.Engine) {
clubs := r.Group("/clubs")
{
clubs.GET("/search", searchClubs)
clubs.GET("/search-with-logos", searchClubsWithLogos)
clubs.GET("/:id", getClub)
}