Skip to content

Commit

Permalink
[ui] Filter individuals by enrollment status
Browse files Browse the repository at this point in the history
Adds the 'isEnrolled' boolean filter to the 'Search'
component.

Signed-off-by: Eva Millán <[email protected]>
  • Loading branch information
evamillan committed Apr 19, 2021
1 parent 4aa0e34 commit 4f2f4df
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 8 deletions.
4 changes: 4 additions & 0 deletions ui/src/components/Search.vue
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,10 @@ export default {
{
filter: "enrollmentDate",
type: "date"
},
{
filter: "isEnrolled",
type: "boolean"
}
]
},
Expand Down
7 changes: 7 additions & 0 deletions ui/src/views/SearchHelp.vue
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,13 @@
</tbody>
</template>
</v-simple-table>

<p class="subtitle-2 mt-8">Filter by enrollment status</p>
<p>
You can search for individuals based on whether they have any
affiliation, using the <code>isEnrolled:true</code> and
<code>isEnrolled:false</code> filters.
</p>
</v-card-text>
</v-card>
</v-main>
Expand Down
12 changes: 6 additions & 6 deletions ui/tests/unit/__snapshots__/mutations.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ exports[`IndividualsTable Mock query for deleteIdentity 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down Expand Up @@ -452,7 +452,7 @@ exports[`IndividualsTable Mock query for merge 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down Expand Up @@ -817,7 +817,7 @@ exports[`IndividualsTable Mock query for moveIdentity 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down Expand Up @@ -1182,7 +1182,7 @@ exports[`IndividualsTable Mock query for unmerge 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down Expand Up @@ -1547,7 +1547,7 @@ exports[`IndividualsTable Mock query for updateEnrollment 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down Expand Up @@ -1912,7 +1912,7 @@ exports[`IndividualsTable Mock query for withdraw 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down
4 changes: 2 additions & 2 deletions ui/tests/unit/__snapshots__/queries.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ exports[`IndividualsTable Mock query for getCountries 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down Expand Up @@ -461,7 +461,7 @@ exports[`IndividualsTable Mock query for getPaginatedIndividuals 1`] = `
filterselector="true"
orderoptions="[object Object],[object Object],[object Object]"
orderselector="true"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
validfilters="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]"
/>
<v-tooltip-stub
Expand Down

0 comments on commit 4f2f4df

Please sign in to comment.