initiate custom filter properly
chnage check to initialize isSearch variable (browse menu)
This commit is contained in:
parent
5e47e4c237
commit
0ef14ca586
|
@ -121,7 +121,7 @@ export class RepositoryComponent extends StakeholderBaseComponent implements OnI
|
||||||
private configurationService: ConfigurationService) {
|
private configurationService: ConfigurationService) {
|
||||||
super();
|
super();
|
||||||
super.initRouterParams(this._route, event => {
|
super.initRouterParams(this._route, event => {
|
||||||
this.isSearch = event.url.includes('search');
|
this.isSearch = event.url.includes('/search');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -131,10 +131,10 @@ export class RepositoryComponent extends StakeholderBaseComponent implements OnI
|
||||||
this.description = 'Repository Monitors';
|
this.description = 'Repository Monitors';
|
||||||
this.setMetadata();
|
this.setMetadata();
|
||||||
this.params.subscribe(params => {
|
this.params.subscribe(params => {
|
||||||
this._customFilterService.setCustomFilter(null);
|
|
||||||
this.alias = params['stakeholder'];
|
this.alias = params['stakeholder'];
|
||||||
if (this.alias) {
|
if (this.alias) {
|
||||||
if(this.stakeholder?.alias !== this.alias) {
|
if(this.stakeholder?.alias !== this.alias) {
|
||||||
|
this._customFilterService.setCustomFilter(null);
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
this.subscriptions.push(this.stakeholderService.getStakeholder(this.alias, true).subscribe(stakeholder => {
|
this.subscriptions.push(this.stakeholderService.getStakeholder(this.alias, true).subscribe(stakeholder => {
|
||||||
this.stakeholder = stakeholder;
|
this.stakeholder = stakeholder;
|
||||||
|
@ -160,6 +160,7 @@ export class RepositoryComponent extends StakeholderBaseComponent implements OnI
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.stakeholder = null;
|
this.stakeholder = null;
|
||||||
|
this._customFilterService.setCustomFilter(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -85,7 +85,7 @@ export class RfoComponent extends StakeholderBaseComponent implements OnInit {
|
||||||
private configurationService: ConfigurationService) {
|
private configurationService: ConfigurationService) {
|
||||||
super();
|
super();
|
||||||
super.initRouterParams(this._route, event => {
|
super.initRouterParams(this._route, event => {
|
||||||
this.isSearch = event.url.includes('search');
|
this.isSearch = event.url.includes('/search');
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -96,11 +96,11 @@ export class RfoComponent extends StakeholderBaseComponent implements OnInit {
|
||||||
this.description = 'RFOs';
|
this.description = 'RFOs';
|
||||||
this.setMetadata();
|
this.setMetadata();
|
||||||
this.params.subscribe(params => {
|
this.params.subscribe(params => {
|
||||||
this._customFilterService.setCustomFilter(null);
|
|
||||||
this.alias = params['stakeholder'];
|
this.alias = params['stakeholder'];
|
||||||
if (this.alias) {
|
if (this.alias) {
|
||||||
if(this.stakeholder?.alias !== this.alias) {
|
if(this.stakeholder?.alias !== this.alias) {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
|
this._customFilterService.setCustomFilter(null);
|
||||||
this.subscriptions.push(this.stakeholderService.getStakeholder(this.alias, true).subscribe(stakeholder => {
|
this.subscriptions.push(this.stakeholderService.getStakeholder(this.alias, true).subscribe(stakeholder => {
|
||||||
this.stakeholder = stakeholder;
|
this.stakeholder = stakeholder;
|
||||||
if (this.stakeholder && this.stakeholder.type === 'funder') {
|
if (this.stakeholder && this.stakeholder.type === 'funder') {
|
||||||
|
@ -120,6 +120,7 @@ export class RfoComponent extends StakeholderBaseComponent implements OnInit {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.stakeholder = null;
|
this.stakeholder = null;
|
||||||
|
this._customFilterService.setCustomFilter(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -85,7 +85,7 @@ export class RpoComponent extends StakeholderBaseComponent implements OnInit {
|
||||||
private configurationService: ConfigurationService) {
|
private configurationService: ConfigurationService) {
|
||||||
super();
|
super();
|
||||||
super.initRouterParams(this._route, event => {
|
super.initRouterParams(this._route, event => {
|
||||||
this.isSearch = event.url.includes('search');
|
this.isSearch = event.url.includes('/search');
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -96,11 +96,11 @@ export class RpoComponent extends StakeholderBaseComponent implements OnInit {
|
||||||
this.description = 'RPOs';
|
this.description = 'RPOs';
|
||||||
this.setMetadata();
|
this.setMetadata();
|
||||||
this.params.subscribe(params => {
|
this.params.subscribe(params => {
|
||||||
this._customFilterService.setCustomFilter(null);
|
|
||||||
this.alias = params['stakeholder'];
|
this.alias = params['stakeholder'];
|
||||||
if (this.alias) {
|
if (this.alias) {
|
||||||
if(this.stakeholder?.alias !== this.alias) {
|
if(this.stakeholder?.alias !== this.alias) {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
|
this._customFilterService.setCustomFilter(null);
|
||||||
this.subscriptions.push(this.stakeholderService.getStakeholder(this.alias, true).subscribe(stakeholder => {
|
this.subscriptions.push(this.stakeholderService.getStakeholder(this.alias, true).subscribe(stakeholder => {
|
||||||
this.stakeholder = stakeholder;
|
this.stakeholder = stakeholder;
|
||||||
if (this.stakeholder && this.stakeholder.type === 'organization') {
|
if (this.stakeholder && this.stakeholder.type === 'organization') {
|
||||||
|
@ -120,6 +120,8 @@ export class RpoComponent extends StakeholderBaseComponent implements OnInit {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.stakeholder = null;
|
this.stakeholder = null;
|
||||||
|
this._customFilterService.setCustomFilter(null);
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue