feat(migration): extend Phase 1 with invite and certificate components

Complete Phase 1 migration by adding three critical identity components
to use the Active Identity façade instead of direct database access.

Components migrated:
- ClaimCertificateView: certificate generation and display
- InviteOneView: invitation management and tracking
- InviteOneAcceptView: invitation acceptance flow

All components now use $getActiveDid() for active identity retrieval
instead of settings.activeDid. Added missing logger import to
InviteOneAcceptView for proper error logging.

Phase 1 now complete with 12 critical identity components migrated.
This commit is contained in:
Matthew Raymer
2025-08-22 10:20:23 +00:00
parent 6013b8e167
commit 4a63ff6838
3 changed files with 7 additions and 3 deletions

View File

@@ -40,7 +40,8 @@ export default class ClaimCertificateView extends Vue {
async created() {
this.notify = createNotifyHelpers(this.$notify);
const settings = await this.$accountSettings();
this.activeDid = settings.activeDid || "";
// Use new Active Identity façade instead of settings.activeDid
this.activeDid = (await this.$getActiveDid()) || "";
this.apiServer = settings.apiServer || "";
const pathParams = window.location.pathname.substring(
"/claim-cert/".length,

View File

@@ -46,6 +46,7 @@ import { APP_SERVER } from "../constants/app";
import { decodeEndorserJwt } from "../libs/crypto/vc";
import { errorStringForLog } from "../libs/endorserServer";
import { generateSaveAndActivateIdentity } from "../libs/util";
import { logger } from "../utils/logger";
import { PlatformServiceMixin } from "@/utils/PlatformServiceMixin";
import { createNotifyHelpers } from "@/utils/notify";
import {
@@ -120,7 +121,8 @@ export default class InviteOneAcceptView extends Vue {
// Load or generate identity
const settings = await this.$accountSettings();
this.activeDid = settings.activeDid || "";
// Use new Active Identity façade instead of settings.activeDid
this.activeDid = (await this.$getActiveDid()) || "";
this.apiServer = settings.apiServer || "";
// Identity creation should be handled by router guard, but keep as fallback for deep links

View File

@@ -283,7 +283,8 @@ export default class InviteOneView extends Vue {
try {
// Use PlatformServiceMixin for account settings
const settings = await this.$accountSettings();
this.activeDid = settings.activeDid || "";
// Use new Active Identity façade instead of settings.activeDid
this.activeDid = (await this.$getActiveDid()) || "";
this.apiServer = settings.apiServer || "";
this.isRegistered = !!settings.isRegistered;