[develop | DONE | CHANGED]: searchAll.component.html: Changed pipe from "| number" to " | numberRound" to round number of results in slider tabs | searchAll.module.ts: Imported NumberRoundModule.

This commit is contained in:
Konstantina Galouni 2024-02-05 11:52:57 +02:00
parent f63e7d72cc
commit b12877df2a
2 changed files with 14 additions and 13 deletions

View File

@ -36,17 +36,17 @@
<ng-template #result>
<span class="uk-text-uppercase">
{{resultsName}}
<span *ngIf=" fetchPublications.searchUtils.totalResults!=null" class="uk-visible@m">
({{fetchPublications.searchUtils.totalResults | number}})</span>
</span>
<span *ngIf=" fetchPublications.searchUtils.totalResults!=null" class="uk-visible@m"
[innerHTML]="'('+(fetchPublications.searchUtils.totalResults | numberRound)+')'"></span>
</span>
</ng-template>
</slider-tab>
<slider-tab *ngIf="showProjects" tabId="projects" [tabTemplate]="projects" [active]="activeEntity == 'projects'">
<ng-template #projects>
<span class="uk-text-uppercase">
{{projectName}}
<span *ngIf="fetchProjects.searchUtils.totalResults!=null" class="uk-visible@m">
({{fetchProjects.searchUtils.totalResults | number}})</span>
<span *ngIf="fetchProjects.searchUtils.totalResults!=null" class="uk-visible@m"
[innerHTML]="'('+(fetchProjects.searchUtils.totalResults | numberRound)+')'"></span>
</span>
</ng-template>
</slider-tab>
@ -54,8 +54,8 @@
<ng-template #datasources>
<span class="uk-text-uppercase">
{{dataSourcesName}}
<span *ngIf="fetchDataproviders.searchUtils.totalResults!=null" class="uk-visible@m">
({{fetchDataproviders.searchUtils.totalResults | number}})</span>
<span *ngIf="fetchDataproviders.searchUtils.totalResults!=null" class="uk-visible@m"
[innerHTML]="'('+(fetchDataproviders.searchUtils.totalResults | numberRound)+')'"></span>
</span>
</ng-template>
</slider-tab>
@ -63,8 +63,8 @@
<ng-template #services>
<span class="uk-text-uppercase">
{{servicesName}}
<span *ngIf="fetchServices.searchUtils.totalResults!=null" class="uk-visible@m">
({{fetchServices.searchUtils.totalResults | number}})</span>
<span *ngIf="fetchServices.searchUtils.totalResults!=null" class="uk-visible@m"
[innerHTML]="'('+(fetchServices.searchUtils.totalResults | numberRound)+')'"></span>
</span>
</ng-template>
</slider-tab>
@ -72,9 +72,9 @@
<ng-template #organizations>
<span class="uk-text-uppercase">
{{organizationsName}}
<span *ngIf="fetchOrganizations.searchUtils.totalResults!=null" class="uk-visible@m">
({{fetchOrganizations.searchUtils.totalResults | number}})</span>
</span>
<span *ngIf="fetchOrganizations.searchUtils.totalResults!=null" class="uk-visible@m"
[innerHTML]="'('+(fetchOrganizations.searchUtils.totalResults | numberRound)+')'"></span>
</span>
</ng-template>
</slider-tab>
</slider-tabs>

View File

@ -23,13 +23,14 @@ import {SearchDataProvidersModule} from "../searchDataProviders.module";
import {PreviousRouteRecorder} from "../../utils/piwik/previousRouteRecorder.guard";
import {BreadcrumbsModule} from "../../utils/breadcrumbs/breadcrumbs.module";
import {SliderTabsModule} from "../../sharedComponents/tabs/slider-tabs.module";
import {NumberRoundModule} from "../../utils/pipes/number-round.module";
@NgModule({
imports: [
CommonModule, FormsModule, RouterModule,
DataProvidersServiceModule, ProjectsServiceModule,
SearchResearchResultsServiceModule, OrganizationsServiceModule,
SearchResultsModule, PiwikServiceModule, Schema2jsonldModule, SEOServiceModule, AdvancedSearchFormModule, SearchResearchResultsModule, SearchProjectsModule, SearchOrganizationsModule, SearchDataProvidersModule, BreadcrumbsModule, SliderTabsModule
SearchResultsModule, PiwikServiceModule, Schema2jsonldModule, SEOServiceModule, AdvancedSearchFormModule, SearchResearchResultsModule, SearchProjectsModule, SearchOrganizationsModule, SearchDataProvidersModule, BreadcrumbsModule, SliderTabsModule, NumberRoundModule
],
declarations: [
SearchAllComponent