[Library | develop] fos/fos.component.ts & landing-utilts/fos.component.ts & searchFields.ts: Restored checks for environment to use fos or foslabel field - foslabel not yet introduced in current prod index.
This commit is contained in:
parent
af95b395bd
commit
edf8ae835c
|
@ -216,6 +216,7 @@ export class FosComponent implements OnInit, OnDestroy {
|
|||
}
|
||||
|
||||
public buildFosQueryParam(fos) {
|
||||
return {'foslabel': this.urlEncodeAndQuote(fos.id+"||"+fos.label)};
|
||||
// return {'foslabel': this.urlEncodeAndQuote(fos.id+"||"+fos.label)};
|
||||
return (properties.environment !== 'production' ? ({'foslabel': this.urlEncodeAndQuote(fos.id+"||"+fos.label)}) : ({'fos': this.urlEncodeAndQuote(fos.id)}));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -121,10 +121,12 @@ export class FosComponent {
|
|||
}
|
||||
|
||||
public buildFosQueryParam(fos) {
|
||||
return {'foslabel': this.urlEncodeAndQuote(fos.id+"||"+fos.label)};
|
||||
// return {'foslabel': this.urlEncodeAndQuote(fos.id+"||"+fos.label)};
|
||||
return (properties.environment !== 'production' ? ({'foslabel': this.urlEncodeAndQuote(fos.id+"||"+fos.label)}) : ({'fos': this.urlEncodeAndQuote(fos.id)}));
|
||||
}
|
||||
|
||||
public buildFosHrefParam(fos): string {
|
||||
return ('foslabel='+this.urlEncodeAndQuote(fos.id+"||"+fos.label));
|
||||
// return ('foslabel='+this.urlEncodeAndQuote(fos.id+"||"+fos.label));
|
||||
return (properties.environment !== 'production' ? ('foslabel='+this.urlEncodeAndQuote(fos.id+"||"+fos.label)) : ('fos='+this.urlEncodeAndQuote(fos.id)));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,7 +14,7 @@ export class SearchFields {
|
|||
|
||||
// Remove Collected From Filter "collectedfrom","collectedfrom"
|
||||
public RESULT_REFINE_FIELDS = [
|
||||
"resultbestaccessright", "instancetypename", "foslabel", "relfunder",
|
||||
"resultbestaccessright", "instancetypename", properties.environment!='production'?"foslabel":'fos', "relfunder",
|
||||
"relfundinglevel0_id", "relfundinglevel1_id", "relfundinglevel2_id",
|
||||
"relproject", "sdg", "country", "resultlanguagename", "resulthostingdatasource", "community"];
|
||||
|
||||
|
|
Loading…
Reference in New Issue