Skip to content
Snippets Groups Projects
Commit 1008bd16 authored by Yana De Pauw's avatar Yana De Pauw
Browse files

64424: Angular impact of changes to relationship type changes

parent 0ad505ba
No related branches found
No related tags found
No related merge requests found
...@@ -58,10 +58,10 @@ export const filterRelationsByTypeLabel = (label: string, thisId?: string) => ...@@ -58,10 +58,10 @@ export const filterRelationsByTypeLabel = (label: string, thisId?: string) =>
return relatedItems$.pipe( return relatedItems$.pipe(
map((arr) => relsCurrentPage.filter((rel: Relationship, idx: number) => map((arr) => relsCurrentPage.filter((rel: Relationship, idx: number) =>
hasValue(relTypesCurrentPage[idx]) && ( hasValue(relTypesCurrentPage[idx]) && (
(hasNoValue(thisId) && (relTypesCurrentPage[idx].leftLabel === label || (hasNoValue(thisId) && (relTypesCurrentPage[idx].leftwardType === label ||
relTypesCurrentPage[idx].rightLabel === label)) || relTypesCurrentPage[idx].rightwardType === label)) ||
(thisId === arr[idx][0].id && relTypesCurrentPage[idx].leftLabel === label) || (thisId === arr[idx][0].id && relTypesCurrentPage[idx].leftwardType === label) ||
(thisId === arr[idx][1].id && relTypesCurrentPage[idx].rightLabel === label) (thisId === arr[idx][1].id && relTypesCurrentPage[idx].rightwardType === label)
) )
)) ))
); );
......
...@@ -23,7 +23,7 @@ export class NormalizedRelationshipType extends NormalizedObject<RelationshipTyp ...@@ -23,7 +23,7 @@ export class NormalizedRelationshipType extends NormalizedObject<RelationshipTyp
* The label that describes the Relation to the left of this RelationshipType * The label that describes the Relation to the left of this RelationshipType
*/ */
@autoserialize @autoserialize
leftLabel: string; leftwardType: string;
/** /**
* The maximum amount of Relationships allowed to the left of this RelationshipType * The maximum amount of Relationships allowed to the left of this RelationshipType
...@@ -41,7 +41,7 @@ export class NormalizedRelationshipType extends NormalizedObject<RelationshipTyp ...@@ -41,7 +41,7 @@ export class NormalizedRelationshipType extends NormalizedObject<RelationshipTyp
* The label that describes the Relation to the right of this RelationshipType * The label that describes the Relation to the right of this RelationshipType
*/ */
@autoserialize @autoserialize
rightLabel: string; rightwardType: string;
/** /**
* The maximum amount of Relationships allowed to the right of this RelationshipType * The maximum amount of Relationships allowed to the right of this RelationshipType
......
...@@ -33,7 +33,7 @@ export class RelationshipType implements CacheableObject { ...@@ -33,7 +33,7 @@ export class RelationshipType implements CacheableObject {
/** /**
* The label that describes the Relation to the left of this RelationshipType * The label that describes the Relation to the left of this RelationshipType
*/ */
leftLabel: string; leftwardType: string;
/** /**
* The maximum amount of Relationships allowed to the left of this RelationshipType * The maximum amount of Relationships allowed to the left of this RelationshipType
...@@ -48,7 +48,7 @@ export class RelationshipType implements CacheableObject { ...@@ -48,7 +48,7 @@ export class RelationshipType implements CacheableObject {
/** /**
* The label that describes the Relation to the right of this RelationshipType * The label that describes the Relation to the right of this RelationshipType
*/ */
rightLabel: string; rightwardType: string;
/** /**
* The maximum amount of Relationships allowed to the right of this RelationshipType * The maximum amount of Relationships allowed to the right of this RelationshipType
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment