diff options
author | Phil Hughes <me@iamphill.com> | 2017-03-08 15:17:01 +0300 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-03-08 15:17:01 +0300 |
commit | 809bba7d02b45938494f8ae471a2b27ce4a40833 (patch) | |
tree | df9d34b65b9e60b7b8dc684b42b8f897d7bb909d /app/assets/javascripts/boards/filtered_search_boards.js | |
parent | 382fea7b5925ac7dc47ccfd79f7537284e68cd6f (diff) |
Updated specs
Diffstat (limited to 'app/assets/javascripts/boards/filtered_search_boards.js')
-rw-r--r-- | app/assets/javascripts/boards/filtered_search_boards.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/app/assets/javascripts/boards/filtered_search_boards.js b/app/assets/javascripts/boards/filtered_search_boards.js index d00cb123909..3014557c440 100644 --- a/app/assets/javascripts/boards/filtered_search_boards.js +++ b/app/assets/javascripts/boards/filtered_search_boards.js @@ -14,4 +14,18 @@ export default class FilteredSearchBoards extends gl.FilteredSearchManager { gl.issueBoards.BoardsStore.updateFiltersUrl(); } } + + updateTokens() { + const tokens = document.querySelectorAll('.js-visual-token'); + + // Remove all the tokens as they will be replaced by the search manager + [].forEach.call(tokens, (el) => { + el.parentNode.removeChild(el); + }); + + this.loadSearchParamsFromURL(); + + // Get the placeholder back if search is empty + this.filteredSearchInput.dispatchEvent(new Event('input')); + } } |