forked from ebhomengo/niki
Merge branch 'develop' into feature/wallet
This commit is contained in:
commit
87923a3d51
|
|
@ -0,0 +1,11 @@
|
|||
package mysql
|
||||
|
||||
import "git.gocasts.ir/ebhomengo/niki/repository/mysql"
|
||||
|
||||
type DB struct {
|
||||
conn *mysql.DB
|
||||
}
|
||||
|
||||
func New(db *mysql.DB) *DB {
|
||||
return &DB{conn: db}
|
||||
}
|
||||
|
|
@ -0,0 +1 @@
|
|||
package mysql
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
package service
|
||||
|
||||
type Service struct {
|
||||
repo Repo
|
||||
}
|
||||
|
||||
type Repo interface {
|
||||
}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
package gamificationapp
|
||||
|
||||
type Application struct {
|
||||
Config Config
|
||||
}
|
||||
|
||||
func setUp(cnf Config) *Application {
|
||||
return &Application{
|
||||
cnf,
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
package gamificationapp
|
||||
|
||||
type Config struct {
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
package gamification
|
||||
|
||||
import (
|
||||
gamification "git.gocasts.ir/ebhomengo/niki/domain/gamification/service"
|
||||
)
|
||||
|
||||
type Handler struct {
|
||||
GamificationSvc gamification.Service
|
||||
}
|
||||
|
||||
func New(gamificationSvc gamification.Service) *Handler {
|
||||
return &Handler{
|
||||
GamificationSvc: gamificationSvc,
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
package gamification
|
||||
|
||||
import "github.com/labstack/echo/v4"
|
||||
|
||||
func (h Handler) SetRoutes(e *echo.Echo) {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
package http
|
||||
|
||||
import "git.gocasts.ir/ebhomengo/niki/gamificationapp/delivery/http/gamification"
|
||||
|
||||
type Server struct {
|
||||
gamificationHandler *gamification.Handler
|
||||
}
|
||||
|
||||
func New(handler gamification.Handler) *Server {
|
||||
return &Server{
|
||||
gamificationHandler: &handler,
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue