From 7ead052054eda34dd58c20faf83547e721ec3cd5 Mon Sep 17 00:00:00 2001 From: Kailash Nadh Date: Sat, 1 Aug 2020 16:59:34 +0530 Subject: [PATCH] Fixed `reset` not clearing query on subscriber search UI --- frontend/src/components/EmptyPlaceholder.vue | 2 +- frontend/src/views/Subscribers.vue | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/EmptyPlaceholder.vue b/frontend/src/components/EmptyPlaceholder.vue index ff5c1fd..0500e11 100644 --- a/frontend/src/components/EmptyPlaceholder.vue +++ b/frontend/src/components/EmptyPlaceholder.vue @@ -4,7 +4,7 @@

-

{{ !label ? 'Nothing here yet' : label }}

+

{{ !label ? 'Nothing here' : label }}

diff --git a/frontend/src/views/Subscribers.vue b/frontend/src/views/Subscribers.vue index 9936f94..3698609 100644 --- a/frontend/src/views/Subscribers.vue +++ b/frontend/src/views/Subscribers.vue @@ -20,7 +20,7 @@
- Query - Reset + Reset
@@ -208,6 +208,8 @@ export default Vue.extend({ all: false, }, + queryInput: '', + // Query params to filter the getSubscribers() API call. queryParams: { // Search query expression. @@ -232,7 +234,12 @@ export default Vue.extend({ // Toggling to simple search. if (!this.isSearchAdvanced) { this.$nextTick(() => { + this.queryInput = ''; + this.queryParams.queryExp = ''; + this.queryParams.page = 1; this.$refs.query.focus(); + + this.querySubscribers(); }); return; }