diff --git a/libs/models/ramp-models/src/lib/analyte.ts b/libs/models/ramp-models/src/lib/analyte.ts index c4ad669..a5b20aa 100644 --- a/libs/models/ramp-models/src/lib/analyte.ts +++ b/libs/models/ramp-models/src/lib/analyte.ts @@ -15,7 +15,7 @@ export class Analyte { } if (obj.sourceAnalyteIDs) { this.sourceAnalyteIDs = obj.sourceAnalyteIDs - .split('; ') + .split(',') .sort((a: string, b: string) => a.localeCompare(b)) .join('; '); } diff --git a/libs/models/ramp-models/src/lib/metabolite.ts b/libs/models/ramp-models/src/lib/metabolite.ts index 7bd2959..32fa206 100644 --- a/libs/models/ramp-models/src/lib/metabolite.ts +++ b/libs/models/ramp-models/src/lib/metabolite.ts @@ -6,5 +6,9 @@ export class Metabolite { constructor(obj: Partial) { Object.assign(this, obj); + + if(obj['metIds']){ + this.metIds = (obj["metIds"]).replace(/,/g, ', ') + } } } diff --git a/libs/models/ramp-models/src/lib/reaction.ts b/libs/models/ramp-models/src/lib/reaction.ts index 78312ba..d2dcbb5 100644 --- a/libs/models/ramp-models/src/lib/reaction.ts +++ b/libs/models/ramp-models/src/lib/reaction.ts @@ -24,8 +24,10 @@ export class Reaction { } if (obj['rxn_partner_ids']) { - this.rxnPartnerIdsString = obj['rxn_partner_ids']; - this.rxnPartnerIds = this.rxnPartnerIdsString.split('; '); + this.rxnPartnerIdsString = (obj['rxn_partner_ids']).replace(/,/g, ', '); + console.log(obj['rxn_partner_ids']) + console.log(this.rxnPartnerIdsString) + this.rxnPartnerIds = this.rxnPartnerIdsString.split(','); } } }