This commit is contained in:
2026-09-18 03:24:01 +07:00
parent f8a4ca0f55
commit fc171dace5
9 changed files with 547 additions and 288 deletions
@@ -70,6 +70,10 @@ func (s *Service) ScenarioRating(ctx context.Context, scenarioID int) (float64,
return s.reviews.ScenarioRating(ctx, scenarioID)
}
func (s *Service) ListByScenario(ctx context.Context, scenarioID int) ([]*game_reviews_repo.Review, float64, int32, error) {
return s.reviews.ListByScenario(ctx, scenarioID)
}
func reviewReminderEmail(job *teams_repo.ReviewReminder, baseURL string) email_sender.Message {
link := strings.TrimRight(baseURL, "/") + "/team-story/" + fmt.Sprint(job.TeamID) + "?" + url.Values{"password": {job.Password}, "review": {"1"}}.Encode()
body := fmt.Sprintf("Команда «%s», поделитесь впечатлениями об игре «%s».\n\nОценка и отзыв займут пару минут: %s\n\nОтзыв можно оставить один раз от команды.", job.TeamName, job.GameName, link)