[Trunk | Library]:

1. dataProvider.component.html: Show 'Related Content Providers' only when there are results (publications and/or datasets and/or software and/or other).
2. searchFilter.component.html: Use 'filterValuesNum' field for method 'getSelectedAndTopValues()'.
3. searchFilter.component.ts: Default value for 'filterValuesNum' field changed from 4 to 6.


git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@58568 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
konstantina.galouni 2020-04-28 10:07:53 +00:00
parent cc5813a5d6
commit b4fd5d7892
3 changed files with 7 additions and 4 deletions

View File

@ -332,7 +332,8 @@
<div
class="uk-margin-top simple-buttons uk-flex uk-flex-middle">
<!-- *ngIf="dataProviderInfo.tabs2.indexOf('Related Content Providers') != -1"-->
<div
<div *ngIf="(fetchPublications.searchUtils.totalResults > 0 || fetchDatasets.searchUtils.totalResults > 0
|| fetchSoftware.searchUtils.totalResults > 0 || fetchOrps.searchUtils.totalResults > 0)"
(click)="openRelatedDatasources()" class="clickable uk-margin-right">
<span class="uk-text-middle">Related Content Providers</span>
</div>
@ -629,7 +630,9 @@
<!-- && dataProviderInfo.relatedDatasources && dataProviderInfo.relatedDatasources.size > 0-->
<!-- && dataProviderInfo.tabs2 && dataProviderInfo.tabs2.indexOf('Related Content Providers') != -1-->
<modal-alert *ngIf="dataProviderInfo"
<modal-alert *ngIf="dataProviderInfo &&
(fetchPublications.searchUtils.totalResults > 0 || fetchDatasets.searchUtils.totalResults > 0
|| fetchSoftware.searchUtils.totalResults > 0 || fetchOrps.searchUtils.totalResults > 0)"
classBody="uk-width-xxlarge uk-padding-remove-right" #relatedDatasourcesModal>
<landing-header [properties]="properties" [title]="dataProviderInfo.title.name"
[subTitle]="(dataProviderInfo.officialName

View File

@ -33,7 +33,7 @@
<!-- </div>-->
<!-- </div>-->
<div *ngFor="let value of getSelectedAndTopValues(filter, 6)"
<div *ngFor="let value of getSelectedAndTopValues(filter, filterValuesNum)"
class="uk-animation-fade filterItem searchFilterItem uk-text-small">
<div title = "{{value.name}}">
<label *ngIf="filter.filterType == 'checkbox' || filter.filterType == 'radio'">

View File

@ -13,7 +13,7 @@ export class SearchFilterComponent {
@Input() isDisabled:boolean = false;
@Input() addShowMore:boolean = true;
@Input() showMoreInline: boolean = true;
@Input() filterValuesNum: number = 4;
@Input() filterValuesNum: number = 6;
public showAll:boolean = false;
public _maxCharacters:number =28;