From d3f040da3394468ea4b316612f6944bd10ab926d Mon Sep 17 00:00:00 2001 From: Andrea Fazzi Date: Thu, 3 Feb 2022 16:20:39 +0100 Subject: [PATCH] Add PreviousParticipantsSelection --- orm/school.go | 2 ++ templates/schools_add_update.html.tpl | 11 +++++++++-- templates/schools_show.html.tpl | 5 +++++ 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/orm/school.go b/orm/school.go index 65b0218b..ec150c03 100644 --- a/orm/school.go +++ b/orm/school.go @@ -57,6 +57,8 @@ type School struct { ContestDirectorLastname string ContestDirectorFirstname string + PreviousParticipantsSelection uint + UserID uint RegionID RegionID `schema:"region_id"` diff --git a/templates/schools_add_update.html.tpl b/templates/schools_add_update.html.tpl index fa7950af..ec1d2a88 100644 --- a/templates/schools_add_update.html.tpl +++ b/templates/schools_add_update.html.tpl @@ -104,11 +104,18 @@ {{template "input" dict "options" ($options|yaml) "value" (.Data|field "ContestDirectorFirstname") "update" $update}}
- {{$options := ` { name: "ContestDirectorLastname",id: "school_contest_director_lastname",label: "Cognome del responsabile di gara",placeholder: "Inserire il cognome del responsabile di gara",type: "text",required: "true"} `}} - {{template "input" dict "options" ($options|yaml) "value" (.Data|field "ContestDirectorLastname") "update" $update}} + {{$options := ` { name: "ContestDirectorLastname",id: "school_contest_director_lastname",label: "Cognome del responsabile di gara",placeholder: "Inserire il cognome del responsabile di gara",type: "text",required: "true"} `}} + {{template "input" dict "options" ($options|yaml) "value" (.Data|field "ContestDirectorLastname") "update" $update}}
+
+
+ {{$options := ` { name: "PreviousParticipantsSelection",id: "school_previous_participants_selection",label: "Indicare il numero complessivo degli studenti nell'ambito del quale sono stati selezionati il candidato JUNIOR e il candidato SENIOR dell'Istituto",placeholder: "Indicare il numero complessivo degli studenti",type: "number",required: "true"} `}} + {{template "input" dict "options" ($options|yaml) "value" (.Data|field "PreviousParticipantsSelection") "update" $update}} +
+
+ {{if ne (env "OEF_REGRESSION_TEST") "1"}} {{if .Claims|isSubscriber}} {{$captcha := genCaptcha}} diff --git a/templates/schools_show.html.tpl b/templates/schools_show.html.tpl index 6698909e..72546aa5 100644 --- a/templates/schools_show.html.tpl +++ b/templates/schools_show.html.tpl @@ -60,6 +60,11 @@
Referente di sede
{{.Data.SchoolContactPersonLastname}} {{.Data.SchoolContactPersonFirstname}} ({{.Data.SchoolContactPersonEmail}}, {{.Data.SchoolContactPersonTelephoneNumber}})
Responsabile di gara
{{.Data.ContestDirectorLastname}} {{.Data.ContestDirectorFirstname}}
+ +
+ Numero di studenti complessivo dal quale sono stati + selezionati i candidati per le prove regionali +
{{.Data.PreviousParticipantsSelection}}
{{if $isAdmin}} {{if $creatorUser:=.Data.CreatedBy}}