Browse Source
fix(assistant): mark form dirty when active filters exist to enable Apply button
pull/6469/head
Aniruddha Khandare
4 weeks ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
13 additions and
4 deletions
-
libs/ui/src/lib/assistant/assistant.component.ts
|
|
|
@ -762,11 +762,20 @@ export class GfAssistantComponent implements OnChanges, OnDestroy, OnInit { |
|
|
|
); |
|
|
|
}); |
|
|
|
|
|
|
|
const account = |
|
|
|
this.user?.settings?.['filters.accounts']?.[0] ?? null; |
|
|
|
const assetClass = |
|
|
|
this.user?.settings?.['filters.assetClasses']?.[0] ?? null; |
|
|
|
const tag = this.user?.settings?.['filters.tags']?.[0] ?? null; |
|
|
|
|
|
|
|
this.portfolioFilterFormControl.setValue({ |
|
|
|
account: this.user?.settings?.['filters.accounts']?.[0] ?? null, |
|
|
|
assetClass: this.user?.settings?.['filters.assetClasses']?.[0] ?? null, |
|
|
|
account, |
|
|
|
assetClass, |
|
|
|
holding: selectedHolding ?? null, |
|
|
|
tag: this.user?.settings?.['filters.tags']?.[0] ?? null |
|
|
|
tag |
|
|
|
}); |
|
|
|
|
|
|
|
if (account || assetClass || selectedHolding || tag) { |
|
|
|
this.portfolioFilterFormControl.markAsDirty(); |
|
|
|
} |
|
|
|
} |
|
|
|
|