Tutte le view marketing, legali, viewer, dashboard e admin usano t(); mailer utente-facing e flash localizzati; admin con LocaleResolver e selettore lingua. Co-authored-by: Cursor <cursoragent@cursor.com>
26 lines
685 B
Ruby
26 lines
685 B
Ruby
module Public
|
|
module TeamPagesHelper
|
|
def team_page_meta_description(team, club)
|
|
t("team_pages.show.meta_description", team: team.name, club: club.name)
|
|
end
|
|
|
|
def filter_params_for_canonical
|
|
params.permit(:q, :sport, :live, :replays).to_h.compact_blank
|
|
end
|
|
|
|
def team_page_structured_data(team, club)
|
|
{
|
|
"@context" => "https://schema.org",
|
|
"@type" => "SportsTeam",
|
|
"name" => team.name,
|
|
"sport" => team.sport_label,
|
|
"url" => seo_absolute_url(public_team_page_path(team.slug)),
|
|
"memberOf" => {
|
|
"@type" => "SportsOrganization",
|
|
"name" => club.name
|
|
}
|
|
}
|
|
end
|
|
end
|
|
end
|