change router struct

This commit is contained in:
2025-06-17 10:49:53 +08:00
parent a8bc73ae99
commit 6c3b4ec367
42 changed files with 1268 additions and 1308 deletions

View File

@@ -52,7 +52,7 @@ func (r *Repository) Transaction(ctx context.Context, fn func(ctx context.Contex
})
}
func NewDB(log *logger.Logger, config *config.Config) (*gorm.DB, func(), error) {
func NewDB(config *config.Config, log *logger.Logger) (*gorm.DB, func(), error) {
dsn := fmt.Sprintf("host=%s user=%s password=%s dbname=%s port=%d sslmode=disable TimeZone=Asia/Shanghai",
config.DB.Host,
config.DB.Username,