From 0b6828a72ba5aa84fc41f2ac9d04b7de08a5d08c Mon Sep 17 00:00:00 2001 From: Vijay Oommen Date: Thu, 27 Feb 2025 14:49:13 -0600 Subject: [PATCH] [PM-18456] Display unassigned items in reports (#13612) --- .../pages/organizations/exposed-passwords-report.component.ts | 3 +++ .../organizations/inactive-two-factor-report.component.ts | 3 +++ .../pages/organizations/reused-passwords-report.component.ts | 3 +++ .../pages/organizations/unsecured-websites-report.component.ts | 3 +++ .../pages/organizations/weak-passwords-report.component.ts | 3 +++ 5 files changed, 15 insertions(+) diff --git a/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts index 4f523dbf7ba..2722e66f14f 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts @@ -91,6 +91,9 @@ export class ExposedPasswordsReportComponent } canManageCipher(c: CipherView): boolean { + if (c.collectionIds.length === 0) { + return true; + } return this.manageableCiphers.some((x) => x.id === c.id); } } diff --git a/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts index 5979e99c0fa..9b53d583b99 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts @@ -94,6 +94,9 @@ export class InactiveTwoFactorReportComponent } protected canManageCipher(c: CipherView): boolean { + if (c.collectionIds.length === 0) { + return true; + } return this.manageableCiphers.some((x) => x.id === c.id); } } diff --git a/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts index 1e2f5225d59..bcd573fb09d 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts @@ -89,6 +89,9 @@ export class ReusedPasswordsReportComponent } canManageCipher(c: CipherView): boolean { + if (c.collectionIds.length === 0) { + return true; + } return this.manageableCiphers.some((x) => x.id === c.id); } } diff --git a/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts index 748986fe5bb..e653a6b9a05 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts @@ -94,6 +94,9 @@ export class UnsecuredWebsitesReportComponent } protected canManageCipher(c: CipherView): boolean { + if (c.collectionIds.length === 0) { + return true; + } return this.manageableCiphers.some((x) => x.id === c.id); } } diff --git a/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts index 82abc8561fb..41018d69c22 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts @@ -93,6 +93,9 @@ export class WeakPasswordsReportComponent } canManageCipher(c: CipherView): boolean { + if (c.collectionIds.length === 0) { + return true; + } return this.manageableCiphers.some((x) => x.id === c.id); } }