package service import ( "net/http" repository "sig-pub/internal/sig/repoitory" "sig-pub/pkg/resp" "github.com/gin-gonic/gin" ) type BacktestService struct { repo *repository.BacktestRepository } func NewBacktestService(repo *repository.BacktestRepository) *BacktestService { return &BacktestService{ repo: repo, } } func (svc *BacktestService) Route(group *gin.RouterGroup) { group.GET("hello", svc.listBacktestLog) } func (svc *BacktestService) listBacktestLog(ctx *gin.Context) { name := ctx.Query("name") ctx.JSON(http.StatusOK, resp.H{ "text": "ojbk: " + name, }) }