wekan/client/components/sidebar/sidebarSearches.js
Lauri Ojansivu 7d6d3af54a Add Features: allowing lists to be sorted by modifiedAt when not in draggable mode.
Bug Fix #2093: the broken should be prior to file attachment feature introduced, and tested export board is working.

Thanks to whowillcare !

( xet7 merged this pull request manually from https://github.com/wekan/wekan/pull/2756 )

Closes #2093
2019-10-29 19:05:44 +02:00

26 lines
605 B
JavaScript

BlazeComponent.extendComponent({
onCreated() {
this.term = new ReactiveVar('');
},
results() {
const currentBoard = Boards.findOne(Session.get('currentBoard'));
return currentBoard.searchCards(this.term.get());
},
lists() {
const currentBoard = Boards.findOne(Session.get('currentBoard'));
return currentBoard.searchLists(this.term.get());
},
events() {
return [
{
'submit .js-search-term-form'(evt) {
evt.preventDefault();
this.term.set(evt.target.searchTerm.value);
},
},
];
},
}).register('searchSidebar');