Browse Source

Fix edge cases in client side

pull/4031/head
Amandee Ellawala 10 months ago
committed by Thomas Kaul
parent
commit
0a4e70dc12
  1. 8
      libs/ui/src/lib/assistant/assistant.component.ts

8
libs/ui/src/lib/assistant/assistant.component.ts

@ -340,11 +340,11 @@ export class GfAssistantComponent implements OnChanges, OnDestroy, OnInit {
type: 'TAG' type: 'TAG'
}, },
{ {
id: this.filterForm.get('holdings').value.dataSource, id: this.filterForm.get('holdings').value?.dataSource,
type: 'DATA_SOURCE' type: 'DATA_SOURCE'
}, },
{ {
id: this.filterForm.get('holdings').value.symbol, id: this.filterForm.get('holdings').value?.symbol,
type: 'SYMBOL' type: 'SYMBOL'
} }
]); ]);
@ -488,7 +488,7 @@ export class GfAssistantComponent implements OnChanges, OnDestroy, OnInit {
public holdingComparisonFunction(option, value): boolean { public holdingComparisonFunction(option, value): boolean {
return ( return (
option.dataSource === value.dataSource && option.symbol === value.symbol option.dataSource === value?.dataSource && option.symbol === value?.symbol
); );
} }
@ -515,7 +515,7 @@ export class GfAssistantComponent implements OnChanges, OnDestroy, OnInit {
(h) => h.dataSource === dataSource && h.symbol === symbol (h) => h.dataSource === dataSource && h.symbol === symbol
); );
const holding = selectedHolding[0]; const holding = selectedHolding[0] ?? null;
this.filterForm.setValue( this.filterForm.setValue(
{ {

Loading…
Cancel
Save