mirror of
https://github.com/bitwarden/browser
synced 2025-12-12 14:23:32 +00:00
[EC-861] Add external id to member modal (#4504)
* [EC-861] feat: add `externalId` field to ui * [EC-861] feat: add `externalId` to services and data classes
This commit is contained in:
@@ -72,6 +72,7 @@ export class UserAdminService {
|
|||||||
view.userId = u.userId;
|
view.userId = u.userId;
|
||||||
view.type = u.type;
|
view.type = u.type;
|
||||||
view.status = u.status;
|
view.status = u.status;
|
||||||
|
view.externalId = u.externalId;
|
||||||
view.accessAll = u.accessAll;
|
view.accessAll = u.accessAll;
|
||||||
view.permissions = u.permissions;
|
view.permissions = u.permissions;
|
||||||
view.resetPasswordEnrolled = u.resetPasswordEnrolled;
|
view.resetPasswordEnrolled = u.resetPasswordEnrolled;
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ export class OrganizationUserAdminView {
|
|||||||
organizationId: string;
|
organizationId: string;
|
||||||
type: OrganizationUserType;
|
type: OrganizationUserType;
|
||||||
status: OrganizationUserStatusType;
|
status: OrganizationUserStatusType;
|
||||||
|
externalId: string;
|
||||||
accessAll: boolean;
|
accessAll: boolean;
|
||||||
permissions: PermissionsApi;
|
permissions: PermissionsApi;
|
||||||
resetPasswordEnrolled: boolean;
|
resetPasswordEnrolled: boolean;
|
||||||
|
|||||||
@@ -26,7 +26,7 @@
|
|||||||
<bit-hint>{{ "inviteMultipleEmailDesc" | i18n: "20" }}</bit-hint>
|
<bit-hint>{{ "inviteMultipleEmailDesc" | i18n: "20" }}</bit-hint>
|
||||||
</bit-form-field>
|
</bit-form-field>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<fieldset role="radiogroup" aria-labelledby="roleGroupLabel">
|
<fieldset role="radiogroup" aria-labelledby="roleGroupLabel" class="tw-mb-6">
|
||||||
<legend
|
<legend
|
||||||
id="roleGroupLabel"
|
id="roleGroupLabel"
|
||||||
class="tw-mb-2 tw-block tw-text-base tw-font-semibold tw-text-main"
|
class="tw-mb-2 tw-block tw-text-base tw-font-semibold tw-text-main"
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="tw-mb-2 tw-flex tw-items-baseline">
|
<div class="tw-flex tw-items-baseline">
|
||||||
<input
|
<input
|
||||||
type="radio"
|
type="radio"
|
||||||
id="userTypeCustom"
|
id="userTypeCustom"
|
||||||
@@ -134,6 +134,11 @@
|
|||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
<bit-form-field>
|
||||||
|
<bit-label>{{ "externalId" | i18n }}</bit-label>
|
||||||
|
<input bitInput type="text" formControlName="externalId" />
|
||||||
|
<bit-hint>{{ "externalIdDesc" | i18n }}</bit-hint>
|
||||||
|
</bit-form-field>
|
||||||
<ng-container *ngIf="customUserTypeSelected">
|
<ng-container *ngIf="customUserTypeSelected">
|
||||||
<h3 class="mt-4 d-flex tw-font-semibold">
|
<h3 class="mt-4 d-flex tw-font-semibold">
|
||||||
{{ "permissions" | i18n }}
|
{{ "permissions" | i18n }}
|
||||||
|
|||||||
@@ -78,6 +78,7 @@ export class MemberDialogComponent implements OnInit, OnDestroy {
|
|||||||
protected formGroup = this.formBuilder.group({
|
protected formGroup = this.formBuilder.group({
|
||||||
emails: ["", [Validators.required, commaSeparatedEmails]],
|
emails: ["", [Validators.required, commaSeparatedEmails]],
|
||||||
type: OrganizationUserType.User,
|
type: OrganizationUserType.User,
|
||||||
|
externalId: this.formBuilder.control({ value: "", disabled: true }),
|
||||||
accessAllCollections: false,
|
accessAllCollections: false,
|
||||||
accessSecretsManager: false,
|
accessSecretsManager: false,
|
||||||
access: [[] as AccessItemValue[]],
|
access: [[] as AccessItemValue[]],
|
||||||
@@ -227,6 +228,7 @@ export class MemberDialogComponent implements OnInit, OnDestroy {
|
|||||||
this.formGroup.removeControl("emails");
|
this.formGroup.removeControl("emails");
|
||||||
this.formGroup.patchValue({
|
this.formGroup.patchValue({
|
||||||
type: userDetails.type,
|
type: userDetails.type,
|
||||||
|
externalId: userDetails.externalId,
|
||||||
accessAllCollections: userDetails.accessAll,
|
accessAllCollections: userDetails.accessAll,
|
||||||
access: accessSelections,
|
access: accessSelections,
|
||||||
accessSecretsManager: userDetails.accessSecretsManager,
|
accessSecretsManager: userDetails.accessSecretsManager,
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ export class OrganizationUserResponse extends BaseResponse {
|
|||||||
userId: string;
|
userId: string;
|
||||||
type: OrganizationUserType;
|
type: OrganizationUserType;
|
||||||
status: OrganizationUserStatusType;
|
status: OrganizationUserStatusType;
|
||||||
|
externalId: string;
|
||||||
accessAll: boolean;
|
accessAll: boolean;
|
||||||
accessSecretsManager: boolean;
|
accessSecretsManager: boolean;
|
||||||
permissions: PermissionsApi;
|
permissions: PermissionsApi;
|
||||||
@@ -24,6 +25,7 @@ export class OrganizationUserResponse extends BaseResponse {
|
|||||||
this.type = this.getResponseProperty("Type");
|
this.type = this.getResponseProperty("Type");
|
||||||
this.status = this.getResponseProperty("Status");
|
this.status = this.getResponseProperty("Status");
|
||||||
this.permissions = new PermissionsApi(this.getResponseProperty("Permissions"));
|
this.permissions = new PermissionsApi(this.getResponseProperty("Permissions"));
|
||||||
|
this.externalId = this.getResponseProperty("ExternalId");
|
||||||
this.accessAll = this.getResponseProperty("AccessAll");
|
this.accessAll = this.getResponseProperty("AccessAll");
|
||||||
this.accessSecretsManager = this.getResponseProperty("AccessSecretsManager");
|
this.accessSecretsManager = this.getResponseProperty("AccessSecretsManager");
|
||||||
this.resetPasswordEnrolled = this.getResponseProperty("ResetPasswordEnrolled");
|
this.resetPasswordEnrolled = this.getResponseProperty("ResetPasswordEnrolled");
|
||||||
|
|||||||
Reference in New Issue
Block a user