2023-08-05 15:50:40 +00:00
|
|
|
<dialog class="card" id="update-card">
|
2024-01-01 11:29:59 +00:00
|
|
|
<h3 class="card-title">Ažuriraj praznik</h3>
|
2023-08-05 15:50:40 +00:00
|
|
|
<form method="post" action="/admin/holidays">
|
|
|
|
<input type="hidden" name="id" value="{{.Holiday.Id}}">
|
2024-01-01 11:29:59 +00:00
|
|
|
<section class="form-field">
|
|
|
|
<label for="country">Država:</label>
|
2023-08-05 15:50:40 +00:00
|
|
|
<select id="country" required name="country">
|
2023-08-05 19:34:09 +00:00
|
|
|
{{range $entry := .Countries}}
|
|
|
|
<option {{if eq $.Holiday.Country $entry.IsoName}}selected{{end}} value="{{$entry.IsoName}}">{{$entry.Name}}</option>
|
|
|
|
{{end}}
|
2023-08-05 15:50:40 +00:00
|
|
|
</select>
|
|
|
|
</section>
|
2024-01-01 11:29:59 +00:00
|
|
|
<section class="form-field">
|
|
|
|
<label for="name">Ime:</label>
|
2023-08-05 15:50:40 +00:00
|
|
|
<input required id="name" value="{{.Holiday.Name}}" name="name" type="text">
|
|
|
|
</section>
|
2024-01-01 11:29:59 +00:00
|
|
|
<section class="form-field">
|
|
|
|
<label for="description">Opis:</label>
|
2023-08-05 15:50:40 +00:00
|
|
|
<textarea id="description" name="description">{{.Holiday.Description}}</textarea>
|
|
|
|
</section>
|
2024-01-01 11:29:59 +00:00
|
|
|
<section class="form-field">
|
|
|
|
<label for="date">Datum:</label>
|
2023-08-05 15:50:40 +00:00
|
|
|
<input required id="date" value="{{.Holiday.Date.Format "2006-01-02"}}" name="date" type="date">
|
|
|
|
</section>
|
2024-01-01 11:29:59 +00:00
|
|
|
<section class="form-field">
|
|
|
|
<label class="checkbox"><span>Državni praznik</span><input id="state_holiday" value="true" {{if .Holiday.IsStateHoliday}}checked{{end}} name="state_holiday" type="checkbox"></label>
|
2023-08-05 15:50:40 +00:00
|
|
|
</section>
|
2024-01-01 11:29:59 +00:00
|
|
|
<section class="form-field">
|
|
|
|
<label class="checkbox"><span>Religiozni praznik</span><input id="religious_holiday" value="true" {{if .Holiday.IsReligiousHoliday}}checked{{end}} name="religious_holiday" type="checkbox"></label>
|
2023-08-05 15:50:40 +00:00
|
|
|
</section>
|
|
|
|
<section class="actions">
|
2024-01-01 11:29:59 +00:00
|
|
|
<button class="primary" type="submit">Ažuriraj</button>
|
|
|
|
<button class="secondary" type="button" onclick="closeDialog('#update-card')">Odustani</button>
|
2023-08-05 15:50:40 +00:00
|
|
|
</section>
|
|
|
|
</form>
|
|
|
|
</dialog>
|