Skip to content
Snippets Groups Projects
Commit 23580065 authored by Ruben Bimberg's avatar Ruben Bimberg :computer:
Browse files

Fix questions filtering when clicking on a tag

[Ticket: #147]
parent 3714c8a6
Branches
Tags
No related merge requests found
......@@ -133,6 +133,7 @@ export class CommentListComponent implements OnInit, OnDestroy {
initNavigation() {
this._subscriptionEventServiceTagConfig = this.eventService.on<string>('setTagConfig').subscribe(tag => {
this.setTimePeriod(Period.all);
this.clickedOnKeyword(tag);
});
this._subscriptionEventServiceRoomData = this.eventService.on<string>('pushCurrentRoomData').subscribe(_ => {
......@@ -395,7 +396,9 @@ export class CommentListComponent implements OnInit, OnDestroy {
return c.userNumber === compare;
case this.keyword:
this.selectedKeyword = compare;
return c.keywordsFromQuestioner ? c.keywordsFromQuestioner.includes(compare) : false;
const isInQuestioner = c.keywordsFromQuestioner ? c.keywordsFromQuestioner.includes(compare) : false;
const isInSpacy = c.keywordsFromSpacy ? c.keywordsFromSpacy.includes(compare) : false;
return isInQuestioner || isInSpacy;
case this.answer:
return c.answer;
case this.unanswered:
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment