add form components

This commit is contained in:
Zeni Kim 2024-10-08 07:58:42 -05:00
parent 015e85bf7b
commit 8f17bf6a8c
8 changed files with 87 additions and 0 deletions

View file

@ -0,0 +1,10 @@
{{define "form_select"}}
<div class="input-container">
<label for="{{.ID}}" class="form-label">{{.Label}}</label>
<select class="form-select" id="{{.ID}}" name="{{.ID}}">
{{range $options := .AllOptions}}
<option value="{{$options.Value}}" {{if eq $options.Value $.SelectedOption.Value }}selected="selected"{{end}}>{{$options.Caption}}</option>
{{end}}
</select>
</div>
{{end}}