splitted user registration into user, consents & bankaccount creation

This commit is contained in:
$(pass /github/name)
2024-07-07 21:39:58 +02:00
parent a76d73aa82
commit 555d1be575
13 changed files with 270 additions and 53 deletions

View File

@@ -21,9 +21,13 @@ func Run() {
defer db.Close()
emailService := services.NewEmailService(cfg.SMTP.Host, cfg.SMTP.Port, cfg.SMTP.User, cfg.SMTP.Password, cfg.SMTP.AdminEmail)
consentRepo := repositories.NewConsentRepository(db)
consentService := services.NewConsentService(consentRepo)
bankAccountRepo := repositories.NewBankAccountRepository(db)
bankAccountService := services.NewBankAccountService(bankAccountRepo)
userRepo := repositories.NewUserRepository(db)
userService := services.NewUserService(userRepo)
userController := controllers.NewUserController(userService, emailService)
userController := controllers.NewUserController(userService, emailService, consentService, bankAccountService)
router := mux.NewRouter()
// router.Handle("/csrf-token", middlewares.GenerateCSRFTokenHandler()).Methods("GET")