LocalGovIMS_localgov-ims/src/Admin/Views/EReturn/_Search.cshtml
@model Admin.Models.EReturn.SearchCriteria

@using (Html.BeginForm("Search", "EReturn", FormMethod.Get))
{
    <div>

        <div class="row">

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2">
                @Html.LabelFor(m => m.Reference, new { @class = "form-label" })
                @Html.TextBoxFor(m => m.Reference, new { @class = "form-control", size = 10, placeholder = "Enter reference" })
            </div>

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2 pt-2 pt-sm-0">
                @Html.LabelFor(m => m.StartDate, new { @class = "form-label" })
                @Html.TextBoxFor(m => m.StartDate, new { @class = "form-control", placeholder = "Start date", type = "date" })
            </div>

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2 pt-2 pt-md-0">
                @Html.LabelFor(m => m.EndDate, new { @class = "form-label" })
                @Html.TextBoxFor(m => m.EndDate, new { @class = "form-control", placeholder = "End date", type = "date" })
            </div>

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2 pt-2 pt-lg-0">
                @Html.LabelFor(m => m.TemplateId, new { @class = "form-label" })
                <select id="TemplateId" name="TemplateId">
                    <option value="">None</option>
                    @foreach (var item in Model.Templates.Items)
                    {
                        <option class="item" value="@item.Value" @(Model.TemplateId.HasValue && Model.TemplateId.Value.ToString().Equals(item.Value) ? "selected" : String.Empty)>@item.Text</option>
                    }
                </select>
            </div>

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2 pt-2 pt-xxl-0">
                @Html.LabelFor(m => m.StatusId, new { @class = "form-label" })
                <select id="StatusId" name="StatusId">
                    <option value="">None</option>
                    @foreach (var item in Model.Statuses.Items)
                    {
                        <option class="item" value="@item.Value" @(Model.StatusId.HasValue && Model.StatusId.Value.ToString().Equals(item.Value) ? "selected" : String.Empty)>@item.Text</option>
                    }
                </select>
            </div>

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2 pt-2 pt-xxl-0">
                @Html.LabelFor(m => m.EReturnType, new { @class = "form-label" })
                <select id="EReturnType" name="EReturnType">
                    <option value="">None</option>
                    @foreach (var item in Model.Types.Items)
                    {
                        <option class="item" value="@item.Value" @(Model.EReturnType.HasValue && Model.EReturnType.Value.ToString().Equals(item.Value) ? "selected" : String.Empty)>@item.Text</option>
                    }
                </select>
            </div>

            <div class="col-12 col-sm-6 col-md-4 col-lg-3 col-xxl-2 pt-2">
                @Html.LabelFor(m => m.Amount, new { @class = "form-label" })
                @Html.TextBoxFor(m => m.Amount, new { @class = "form-control monetary-amount", placeholder = "Enter amount", @maxlength = "18" })
            </div>

            <div class="col-12 col-sm-6 col-md-8 col-lg-3 col-xxl-10 pt-3 gap-2 d-flex align-self-end justify-content-end">
                <button class="btn btn-primary search" tabindex="0" type="submit">Search</button>
                <a href="@Url.Action("Search", "EReturn")" class="btn btn-secondary" id="reset">Reset search</a>
            </div>

        </div>

    </div>

}