blob: 111a86b878989379f13a23999981c1faf75853fa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
BlazeComponent.extendComponent({
onCreated() {
this.term = new ReactiveVar('');
},
results() {
const currentBoard = Boards.findOne(Session.get('currentBoard'));
return currentBoard.searchCards(this.term.get());
},
events() {
return [{
'submit .js-search-term-form'(evt) {
evt.preventDefault();
this.term.set(evt.target.searchTerm.value);
},
}];
},
}).register('searchSidebar');
|