1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-14 07:13:32 +00:00

[PM-5011][PM-7284] migrate user subscription along with update license dialog (#8659)

* migrate user subscription along with update license dialog

* migrate user subscription along with update license dialog
This commit is contained in:
vinith-kovan
2024-05-28 21:23:54 +05:30
committed by GitHub
parent 49b59840a8
commit 1b5faae7c3
5 changed files with 118 additions and 74 deletions

View File

@@ -0,0 +1,38 @@
import { Component } from "@angular/core";
import { FormBuilder } from "@angular/forms";
import { ApiService } from "@bitwarden/common/abstractions/api.service";
import { OrganizationApiServiceAbstraction } from "@bitwarden/common/admin-console/abstractions/organization/organization-api.service.abstraction";
import { I18nService } from "@bitwarden/common/platform/abstractions/i18n.service";
import { PlatformUtilsService } from "@bitwarden/common/platform/abstractions/platform-utils.service";
import { DialogService } from "@bitwarden/components";
import { UpdateLicenseComponent } from "./update-license.component";
export enum UpdateLicenseDialogResult {
Updated = "updated",
Cancelled = "cancelled",
}
@Component({
templateUrl: "update-license-dialog.component.html",
})
export class UpdateLicenseDialogComponent extends UpdateLicenseComponent {
constructor(
apiService: ApiService,
i18nService: I18nService,
platformUtilsService: PlatformUtilsService,
organizationApiService: OrganizationApiServiceAbstraction,
formBuilder: FormBuilder,
) {
super(apiService, i18nService, platformUtilsService, organizationApiService, formBuilder);
}
async submitLicense() {
await this.submit();
}
submitLicenseDialog = async () => {
await this.submitLicense();
};
static open(dialogService: DialogService) {
return dialogService.open<UpdateLicenseDialogResult>(UpdateLicenseDialogComponent);
}
}