generated from VLADIMIR/template
add catalog
This commit is contained in:
@@ -46,6 +46,16 @@ func (s *ScenarioService) GetScenariosByAuthorID(
|
||||
return mapScenariosLight(scenarios, s.domain), nil
|
||||
}
|
||||
|
||||
func (s *ScenarioService) GetScenariosCatalog(
|
||||
ctx context.Context,
|
||||
) ([]*Scenario, error) {
|
||||
scenarios, err := s.scenariosRepo.GetScenariosByStatus(ctx, "public")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return mapScenariosLight(scenarios, s.domain), nil
|
||||
}
|
||||
|
||||
func (s *ScenarioService) GetScenarioByID(
|
||||
ctx context.Context,
|
||||
id int,
|
||||
|
||||
Reference in New Issue
Block a user