package localeSelectorService

import (
	"git.ma-al.com/goc_daniel/b2b/app/model"
	"git.ma-al.com/goc_daniel/b2b/app/repos/localeSelectorRepo"
)

// LocaleSelectorService literally sends back language and countries information.
type LocaleSelectorService struct {
	repo localeSelectorRepo.UILocaleSelectorRepo
}

// NewLocaleSelectorService creates a new LocaleSelector service
func New() *LocaleSelectorService {
	return &LocaleSelectorService{
		repo: localeSelectorRepo.New(),
	}
}

func (s *LocaleSelectorService) GetLanguages() ([]model.Language, error) {
	return s.repo.GetLanguages()
}

func (s *LocaleSelectorService) GetCountriesAndCurrencies() ([]model.Country, error) {
	return s.repo.GetCountriesAndCurrencies()
}
