Files
futur-web-app/server/internal/service/nutrient_service.go
2025-11-03 12:24:01 +02:00

20 lines
405 B
Go

package service
import (
"context"
"go-server/internal/models"
"go-server/internal/repository"
)
type NutrientService struct {
repo *repository.NutrientRepository
}
func NewNutrientService(repo *repository.NutrientRepository) *NutrientService {
return &NutrientService{repo: repo}
}
func (s *NutrientService) GetAll(ctx context.Context) ([]*models.Nutrient, error) {
return s.repo.GetAll(ctx)
}