Add PostgreSQL database option and more booking flow functionalities

This commit is contained in:
2023-05-08 01:29:59 +02:00
parent d8346a20be
commit e2e6759dc0
40 changed files with 1594 additions and 907 deletions

View File

@@ -1,3 +1,4 @@
// Package handler provides the business logic for the carpool service
package handler
import (
@@ -8,17 +9,20 @@ import (
)
type CarpoolServiceHandler struct {
Config *viper.Viper
Storage storage.Storage
Tiles *tiles.TilesHandler
Routing routing.RoutingService
Config *viper.Viper
Storage storage.Storage
Tiles *tiles.TilesHandler
Routing routing.RoutingService
InternalOperatorID string
}
func NewCarpoolServiceHandler(cfg *viper.Viper, storage storage.Storage, tilesHandler *tiles.TilesHandler, routing routing.RoutingService) (*CarpoolServiceHandler, error) {
operator := cfg.GetString("interoperability.internal_operator_id")
return &CarpoolServiceHandler{
Config: cfg,
Storage: storage,
Tiles: tilesHandler,
Routing: routing,
Config: cfg,
Storage: storage,
Tiles: tilesHandler,
Routing: routing,
InternalOperatorID: operator,
}, nil
}