backend/internal/types/types.go
2025-05-06 22:20:30 +01:00

30 lines
555 B
Go

package types
import (
"time"
"github.com/gin-gonic/gin"
"gorm.io/gorm"
"stereo.cat/backend/internal/auth/client"
)
type Route struct {
Path string
Method string
Exec func(cfg *StereoConfig) gin.HandlerFunc
}
type StereoConfig struct {
ImagePath string
Router *gin.Engine
Client client.Client
Database *gorm.DB
JWTSecret string
}
type File struct {
ID string `gorm:"primaryKey"`
Path string `gorm:"not null;index"`
Owner string `gorm:"not null;index"`
CreatedAt time.Time `gorm:"autoCreateTime"`
}