From a2df6158e6235fbe796a04144e2e216ad3ac2014 Mon Sep 17 00:00:00 2001 From: John Sandoval Date: Thu, 19 Feb 2026 13:47:10 -0700 Subject: [PATCH 1/3] WIP: Email display, text, login updates --- webroot/src/app.config.ts | 6 +- webroot/src/components/App/App.ts | 14 ++- webroot/src/locales/en.json | 6 +- webroot/src/locales/es.json | 4 +- .../src/models/License/License.model.spec.ts | 5 ++ webroot/src/models/License/License.model.ts | 3 + .../models/Licensee/Licensee.model.spec.ts | 5 ++ webroot/src/models/Licensee/Licensee.model.ts | 3 + webroot/src/network/mocks/mock.data.api.ts | 1 - webroot/src/network/mocks/mock.data.ts | 90 ++++++++++--------- .../LicensingDetail/LicensingDetail.less | 8 ++ .../pages/LicensingDetail/LicensingDetail.ts | 8 ++ .../pages/LicensingDetail/LicensingDetail.vue | 8 ++ .../pages/PublicDashboard/PublicDashboard.ts | 19 +++- .../pages/PublicDashboard/PublicDashboard.vue | 20 +++-- 15 files changed, 136 insertions(+), 64 deletions(-) diff --git a/webroot/src/app.config.ts b/webroot/src/app.config.ts index 2978ce2a3..ee167fdbb 100644 --- a/webroot/src/app.config.ts +++ b/webroot/src/app.config.ts @@ -150,15 +150,16 @@ export const tokens = { export const AUTH_TYPE = 'auth_type'; export const AUTH_LOGIN_GOTO_PATH = 'login_goto'; export const AUTH_LOGIN_GOTO_PATH_AUTH_TYPE = 'login_goto_auth_type'; +export const AUTH_LOGIN_GOTO_COMPACT = 'login_goto_compact'; // ==================== // = Auto logout = // ==================== export const autoLogoutConfig = { INACTIVITY_TIMER_DEFAULT_MS: moment.duration(10, 'minutes').asMilliseconds(), - INACTIVITY_TIMER_STAFF_MS: moment.duration(10, 'minutes').asMilliseconds(), + INACTIVITY_TIMER_STAFF_MS: moment.duration(1, 'minutes').asMilliseconds(), INACTIVITY_TIMER_LICENSEE_MS: moment.duration(10, 'minutes').asMilliseconds(), - GRACE_PERIOD_MS: moment.duration(30, 'seconds').asMilliseconds(), + GRACE_PERIOD_MS: moment.duration(3, 'seconds').asMilliseconds(), LOG: (message = '') => { const isEnabled = false; // Helper logging for auto-logout testing @@ -357,6 +358,7 @@ export default { authStorage, tokens, AUTH_LOGIN_GOTO_PATH, + AUTH_LOGIN_GOTO_COMPACT, languagesEnabled, defaultLanguage, serverDateFormat, diff --git a/webroot/src/components/App/App.ts b/webroot/src/components/App/App.ts index 7a51d4a09..34f2d7a8d 100644 --- a/webroot/src/components/App/App.ts +++ b/webroot/src/components/App/App.ts @@ -17,7 +17,8 @@ import { AppModes, AuthTypes, relativeTimeFormats, - AUTH_TYPE + AUTH_TYPE, + AUTH_LOGIN_GOTO_COMPACT } from '@/app.config'; import { CompactType } from '@models/Compact/Compact.model'; import PageContainer from '@components/Page/PageContainer/PageContainer.vue'; @@ -187,19 +188,26 @@ class App extends Vue { async setCurrentCompact(): Promise { const { authType } = this.globalStore; const { currentCompact, model: user } = this.userStore; + const preLoginCompactType = authStorage.getItem(AUTH_LOGIN_GOTO_COMPACT); let userDefaultCompact; let isCompactPartOfUserPermissions; + authStorage.removeItem(AUTH_LOGIN_GOTO_COMPACT); + if (authType === AuthTypes.STAFF) { const { permissions = [] } = user || {}; + const preLoginCompact = permissions?.find((permission) => + permission.compact.type === preLoginCompactType)?.compact || null; + const firstCompactFromServer = permissions?.[0]?.compact || null; - userDefaultCompact = permissions?.[0]?.compact || null; + userDefaultCompact = preLoginCompact || firstCompactFromServer; isCompactPartOfUserPermissions = permissions.some((permission) => permission.compact.type === currentCompact?.type); } else if (authType === AuthTypes.LICENSEE) { const { licenses = [] } = user?.licensee || {}; + const firstCompactFromServer = licenses?.[0]?.compact || null; - userDefaultCompact = licenses?.[0]?.compact || null; + userDefaultCompact = firstCompactFromServer; isCompactPartOfUserPermissions = licenses.some((license) => license.compact.type === currentCompact?.type); } diff --git a/webroot/src/locales/en.json b/webroot/src/locales/en.json index e39b690fb..988fd7687 100644 --- a/webroot/src/locales/en.json +++ b/webroot/src/locales/en.json @@ -588,7 +588,9 @@ "licensingListDescription": "Click on a licensee to view the status of their privilege(s). The “Privileges” column includes both past and active privileges.", "attestation": "Attestation", "stateProvidedEmail": "State-provided email", + "stateEmail": "State email", "accountEmail": "Account email", + "registrationEmail": "Registration email", "searchTitle": "Begin a search", "searchTitlePublic": "Verify a compact privilege", "searchSubtext": "Enter at least one field to search for licensing data.", @@ -604,7 +606,7 @@ "searchPlaceholderNpi": "Enter NPI", "licenseExpirationDate": "License expiration date", "residenceLocation": "Residence location", - "generateVerification": "Generate verification doc", + "generateVerification": "Generate verification document", "generateVerificationSubtext": "Printer-friendly view", "provider": "Provider", "providers": "Providers", @@ -945,7 +947,7 @@ "practitionerName": "Practitioner name", "homeStateLicenses": "Home State Licenses", "activeDate": "Active", - "privilegeProofFooter": "This document is issued by Compact Connect as official proof of the practitioner’s current privileges to practice.
It confirms privilege-to-practice status only and is not intended to be a verification of state licensure.", + "privilegeProofFooter": "This document is issued by CompactConnect as official proof of the practitioner’s current privileges to practice.
It confirms privilege-to-practice status only and is not intended to be a verification of state licensure.", "publicProfileLink": "View public profile at", "qrCodeAlt": "QR code linking to public profile", "licenseDeactivationNote": "Deactivated due to associated license being deactivated", diff --git a/webroot/src/locales/es.json b/webroot/src/locales/es.json index 183831ff7..de125b895 100644 --- a/webroot/src/locales/es.json +++ b/webroot/src/locales/es.json @@ -573,7 +573,9 @@ "searchTitlePublic": "Verificar un privilegio compacto", "attestation": "Atestación", "stateProvidedEmail": "Correo electrónico proporcionado por el estado", + "stateEmail": "Correo electrónico estatal", "accountEmail": "Correo electrónico de la cuenta", + "registrationEmail": "Correo electrónico de registro", "searchSubtext": "Introduzca al menos un campo para buscar datos de licencia.", "searchStateDisabled": "Por favor, primero seleccione un tipo de profesión", "searchTypeTitle": "Buscar", @@ -929,7 +931,7 @@ "practitionerName": "Nombre del profesional", "homeStateLicenses": "Licencias del estado de origen", "activeDate": "Activa", - "privilegeProofFooter": "Este documento es emitido por Compact Connect como prueba oficial de los privilegios actuales del profesional para practicar.
Confirma el estado de privilegio-a-practicar solo y no está destinado a ser una verificación de la licencia estatal.", + "privilegeProofFooter": "Este documento es emitido por CompactConnect como prueba oficial de los privilegios actuales del profesional para practicar.
Confirma el estado de privilegio-a-practicar solo y no está destinado a ser una verificación de la licencia estatal.", "publicProfileLink": "Ver perfil público en", "licenseDeactivationNote": "Desactivado debido a que la licencia asociada está desactivada", "homeStateChangeNote": "Desactivado debido al cambio de estado de origen", diff --git a/webroot/src/models/License/License.model.spec.ts b/webroot/src/models/License/License.model.spec.ts index 611090012..1656a7fed 100644 --- a/webroot/src/models/License/License.model.spec.ts +++ b/webroot/src/models/License/License.model.spec.ts @@ -59,6 +59,7 @@ describe('License model', () => { expect(license.licenseNumber).to.equal(null); expect(license.privilegeId).to.equal(null); expect(license.mailingAddress).to.be.an.instanceof(Address); + expect(license.email).to.equal(null); expect(license.licenseType).to.equal(null); expect(license.history).to.matchPattern([]); expect(license.status).to.equal(LicenseStatus.INACTIVE); @@ -95,6 +96,7 @@ describe('License model', () => { licenseNumber: 'test-license-number', privilegeId: 'privilegeId', mailingAddress: new Address(), + email: 'test@example.com', npi: 'test-npi', licenseType: LicenseType.AUDIOLOGIST, history: [new LicenseHistoryItem()], @@ -118,6 +120,7 @@ describe('License model', () => { expect(license.renewalDate).to.equal(data.renewalDate); expect(license.expireDate).to.equal(data.expireDate); expect(license.mailingAddress).to.be.an.instanceof(Address); + expect(license.email).to.equal(data.email); expect(license.npi).to.equal(data.npi); expect(license.licenseNumber).to.equal(data.licenseNumber); expect(license.privilegeId).to.equal(data.privilegeId); @@ -175,6 +178,7 @@ describe('License model', () => { homeAddressCity: 'test-city', homeAddressState: 'co', homeAddressPostalCode: 'test-zip', + emailAddress: 'test@example.com', licenseType: LicenseType.AUDIOLOGIST, history: [], licenseStatus: LicenseStatus.ACTIVE, @@ -209,6 +213,7 @@ describe('License model', () => { expect(license.licenseeId).to.equal(data.providerId); expect(license.issueState).to.be.an.instanceof(State); expect(license.mailingAddress).to.be.an.instanceof(Address); + expect(license.email).to.equal(data.emailAddress); expect(license.issueState.abbrev).to.equal(data.jurisdiction); expect(license.issueDate).to.equal(data.dateOfIssuance); expect(license.renewalDate).to.equal(data.dateOfRenewal); diff --git a/webroot/src/models/License/License.model.ts b/webroot/src/models/License/License.model.ts index 318611453..2f9db1db4 100644 --- a/webroot/src/models/License/License.model.ts +++ b/webroot/src/models/License/License.model.ts @@ -54,6 +54,7 @@ export interface InterfaceLicense { renewalDate?: string | null; activeFromDate?: string | null; mailingAddress?: Address; + email?: string | null; expireDate?: string | null; npi?: string | null; licenseNumber?: string | null; @@ -82,6 +83,7 @@ export class License implements InterfaceLicense { public issueDate? = null; public activeFromDate? = null; public mailingAddress? = new Address(); + public email? = null; public renewalDate? = null; public npi? = null; public licenseNumber? = null; @@ -209,6 +211,7 @@ export class LicenseSerializer { state: json.homeAddressState, zip: json.homeAddressPostalCode, }), + email: json.emailAddress, issueState: new State({ abbrev: json.jurisdiction || json.licenseJurisdiction }), issueDate: json.dateOfIssuance, activeFromDate: json.activeSince, diff --git a/webroot/src/models/Licensee/Licensee.model.spec.ts b/webroot/src/models/Licensee/Licensee.model.spec.ts index aedc22be7..61d215088 100644 --- a/webroot/src/models/Licensee/Licensee.model.spec.ts +++ b/webroot/src/models/Licensee/Licensee.model.spec.ts @@ -51,6 +51,7 @@ describe('Licensee model', () => { expect(licensee.firstName).to.equal(null); expect(licensee.middleName).to.equal(null); expect(licensee.lastName).to.equal(null); + expect(licensee.compactConnectEmail).to.equal(null); expect(licensee.dob).to.equal(null); expect(licensee.birthMonthDay).to.equal(null); expect(licensee.licenseType).to.equal(null); @@ -110,6 +111,7 @@ describe('Licensee model', () => { address: new Address(), phoneNumber: '+13234558990', homeJurisdiction: new State({ abbrev: 'ma' }), + compactConnectEmail: 'test@example.com', dob: '2020-01-01', birthMonthDay: '01-16', ssnLastFour: '0000', @@ -165,6 +167,7 @@ describe('Licensee model', () => { expect(licensee.lastName).to.equal(data.lastName); expect(licensee.phoneNumber).to.equal(data.phoneNumber); expect(licensee.homeJurisdiction).to.be.an.instanceof(State); + expect(licensee.compactConnectEmail).to.equal(data.compactConnectEmail); expect(licensee.dob).to.equal(data.dob); expect(licensee.birthMonthDay).to.equal(data.birthMonthDay); expect(licensee.ssnLastFour).to.equal(data.ssnLastFour); @@ -311,6 +314,7 @@ describe('Licensee model', () => { dateOfBirth: moment().format(serverDateFormat), phoneNumber: '+13234558990', currentHomeJurisdiction: 'co', + compactConnectRegisteredEmailAddress: 'test@example.com', ssnLastFour: '0000', licenseType: LicenseType.AUDIOLOGIST, licenseJurisdiction: 'co', @@ -430,6 +434,7 @@ describe('Licensee model', () => { expect(licensee.firstName).to.equal(data.givenName); expect(licensee.middleName).to.equal(data.middleName); expect(licensee.lastName).to.equal(data.familyName); + expect(licensee.compactConnectEmail).to.equal(data.compactConnectRegisteredEmailAddress); expect(licensee.birthMonthDay).to.equal(data.birthMonthDay); expect(licensee.dob).to.equal(data.dateOfBirth); expect(licensee.ssnLastFour).to.equal(data.ssnLastFour); diff --git a/webroot/src/models/Licensee/Licensee.model.ts b/webroot/src/models/Licensee/Licensee.model.ts index 335ac96c1..c0b327225 100644 --- a/webroot/src/models/Licensee/Licensee.model.ts +++ b/webroot/src/models/Licensee/Licensee.model.ts @@ -44,6 +44,7 @@ export interface InterfaceLicensee { middleName?: string | null; lastName?: string | null; homeJurisdiction?: State; + compactConnectEmail?: string | null; dob?: string | null; birthMonthDay?: string | null; ssnLastFour?: string | null; @@ -74,6 +75,7 @@ export class Licensee implements InterfaceLicensee { public middleName? = null; public lastName? = null; public homeJurisdiction? = new State(); + public compactConnectEmail? = null; public dob? = null; public birthMonthDay? = null; public ssnLastFour? = null; @@ -424,6 +426,7 @@ export class LicenseeSerializer { homeJurisdiction: (json.currentHomeJurisdiction && json.currentHomeJurisdiction.trim().toLowerCase() !== 'unknown') ? new State({ abbrev: json.currentHomeJurisdiction }) : new State({ abbrev: json.licenseJurisdiction }), + compactConnectEmail: json.compactConnectRegisteredEmailAddress, dob: json.dateOfBirth, birthMonthDay: json.birthMonthDay, ssnLastFour: json.ssnLastFour, diff --git a/webroot/src/network/mocks/mock.data.api.ts b/webroot/src/network/mocks/mock.data.api.ts index edfe9432e..00cb0a3b4 100644 --- a/webroot/src/network/mocks/mock.data.api.ts +++ b/webroot/src/network/mocks/mock.data.api.ts @@ -606,7 +606,6 @@ export class DataApi { const account = JSON.parse(JSON.stringify(staffAccount)); if (mockStore?.state?.appMode === AppModes.COSMETOLOGY) { - console.log(`deleting non-cosm staff user compacts`); delete account.permissions.octp; delete account.permissions.aslp; delete account.permissions.coun; diff --git a/webroot/src/network/mocks/mock.data.ts b/webroot/src/network/mocks/mock.data.ts index c8875a2ca..cd9f2716b 100644 --- a/webroot/src/network/mocks/mock.data.ts +++ b/webroot/src/network/mocks/mock.data.ts @@ -26,7 +26,7 @@ export const staffAccount = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { al: { @@ -34,7 +34,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -42,7 +42,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -50,7 +50,7 @@ export const staffAccount = { admin: false, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ne: { @@ -58,7 +58,7 @@ export const staffAccount = { admin: false, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, oh: { @@ -66,7 +66,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, nv: { @@ -74,7 +74,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ma: { @@ -82,7 +82,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, wy: { @@ -90,7 +90,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -99,7 +99,7 @@ export const staffAccount = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { ak: { @@ -107,7 +107,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ar: { @@ -115,7 +115,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -123,7 +123,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -132,7 +132,7 @@ export const staffAccount = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { al: { @@ -140,7 +140,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -148,7 +148,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -156,7 +156,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -165,7 +165,7 @@ export const staffAccount = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { al: { @@ -173,7 +173,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -181,7 +181,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -189,7 +189,7 @@ export const staffAccount = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -479,7 +479,7 @@ export const licensees = { compact: 'octp', type: 'provider', emailAddress: 'test@example.com', - compactConnectRegisteredEmailAddress: 'test@example.com', + compactConnectRegisteredEmailAddress: 'registration@example.com', dateOfBirth: '1967-08-22', birthMonthDay: '1967-08-22', ssnLastFour: '7777', @@ -514,6 +514,7 @@ export const licensees = { givenName: 'Jeff', middleName: '', familyName: 'Cornell', + emailAddress: 'state.license@example.com', compact: 'octp', dateOfBirth: '1967-08-22', ssnLastFour: '7777', @@ -540,6 +541,7 @@ export const licensees = { givenName: 'Layne', middleName: '', familyName: 'Cornell', + emailAddress: 'state.license@example.com', compact: 'octp', dateOfBirth: '1967-08-22', ssnLastFour: '7777', @@ -1327,7 +1329,7 @@ export const users = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { al: { @@ -1335,7 +1337,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -1343,7 +1345,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -1351,7 +1353,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -1360,7 +1362,7 @@ export const users = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { ak: { @@ -1368,7 +1370,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ar: { @@ -1376,7 +1378,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -1384,7 +1386,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -1393,7 +1395,7 @@ export const users = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { al: { @@ -1401,7 +1403,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -1409,7 +1411,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -1417,7 +1419,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -1426,7 +1428,7 @@ export const users = { actions: { admin: true, readPrivate: true, - readSsn: true, + readSSN: true, }, jurisdictions: { al: { @@ -1434,7 +1436,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, co: { @@ -1442,7 +1444,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -1450,7 +1452,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -1469,7 +1471,7 @@ export const users = { actions: { admin: false, readPrivate: false, - readSsn: false, + readSSN: false, }, jurisdictions: { al: { @@ -1477,7 +1479,7 @@ export const users = { admin: false, write: false, readPrivate: false, - readSsn: false, + readSSN: false, }, }, co: { @@ -1485,7 +1487,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, ky: { @@ -1493,7 +1495,7 @@ export const users = { admin: false, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, @@ -1512,7 +1514,7 @@ export const users = { actions: { admin: false, readPrivate: false, - readSsn: false, + readSSN: false, }, jurisdictions: { ky: { @@ -1520,7 +1522,7 @@ export const users = { admin: true, write: true, readPrivate: true, - readSsn: true, + readSSN: true, }, }, }, diff --git a/webroot/src/pages/LicensingDetail/LicensingDetail.less b/webroot/src/pages/LicensingDetail/LicensingDetail.less index 9b92daf25..6f638d3ac 100644 --- a/webroot/src/pages/LicensingDetail/LicensingDetail.less +++ b/webroot/src/pages/LicensingDetail/LicensingDetail.less @@ -158,17 +158,25 @@ flex-wrap: wrap; .info-item-container { + max-width: 100%; padding: 2rem; + overflow: hidden; + + @media @tabletWidth { + max-width: 30rem; + } .info-item-title { font-weight: @fontWeightBold; font-size: 1.4rem; line-height: 2.1rem; + word-break: break-word; } .info-item { font-size: 1.4rem; line-height: 2.1rem; + word-break: break-word; } .info-item-error { diff --git a/webroot/src/pages/LicensingDetail/LicensingDetail.ts b/webroot/src/pages/LicensingDetail/LicensingDetail.ts index c486f7a40..ff8ad401d 100644 --- a/webroot/src/pages/LicensingDetail/LicensingDetail.ts +++ b/webroot/src/pages/LicensingDetail/LicensingDetail.ts @@ -191,6 +191,14 @@ export default class LicensingDetail extends Vue { return `${city}${delim}${stateAbbrev} ${zip}`.trim(); } + get registrationEmail(): string { + return this.licensee?.compactConnectEmail || ''; + } + + get stateEmail(): string { + return this.licensee?.bestLicense().email || ''; + } + get privilegesTitle(): string { return this.$t('licensing.privileges'); } diff --git a/webroot/src/pages/LicensingDetail/LicensingDetail.vue b/webroot/src/pages/LicensingDetail/LicensingDetail.vue index 75789b209..1d398a5cf 100644 --- a/webroot/src/pages/LicensingDetail/LicensingDetail.vue +++ b/webroot/src/pages/LicensingDetail/LicensingDetail.vue @@ -91,6 +91,14 @@ +
+
{{$t('licensing.registrationEmail')}}
+ +
+
+
{{$t('licensing.stateEmail')}}
+ +
{{$t('common.dateOfBirthShort')}}
{{dob}}
diff --git a/webroot/src/pages/PublicDashboard/PublicDashboard.ts b/webroot/src/pages/PublicDashboard/PublicDashboard.ts index f654f4958..40a2cdaf4 100644 --- a/webroot/src/pages/PublicDashboard/PublicDashboard.ts +++ b/webroot/src/pages/PublicDashboard/PublicDashboard.ts @@ -12,7 +12,8 @@ import { AuthTypes, getHostedLoginUri, AUTH_LOGIN_GOTO_PATH, - AUTH_LOGIN_GOTO_PATH_AUTH_TYPE + AUTH_LOGIN_GOTO_PATH_AUTH_TYPE, + AUTH_LOGIN_GOTO_COMPACT } from '@/app.config'; import Card from '@components/Card/Card.vue'; import SearchIcon from '@components/Icons/Search/Search.vue'; @@ -108,8 +109,11 @@ export default class DashboardPublic extends Vue { } } - bypassToStaffLogin(): void { + bypassToStaffLogin(compactType?: CompactType): void { if (this.isUsingMockApi) { + if (compactType) { + this.setGotoCompact(compactType); + } this.mockStaffLogin(AppModes.JCC); } else { this.$store.dispatch('startLoading'); @@ -117,8 +121,11 @@ export default class DashboardPublic extends Vue { } } - bypassToStaffLoginCosmo(): void { + bypassToStaffLoginCosmo(compactType?: CompactType): void { if (this.isUsingMockApi) { + if (compactType) { + this.setGotoCompact(compactType); + } this.mockStaffLogin(AppModes.COSMETOLOGY); } else { this.$store.dispatch('startLoading'); @@ -168,6 +175,12 @@ export default class DashboardPublic extends Vue { return compactDisplay.trim(); } + setGotoCompact(compactType: CompactType): void { + if (compactType) { + authStorage.setItem(AUTH_LOGIN_GOTO_COMPACT, compactType); + } + } + async mockStaffLogin(appMode: AppModes): Promise { const goto = authStorage.getItem(AUTH_LOGIN_GOTO_PATH); const gotoAuthType = authStorage.getItem(AUTH_LOGIN_GOTO_PATH_AUTH_TYPE); diff --git a/webroot/src/pages/PublicDashboard/PublicDashboard.vue b/webroot/src/pages/PublicDashboard/PublicDashboard.vue index b6e08bcd7..daf60fcba 100644 --- a/webroot/src/pages/PublicDashboard/PublicDashboard.vue +++ b/webroot/src/pages/PublicDashboard/PublicDashboard.vue @@ -96,14 +96,15 @@ :href="hostedLoginUriStaff" class="login-link small" rel="noopener noreferrer" + @click="setGotoCompact(compactTypes.ASLP)" > {{ getCompactDisplay(compactTypes.ASLP) }}