mirror of
https://github.com/bitwarden/browser
synced 2026-02-08 12:40:26 +00:00
Update bulk restore/revoke component to conditionally display non-compliant members callout. Adjusted logic to set statuses based on entry errors and isRevoking state. (#18654)
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
|
||||
<bit-callout
|
||||
type="danger"
|
||||
*ngIf="nonCompliantMembers"
|
||||
*ngIf="nonCompliantMembers && !isRevoking"
|
||||
title="{{ 'nonCompliantMembersTitle' | i18n }}"
|
||||
>
|
||||
{{ "nonCompliantMembersError" | i18n }}
|
||||
|
||||
@@ -88,12 +88,9 @@ export class BulkRestoreRevokeComponent {
|
||||
const bulkMessage = this.isRevoking ? "bulkRevokedMessage" : "bulkRestoredMessage";
|
||||
|
||||
response.data.forEach(async (entry) => {
|
||||
const error =
|
||||
entry.error !== ""
|
||||
? this.i18nService.t("cannotRestoreAccessError")
|
||||
: this.i18nService.t(bulkMessage);
|
||||
this.statuses.set(entry.id, error);
|
||||
if (entry.error !== "") {
|
||||
const status = entry.error !== "" ? entry.error : this.i18nService.t(bulkMessage);
|
||||
this.statuses.set(entry.id, status);
|
||||
if (entry.error !== "" && !this.isRevoking) {
|
||||
this.nonCompliantMembers = true;
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user