fix: audit filter — add submit button, fix type comparison
This commit is contained in:
+3
-2
@@ -91,14 +91,15 @@
|
||||
<div class="card-body">
|
||||
<form method="GET" action="/audit" class="filter-bar">
|
||||
<label style="font-size:.85rem;color:var(--muted);">Компания:</label>
|
||||
<select name="company" onchange="this.form.submit()">
|
||||
<select name="company">
|
||||
<option value="">— Все компании —</option>
|
||||
<% companies.forEach(c => { %>
|
||||
<option value="<%= c.id %>" <%= selectedCompanyId === c.id ? 'selected' : '' %>>
|
||||
<option value="<%= c.id %>" <%= Number(selectedCompanyId) === Number(c.id) ? 'selected' : '' %>>
|
||||
<%= c.name %> (<%= c.client_id %>)
|
||||
</option>
|
||||
<% }) %>
|
||||
</select>
|
||||
<button type="submit" class="btn btn-sm">Применить</button>
|
||||
<% if (selectedCompanyId) { %>
|
||||
<a href="/audit" class="btn btn-sm">Сбросить</a>
|
||||
<% } %>
|
||||
|
||||
Reference in New Issue
Block a user