delete unused files/methods in landing pages

This commit is contained in:
Alex Martzios 2022-05-10 12:44:10 +03:00
parent bd6e141801
commit 10c70ad1da
15 changed files with 4 additions and 523 deletions

View File

@ -5,19 +5,11 @@ import { RouterModule } from '@angular/router';
import {IFrameModule} from '../../utils/iframe.module';
import {ErrorMessagesModule} from '../../utils/errorMessages.module';
import {TabResultModule } from '../../searchPages/searchUtils/tabResult.module';
import {MetricsModule} from '../landing-utils/metrics/metrics.module';
import {LandingModule} from '../landing-utils/landing.module';
import {PagingModule} from '../../utils/paging.module';
import {PublicationsTabComponent} from './publicationsTab.component';
import {DatasetsTabComponent} from './datasetsTab.component';
import {SoftwareTabComponent} from './softwareTab.component';
import {OrpsTabComponent} from './orpsTab.component';
import {StatisticsTabComponent} from './statisticsTab.component';
import {ProjectsTabComponent} from './projectsTab.component';
import {DatasourcesTabComponent} from './datasourcesTab.component';
import {OrganizationsTabComponent} from './organizationsTab.component';
import {RelatedDatasourcesTabComponent} from './relatedDatasourcesTab.component';
import {DataProviderComponent} from './dataProvider.component';
@ -45,15 +37,15 @@ import {LoadingModalModule} from "../../utils/modal/loadingModal.module";
@NgModule({
imports:
[CommonModule, FormsModule, RouterModule,
TabResultModule, IFrameModule, ErrorMessagesModule, MetricsModule, LandingModule,
IFrameModule, ErrorMessagesModule, MetricsModule, LandingModule,
DataProvidersServiceModule, ProjectsServiceModule, SearchResearchResultsServiceModule,
PagingModule, Schema2jsonldModule, SEOServiceModule, ShowPublisherModule, HelperModule,
LandingHeaderModule, AlertModalModule, NoLoadPaging, FeedbackModule,
TabsModule, SearchTabModule, LoadingModule, IconsModule, LoadingModalModule
],
declarations:
[PublicationsTabComponent, DatasetsTabComponent, StatisticsTabComponent, ProjectsTabComponent, DatasourcesTabComponent, OrganizationsTabComponent,
RelatedDatasourcesTabComponent, DataProviderComponent, SoftwareTabComponent, OrpsTabComponent
[StatisticsTabComponent,
RelatedDatasourcesTabComponent, DataProviderComponent
],
providers:[
DataProviderService],

View File

@ -1,41 +0,0 @@
import {Component, Input} from '@angular/core';
import { FetchResearchResults } from '../../utils/fetchEntitiesClasses/fetchResearchResults.class';
import {ErrorCodes} from '../../utils/properties/errorCodes';
import{EnvProperties} from '../../utils/properties/env-properties';
@Component({
selector: 'datasetsTab',
template: `
<errorMessages [status]="[fetchDatasets.searchUtils.status]" [type]="'research data'" tab_error_class=true></errorMessages>
<div *ngIf="fetchDatasets.searchUtils.status == errorCodes.DONE">
<div class = "uk-text-right" *ngIf = "fetchDatasets.searchUtils.totalResults > 10" >
<a [queryParams]="paramsForSearchLink"
routerLinkActive="router-link-active" [routerLink]="linkToSearchDatasets" class="uk-button uk-button-text">
View all {{fetchDatasets.searchUtils.totalResults | number}} results
</a>
</div>
<tab-result [results]="fetchDatasets.results"
[status]= "fetchDatasets.searchUtils.status"
type="dataset" urlParam="datasetId">
</tab-result>
</div>
`
})
export class DatasetsTabComponent {
@Input() paramsForSearchLink = {};
@Input() fetchDatasets : FetchResearchResults;
@Input() properties:EnvProperties ;
public linkToSearchDatasets = "";
public errorCodes:ErrorCodes = new ErrorCodes();
constructor () {}
ngOnInit() {
this.linkToSearchDatasets = this.properties.searchLinkToAdvancedDatasets;
}
ngOnDestroy() {}
}

View File

@ -1,44 +0,0 @@
import {Component, Input} from '@angular/core';
import { FetchDataproviders } from '../../utils/fetchEntitiesClasses/fetchDataproviders.class';
import {ErrorCodes} from '../../utils/properties/errorCodes';
import{EnvProperties} from '../../utils/properties/env-properties';
@Component({
selector: 'datasourcesTab',
template: `
<errorMessages [status]="[fetchDataproviders.searchUtils.status]" [type]="'content providers'" tab_error_class=true></errorMessages>
<div *ngIf="fetchDataproviders.searchUtils.status == errorCodes.DONE">
<div class = "uk-text-right" *ngIf = "fetchDataproviders.searchUtils.totalResults > 10">
<a [queryParams]="paramsForSearchLink"
routerLinkActive="router-link-active" [routerLink]="linkToSearchDataproviders" class="uk-button uk-button-text">
View all compatible results
</a>
</div>
<tab-result [(results)]="fetchDataproviders.results"
[(status)]= "fetchDataproviders.status"
type="dataprovider" urlParam="datasourceId"
lazy=false>
</tab-result>
</div>
`
})
export class DatasourcesTabComponent {
@Input() paramsForSearchLink = {};
@Input() fetchDataproviders : FetchDataproviders;
@Input() properties:EnvProperties ;
public linkToSearchDataproviders = "";
public errorCodes:ErrorCodes = new ErrorCodes();
constructor () {}
ngOnInit() {
this.linkToSearchDataproviders = this.properties.searchLinkToAdvancedDataProviders;
}
ngOnDestroy() {}
}

View File

@ -1,56 +0,0 @@
import {Component, Input} from '@angular/core';
import {properties} from "../../../../environments/environment";
@Component({
selector: 'organizationsTab',
template: `
<div *ngIf=" !organizations || organizations.length == 0" class="uk-alert uk-alert-primary uk-animation-fade" role="alert">
No organizations available
</div>
<div *ngIf=" organizations && organizations.length > 0">
<div *ngIf="organizations.length > pageSize" class="uk-margin-bottom">
{{organizations.length | number}} organizations, page {{organizationsPage | number}} of {{totalPages(organizations.length) | number}}
<paging-no-load class="uk-float-right" [currentPage]="organizationsPage" [totalResults]="organizations.length" [size]="pageSize" (pageChange)="updateOrganizationsPage($event)"></paging-no-load>
</div>
<div *ngFor="let item of organizations.slice((organizationsPage-1)*pageSize, organizationsPage*pageSize)">
<h4 *ngIf=" item != undefined && item['id'] != undefined">
<!--a href="{{item['url']}}"-->
<a [queryParams]="{organizationId: item.id}" routerLinkActive="router-link-active" [routerLink]="url">
<p>{{item['name']}}</p>
</a>
</h4>
<h4 *ngIf="item['id'] == undefined">
<p>{{item['name']}}</p>
</h4>
</div>
</div>
`
})
export class OrganizationsTabComponent {
@Input() organizations: {"name": string, "id": string}[];
public organizationsPage: number = 1;
public pageSize: number = 10;
public url = properties.searchLinkToDataProvider.split('?')[0];
constructor () {}
ngOnInit() {}
ngOnDestroy() {}
totalPages(totalResults: number): number {
let totalPages:any = totalResults/this.pageSize;
if(!(Number.isInteger(totalPages))) {
totalPages = (parseInt(totalPages, this.pageSize) + 1);
}
return totalPages;
}
updateOrganizationsPage($event) {
this.organizationsPage = $event.value;
}
}

View File

@ -1,39 +0,0 @@
import {Component, Input} from '@angular/core';
import { FetchResearchResults } from '../../utils/fetchEntitiesClasses/fetchResearchResults.class';
import {ErrorCodes} from '../../utils/properties/errorCodes';
import{EnvProperties} from '../../utils/properties/env-properties';
@Component({
selector: 'orpsTab',
template: `
<errorMessages [status]="[fetchOrps.searchUtils.status]" [type]="'other research products'" tab_error_class=true></errorMessages>
<div *ngIf="fetchOrps.searchUtils.status == errorCodes.DONE">
<div class = "uk-text-right" *ngIf = "fetchOrps.searchUtils.totalResults > 10" >
<a [queryParams]="paramsForSearchLink"
routerLinkActive="router-link-active" [routerLink]="linkToSearchOrps" class="uk-button uk-button-text">
View all {{fetchOrps.searchUtils.totalResults | number}} results
</a>
</div>
<tab-result [results]="fetchOrps.results"
[status]= "fetchOrps.searchUtils.status"
type="other" urlParam="orpId">
</tab-result>
</div>
`
})
export class OrpsTabComponent {
@Input() paramsForSearchLink = {};
@Input() fetchOrps : FetchResearchResults;
@Input() properties:EnvProperties ;
public linkToSearchOrps = "";
public errorCodes:ErrorCodes = new ErrorCodes();
constructor () {}
ngOnInit() {
this.linkToSearchOrps = this.properties.searchLinkToAdvancedOrps;
}
}

View File

@ -1,44 +0,0 @@
import {Component, Input} from '@angular/core';
import { FetchProjects } from '../../utils/fetchEntitiesClasses/fetchProjects.class';
import { ErrorCodes} from '../../utils/properties/errorCodes';
import{EnvProperties} from '../../utils/properties/env-properties';
@Component({
selector: 'projectsTab',
template: `
<errorMessages [status]="[fetchProjects.searchUtils.status]" [type]="'projects'" tab_error_class=true></errorMessages>
<div *ngIf="fetchProjects.searchUtils.status == errorCodes.DONE">
<div class = "uk-text-right" *ngIf = "fetchProjects.searchUtils.totalResults > 10">
<a [queryParams]="paramsForSearchLink"
routerLinkActive="router-link-active" [routerLink]="linkToSearchProjects" class="uk-button uk-button-text">
View all {{fetchProjects.searchUtils.totalResults | number}} results
</a>
</div>
<tab-result [(results)]="fetchProjects.results"
[(status)]= "fetchProjects.status"
type="project" urlParam="projectId">
</tab-result>
</div>
`
})
export class ProjectsTabComponent {
@Input() paramsForSearchLink = {};
@Input() fetchProjects : FetchProjects;
@Input() properties:EnvProperties ;
public linkToSearchProjects = "";
public errorCodes:ErrorCodes = new ErrorCodes();
constructor () {}
ngOnInit() {
this.linkToSearchProjects = this.properties.searchLinkToAdvancedProjects;
}
ngOnDestroy() {}
}

View File

@ -1,42 +0,0 @@
import {Component, Input} from '@angular/core';
import { FetchResearchResults } from '../../utils/fetchEntitiesClasses/fetchResearchResults.class';
import {ErrorCodes} from '../../utils/properties/errorCodes';
import{EnvProperties} from '../../utils/properties/env-properties';
@Component({
selector: 'publicationsTab',
template: `
<errorMessages [status]="[fetchPublications.searchUtils.status]" [type]="'publications'" tab_error_class=true></errorMessages>
<div *ngIf="fetchPublications.searchUtils.status == errorCodes.DONE">
<div class = "uk-text-right" *ngIf = "fetchPublications.searchUtils.totalResults > 10">
<a [queryParams]="paramsForSearchLink"
routerLinkActive="router-link-active" [routerLink]="linkToSearchPublications" class="uk-button uk-button-text">
View all {{fetchPublications.searchUtils.totalResults | number}} results
</a>
</div>
<tab-result [results]="fetchPublications.results"
[status]= "fetchPublications.searchUtils.status"
type="publication" urlParam="articleId">
</tab-result>
</div>
`
})
export class PublicationsTabComponent {
@Input() paramsForSearchLink = {};//: string = "";
@Input() fetchPublications : FetchResearchResults;
@Input() properties:EnvProperties ;
public linkToSearchPublications = "";
public errorCodes:ErrorCodes = new ErrorCodes();
constructor () {}
ngOnInit() {
this.linkToSearchPublications = this.properties.searchLinkToAdvancedPublications
}
ngOnDestroy() {}
}

View File

@ -1,40 +0,0 @@
import {Component, Input} from '@angular/core';
import { FetchResearchResults } from '../../utils/fetchEntitiesClasses/fetchResearchResults.class';
import {ErrorCodes} from '../../utils/properties/errorCodes';
import{EnvProperties} from '../../utils/properties/env-properties';
@Component({
selector: 'softwareTab',
template: `
<errorMessages [status]="[fetchSoftware.searchUtils.status]" [type]="'software'" tab_error_class=true></errorMessages>
<div *ngIf="fetchSoftware.searchUtils.status == errorCodes.DONE">
<div class = "uk-text-right" *ngIf = "fetchSoftware.searchUtils.totalResults > 10" >
<a [queryParams]="paramsForSearchLink"
routerLinkActive="router-link-active" [routerLink]="linkToSearchSoftware" class="uk-button uk-button-text">
View all {{fetchSoftware.searchUtils.totalResults | number}} results
</a>
</div>
<tab-result [results]="fetchSoftware.results"
[status]= "fetchSoftware.searchUtils.status"
type="software" urlParam="softwareId">
</tab-result>
</div>
`
})
export class SoftwareTabComponent {
@Input() paramsForSearchLink = {};
@Input() fetchSoftware : FetchResearchResults;
@Input() properties:EnvProperties ;
public linkToSearchSoftware = "";
public errorCodes:ErrorCodes = new ErrorCodes();
constructor () {}
ngOnInit() {
this.linkToSearchSoftware = this.properties.searchLinkToAdvancedSoftware;
}
}

View File

@ -6,7 +6,6 @@ import {FormsModule} from '@angular/forms';
import {RouterModule} from '@angular/router';
import {ProjectsServiceModule} from '../../services/projectsService.module';
import {TabResultModule} from '../../searchPages/searchUtils/tabResult.module';
import {ProjectsInModalComponent} from './projects-in-modal.component';
import {PagingModule} from '../../utils/paging.module';
@ -18,7 +17,7 @@ import {SearchFilterModule} from '../../searchPages/searchUtils/searchFilter.mod
@NgModule({
imports: [
RouterModule, CommonModule, FormsModule,
ProjectsServiceModule, TabResultModule,
ProjectsServiceModule,
PagingModule, ErrorMessagesModule, NoLoadPaging,
SearchResultsModule, SearchFilterModule
],

View File

@ -788,22 +788,6 @@ export class OrganizationComponent {
// return this._numberOfTabs;
// }
private getEntityName(entityType: string, plural: boolean, full: boolean): string {
if (entityType == "publication") {
return "publication" + (plural ? "s" : "");
} else if (entityType == "dataset") {
return (full ? "research data" : ("dataset" + (plural ? "s" : "")));
} else if (entityType == "software") {
return "software";
} else if (entityType == "other") {
return (full ? ("other research product" + (plural ? "s" : "")) : "other");
} else if (entityType == "dataprovider") {
return (full ? ("content provider" + (plural ? "s" : "")) : "dataprovider" + (plural ? "s" : ""));
} else {
return entityType + (plural ? "s" : "");
}
}
public buildFunderOptions() {
this.funderOptions = [];
if(this.fetchProjects.funders && this.fetchProjects.funders.length > 0) {

View File

@ -10,7 +10,6 @@ import {ErrorMessagesModule} from '../../utils/errorMessages.module';
import {OrganizationServiceModule} from '../../services/organizationService.module';
import {OrganizationComponent} from './organization.component';
import {LandingModule} from '../landing-utils/landing.module';
import {TabResultModule} from '../../searchPages/searchUtils/tabResult.module';
import {DataProvidersServiceModule} from '../../services/dataProvidersService.module';
import {ReportsServiceModule} from '../../services/reportsService.module';
import {SearchResearchResultsServiceModule} from '../../services/searchResearchResultsService.module';
@ -39,7 +38,6 @@ import {graph} from "../../utils/icons/icons";
CommonModule, FormsModule, RouterModule,
LoadingModalModule, AlertModalModule, ErrorMessagesModule,
LandingModule,
TabResultModule,
DataProvidersServiceModule,
ReportsServiceModule,
OrganizationServiceModule,

View File

@ -856,22 +856,6 @@ export class ProjectComponent {
return false;
}
private getEntityName (entityType:string, plural:boolean, full:boolean): string {
if(entityType == "publication") {
return "publication" + (plural ? "s" : "");
} else if(entityType == "dataset") {
return (full ? "research data" : ("dataset" + (plural ? "s" : "")));
} else if(entityType == "software") {
return "software";
} else if(entityType == "other") {
return (full ? ("other research product" + (plural ? "s" : "")) : "other");
} else if(entityType == "dataprovider") {
return (full ? ("content provider" + (plural ? "s" : "")) : "dataprovider" + (plural ? "s" : ""));
} else {
return entityType + (plural ? "s" : "");
}
}
public getResultPreview(result: SearchResult, type: string): ResultPreview {
return ResultPreview.searchResultConvert(result, type);
}

View File

@ -1,116 +0,0 @@
<ul class="uk-list uk-list-divider uk-margin">
<li *ngFor="let result of results">
<!-- <div class = "uk-h4 {{result.title.accessMode}} {{result.title.sc39}}" [title] = result.title.accessMode >
<a [queryParams]="routerHelper.createQueryParam(urlParam,result.id)" routerLinkActive="router-link-active" routerLink="/search/{{type}}">
<span *ngIf="result['title'].name || result.acronym">
<span *ngIf="result.acronym">{{result.acronym}}</span>
<span *ngIf="result.acronym && result['title'].name">-</span>
<span *ngIf="result['title'].name" [innerHTML]="result['title'].name"></span>
<span *ngIf="result.code">({{result.code}})</span>
</span>
<span *ngIf="!result['title'].name && !result.acronym">
[no title available]
<span *ngIf="result.code">({{result.code}})</span>
</span>
</a>
</div> -->
<h6 [title] = result.title.accessMode >
<a *ngIf="!result.compatibilityUNKNOWN" [queryParams]="routerHelper.createQueryParam(urlParam,result.id)" routerLinkActive="router-link-active" routerLink="/search/{{type}}">
<p *ngIf="result['title'].name || result.acronym"><span *ngIf="result.acronym">{{result.acronym}}</span><span *ngIf="result.acronym && result['title'].name">-</span><span *ngIf="result['title'].name" [innerHTML]="result['title'].name"></span><span *ngIf="result.code"> ({{result.code}})</span></p>
<p *ngIf="!result['title'].name && !result.acronym">[no title available]<span *ngIf="result.code"> ({{result.code}})</span></p>
</a>
<p *ngIf="result.compatibilityUNKNOWN && result['title'].name"
title="Incompatible content provider" [innerHTML]="result['title'].name">
</p>
<p *ngIf="result.compatibilityUNKNOWN && !result['title'].name"
title="Incompatible content provider" >[no title available]
</p>
</h6>
<span *ngIf="result.types && result.types.length > 0" [class]="'uk-label custom-label label-blue label-'+result.entityType" title="Type">{{result.types.join(", ")}}</span>
<span *ngIf="result.programmingLanguages && result.programmingLanguages.length > 0" class="uk-label custom-label label-progrLanguage " title="Programming Language">{{result.programmingLanguages.join(", ")}}</span>
<span *ngIf="result.languages && result.languages.length > 0" class="uk-label custom-label label-language " title="Language">{{result.languages.join(", ")}}</span>
<span *ngIf="result.countriesForResults && result.countriesForResults.length > 0" class="uk-label custom-label label-country " title="Country">{{result.countriesForResults.join(", ")}}</span>
<span *ngIf="result.title && result.title.accessMode" [class]="'uk-label custom-label label-'+ result.title.accessMode " title="Access Mode">{{result.title.accessMode}}</span>
<span *ngIf="result['funderShortname']" class="uk-label custom-label label-funder " title="Funder">{{result['funderShortname']}}</span>
<span *ngIf="result.openAccessMandatePublications != undefined && result.openAccessMandatePublications && (result.openAccessMandateDatasets == undefined || !result.openAccessMandateDatasets)"
class="uk-label custom-label label-open uk-text-truncate" title="Open Access mandate for Publications">Open Access mandate for Publications</span>
<span *ngIf="result.openAccessMandateDatasets != undefined && result.openAccessMandateDatasets && (result.openAccessMandatePublications == undefined || !result.openAccessMandatePublications)"
class="uk-label custom-label label-open uk-text-truncate" title="Open Access mandate for Research Data">Open Access mandate for Research Data</span>
<span *ngIf="result.openAccessMandatePublications != undefined && result.openAccessMandatePublications && result.openAccessMandateDatasets != undefined && result.openAccessMandateDatasets"
class="uk-label custom-label label-open uk-text-truncate" title="Open Access mandate for Publications and Research Data">Open Access mandate for Publications and Research Data</span>
<div *ngIf="result.publisher != undefined && result.publisher != ''"><span class="uk-text-bold">Publisher:</span> {{result.publisher}}</div>
<span *ngIf="result['type'] != undefined && result['type'] != ''" class="uk-label custom-label label-blue label-dataprovider" title="Type"> {{result['type']}}</span>
<span *ngIf="result['compatibility'] != undefined && result['compatibility'] != ''" class="uk-label custom-label label-compatibility" title="Compatibility">{{result.compatibility}}</span>
<span *ngIf="result.country != undefined && result.country != ''" class="uk-label custom-label label-country" title="Country"> {{result.country}}</span>
<div class="uk-margin-small">
<!-- <span *ngIf="result['authors'] != undefined" class="resultsAuthors uk-margin-small-top" style="font-style: italic;">-->
<!-- <span *ngFor="let author of result['authors'].slice(0,15)">-->
<!-- {{author}};-->
<!-- </span>-->
<!-- <span *ngIf="result['authors'].length > 15">...</span>-->
<!-- </span>-->
<showAuthors [authors]="result['authors']" [authorsLimit]=15 [showAll]=false></showAuthors>
<span *ngIf="result.year != undefined && result.year != ''">
({{result.year}})
</span>
</div>
<div *ngIf="result['projects'] != undefined">
<span> Project: </span>
<span *ngFor="let project of result['projects'].slice(0,15) let i=index">
<a *ngIf="project.id" [queryParams]="{projectId: project.id}" routerLinkActive="router-link-active" routerLink="/search/project">
{{project['funderShortname']?project['funderShortname']:project['funderName']}}
| {{ project['acronym']?project['acronym']:(project['title'].length>25?project['title'].substring(0,25)+'...':project['title'])}} ({{project.code}})</a><span
*ngIf="!project.id">{{project['funderShortname']?project['funderShortname']:project['funderName']}}<span
*ngIf="project['acronym'] || project['title']"> | {{ project['acronym']?project['acronym']:(project['title'].length>25?project['title'].substring(0,25)+'...':project['title'])}}</span><span
*ngIf="project.code">({{project.code}})</span></span><span
*ngIf="i < result['projects'].length-1">,</span>
</span>
<span *ngIf="result['projects'].length > 15">...</span>
</div>
<span *ngIf="result.embargoEndDate != undefined && result.embargoEndDate != ''">Embargo End Date: {{result.embargoEndDate}}</span>
<div *ngIf="result.startYear && result.endYear"> Start year: {{result.startYear}} - End year: {{result.endYear}}</div>
<div *ngIf="showOrganizations && result['organizations'] != undefined && result['organizations'].length > 0">
<span> Organization: </span>
<span *ngFor="let organization of result['organizations'].slice(0,10) let i=index">
<a *ngIf="organization.id" [queryParams]="{organizationId: organization.id}" routerLinkActive="router-link-active" routerLink="/search/organization">
{{organization.name}}</a><span
*ngIf="!organization.id">
{{organization.name}}</span><span
*ngIf="(i < result['organizations'].length-1) && (i < 9)">,</span>
</span>
<span *ngIf="result['organizations'].length > 10">...</span>
</div>
<div *ngIf="result['countries'] && result['countries'].length > 0">
Country: <span *ngFor="let country of result['countries'].slice(0,10) let i = index">{{country}}{{(i < ( result['countries'].slice(0,10).length-1))?", ":""}}{{(i == result['countries'].slice(0,10).length-1 && result['countries'].length > 10)?"...":""}}</span>
</div>
<div *ngIf="result['websiteURL'] != undefined && result['websiteURL'] != ''">
<span>Website URL: </span>
<span>
<a href="{{result['websiteURL']}}" target="_blank">
<span class="custom-external custom-icon"></span>
{{result['websiteURL']}}
</a>
</span>
</div>
<div *ngIf="result['OAIPMHURL'] != undefined && result['OAIPMHURL'] != ''">
<span>OAI-PMH URL: </span>
<span>
<a href="{{result['OAIPMHURL']}}" target="_blank">
<span class="custom-external custom-icon"></span>
{{result['OAIPMHURL']}}
</a>
</span>
</div>
</li>
</ul>

View File

@ -1,31 +0,0 @@
import {Component, Input} from '@angular/core';
import {SearchResult} from '../../utils/entities/searchResult';
import {ErrorCodes} from '../../utils/properties/errorCodes';
import {RouterHelper} from '../../utils/routerHelper.class';
@Component({
selector: 'tab-result',
templateUrl: 'tabResult.component.html'
})
export class TabResultComponent {
@Input() results: SearchResult[];
@Input() status: number;
@Input() type: string;
@Input() urlParam: string;
@Input() showLoading: boolean = false;
@Input() showOrganizations: boolean = true;
public errorCodes:ErrorCodes = new ErrorCodes();
public routerHelper:RouterHelper = new RouterHelper();
public errorMessage: string = "No results found";
constructor () {
}
ngOnInit() {}
public quote(params: string):string {
return '"'+params+'"';
}
}

View File

@ -1,23 +0,0 @@
import { NgModule} from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import {TabResultComponent} from './tabResult.component';
import {RouterModule} from '@angular/router';
import {ShowAuthorsModule} from "../../utils/authors/showAuthors.module";
@NgModule({
imports: [
CommonModule, FormsModule,
RouterModule, ShowAuthorsModule
],
declarations: [
TabResultComponent,
],
providers:[
],
exports: [
TabResultComponent
]
})
export class TabResultModule { }