Allow selecting several comptes/types at once in the filters
Compte and Type were single-value <select> elements. Converted both to <select multiple> -- Vue binds those to an array natively, so ctrl/cmd+click and shift+click just work with no custom JS. Matching semantics are OR within a filter (any of the selected comptes/types) and AND across filters, same as the existing client/year/écarts filters. The URL hash (compte=Maud,Bachir&type=versement,achat) now carries comma-separated lists instead of a single value, so the shareable/ reloadable filtered view still works with multiple selections.
This commit is contained in:
@@ -20,8 +20,7 @@
|
||||
{% verbatim %}
|
||||
|
||||
<label>Compte
|
||||
<select v-model="filterCompte">
|
||||
<option value="">Tous</option>
|
||||
<select v-model="filterCompte" multiple size="4" title="Ctrl/Cmd+clic ou Maj+clic pour plusieurs comptes">
|
||||
<option v-for="c in allComptes" :key="c" :value="c">{{ c }}</option>
|
||||
</select>
|
||||
</label>
|
||||
@@ -34,8 +33,7 @@
|
||||
</label>
|
||||
|
||||
<label>Type
|
||||
<select v-model="filterType">
|
||||
<option value="">Tous</option>
|
||||
<select v-model="filterType" multiple size="4" title="Ctrl/Cmd+clic ou Maj+clic pour plusieurs types">
|
||||
<option v-for="t in allTypes" :key="t.value" :value="t.value">{{ t.label }}</option>
|
||||
</select>
|
||||
</label>
|
||||
|
||||
Reference in New Issue
Block a user