diff --git a/handlers/certificate.go b/handlers/certificate.go index fb32700..7171bc2 100644 --- a/handlers/certificate.go +++ b/handlers/certificate.go @@ -58,6 +58,12 @@ func (h *DefaultHandler) GenerateCertificate(c *fiber.Ctx) error { Footer: h.Config.CertificateFooter, CurrencySymbol: h.Config.CurrencySymbol, Locale: certificateRequest.Locale, + SepaConfig: &models.SepaConfig{ + BIC: h.Config.SepaBic, + HolderName: h.Config.SepaName, + IBAN: h.Config.SepaIban, + CurrencyIdentifier: h.Config.CurrencyIdentifier, + }, } logger.Info("Generating certificate html") @@ -90,6 +96,13 @@ func addUpRunnerDonations(runners []models.RunnerWithDonations) []models.RunnerW runners[i].TotalDonations += runners[i].DistanceDonations[j].Amount runners[i].TotalPerDistance += runners[i].DistanceDonations[j].AmountPerDistance } + if runners[i].Group.ParentGroup.Name != "" { + runners[i].CombinedGroupName = runners[i].Group.ParentGroup.Name + " - " + runners[i].Group.Name + } else { + runners[i].CombinedGroupName = runners[i].Group.Name + + } + } return runners }