From a226d17aa70422b4e668cb40e18546e244d0d240 Mon Sep 17 00:00:00 2001 From: jordi fita mas Date: Sat, 13 Jan 2024 01:37:11 +0100 Subject: [PATCH] =?UTF-8?q?Add=20the=20campsite=20type=E2=80=99s=20name=20?= =?UTF-8?q?in=20front=20of=20price=20if=20it=20has=20options?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Customer wants to explicitly show that the first price, the one on top of the options, is for the campsite type. --- web/templates/public/campsite/type.gohtml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/web/templates/public/campsite/type.gohtml b/web/templates/public/campsite/type.gohtml index cb32b4d..b0be5ef 100644 --- a/web/templates/public/campsite/type.gohtml +++ b/web/templates/public/campsite/type.gohtml @@ -80,7 +80,13 @@ {{ .SeasonName }} -
{{ printf (gettext "%s €/night") .PricePerNight }}
+
+ {{- if .Options -}} + {{ printf (gettext "%s: %s €/night") $.Name .PricePerNight }} + {{- else -}} + {{ printf (gettext "%s €/night") .PricePerNight }} + {{- end -}} +
{{ range .Options }}
{{ printf (gettext "%s: %s €/night") .OptionName .PricePerNight }}
{{- end }}