@sphereon/ssi-sdk.data-store 0.30.2-feature.SPRIND.84.145 → 0.30.2-feature.SPRIND.84.182
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities/digitalCredential/DigitalCredentialEntity.d.ts.map +1 -1
- package/dist/entities/digitalCredential/DigitalCredentialEntity.js +1 -1
- package/dist/entities/digitalCredential/DigitalCredentialEntity.js.map +1 -1
- package/dist/entities/eventLogger/AuditEventEntity.d.ts +1 -4
- package/dist/entities/eventLogger/AuditEventEntity.d.ts.map +1 -1
- package/dist/entities/eventLogger/AuditEventEntity.js +2 -55
- package/dist/entities/eventLogger/AuditEventEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.js +1 -8
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.js +1 -9
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.js +1 -16
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/ImageAttributesEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/ImageAttributesEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/ImageAttributesEntity.js +1 -11
- package/dist/entities/issuanceBranding/ImageAttributesEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.js +1 -8
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.js +1 -8
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.d.ts +4 -2
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.js +21 -15
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.js.map +1 -1
- package/dist/entities/issuanceBranding/TextAttributesEntity.d.ts +0 -2
- package/dist/entities/issuanceBranding/TextAttributesEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/TextAttributesEntity.js +1 -7
- package/dist/entities/issuanceBranding/TextAttributesEntity.js.map +1 -1
- package/dist/eventLogger/EventLoggerStore.d.ts.map +1 -1
- package/dist/eventLogger/EventLoggerStore.js +2 -2
- package/dist/eventLogger/EventLoggerStore.js.map +1 -1
- package/dist/index.d.ts +14 -13
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -18
- package/dist/index.js.map +1 -1
- package/dist/issuanceBranding/IssuanceBrandingStore.d.ts +1 -1
- package/dist/issuanceBranding/IssuanceBrandingStore.d.ts.map +1 -1
- package/dist/issuanceBranding/IssuanceBrandingStore.js +5 -5
- package/dist/issuanceBranding/IssuanceBrandingStore.js.map +1 -1
- package/dist/migrations/postgres/1685628974232-CreateIssuanceBranding.js +1 -1
- package/dist/migrations/postgres/1685628974232-CreateIssuanceBranding.js.map +1 -1
- package/dist/migrations/postgres/1708525189001-CreateDigitalCredential.js +1 -1
- package/dist/migrations/postgres/1708525189001-CreateDigitalCredential.js.map +1 -1
- package/dist/migrations/sqlite/1685628973231-CreateIssuanceBranding.js +3 -3
- package/dist/migrations/sqlite/1685628973231-CreateIssuanceBranding.js.map +1 -1
- package/dist/migrations/sqlite/1708525189002-CreateDigitalCredential.js +1 -1
- package/dist/types/contact/contact.d.ts +3 -3
- package/dist/types/contact/contact.d.ts.map +1 -1
- package/dist/types/digitalCredential/digitalCredential.d.ts +2 -1
- package/dist/types/digitalCredential/digitalCredential.d.ts.map +1 -1
- package/dist/types/digitalCredential/digitalCredential.js +1 -0
- package/dist/types/digitalCredential/digitalCredential.js.map +1 -1
- package/dist/types/issuanceBranding/issuanceBranding.d.ts +7 -2
- package/dist/types/issuanceBranding/issuanceBranding.d.ts.map +1 -1
- package/dist/utils/eventLogger/MappingUtils.d.ts +4 -1
- package/dist/utils/eventLogger/MappingUtils.d.ts.map +1 -1
- package/dist/utils/eventLogger/MappingUtils.js +55 -1
- package/dist/utils/eventLogger/MappingUtils.js.map +1 -1
- package/dist/utils/issuanceBranding/MappingUtils.d.ts +15 -1
- package/dist/utils/issuanceBranding/MappingUtils.d.ts.map +1 -1
- package/dist/utils/issuanceBranding/MappingUtils.js +81 -1
- package/dist/utils/issuanceBranding/MappingUtils.js.map +1 -1
- package/package.json +5 -5
- package/src/__tests__/contact.store.test.ts +59 -4
- package/src/__tests__/digitalCredential.entities.test.ts +5 -5
- package/src/__tests__/digitalCredential.store.test.ts +1 -1
- package/src/__tests__/eventLogger.entities.test.ts +24 -24
- package/src/__tests__/issuanceBranding.entities.test.ts +8 -0
- package/src/entities/digitalCredential/DigitalCredentialEntity.ts +1 -1
- package/src/entities/eventLogger/AuditEventEntity.ts +1 -57
- package/src/entities/issuanceBranding/BackgroundAttributesEntity.ts +2 -11
- package/src/entities/issuanceBranding/CredentialBrandingEntity.ts +1 -13
- package/src/entities/issuanceBranding/CredentialLocaleBrandingEntity.ts +0 -17
- package/src/entities/issuanceBranding/ImageAttributesEntity.ts +2 -14
- package/src/entities/issuanceBranding/ImageDimensionsEntity.ts +0 -9
- package/src/entities/issuanceBranding/IssuerBrandingEntity.ts +1 -12
- package/src/entities/issuanceBranding/IssuerLocaleBrandingEntity.ts +17 -17
- package/src/entities/issuanceBranding/TextAttributesEntity.ts +1 -9
- package/src/eventLogger/EventLoggerStore.ts +5 -4
- package/src/index.ts +13 -26
- package/src/issuanceBranding/IssuanceBrandingStore.ts +14 -6
- package/src/migrations/postgres/1685628974232-CreateIssuanceBranding.ts +1 -1
- package/src/migrations/postgres/1708525189001-CreateDigitalCredential.ts +1 -1
- package/src/migrations/sqlite/1685628973231-CreateIssuanceBranding.ts +3 -3
- package/src/migrations/sqlite/1708525189002-CreateDigitalCredential.ts +1 -1
- package/src/types/contact/contact.ts +3 -3
- package/src/types/digitalCredential/digitalCredential.ts +1 -0
- package/src/types/issuanceBranding/issuanceBranding.ts +9 -3
- package/src/utils/eventLogger/MappingUtils.ts +57 -2
- package/src/utils/issuanceBranding/MappingUtils.ts +105 -2
|
@@ -4,12 +4,9 @@ import { ActionType, InitiatorType, LoggingEventType, LogLevel, SubSystem, Syste
|
|
|
4
4
|
import { DataSource } from 'typeorm'
|
|
5
5
|
import { DataStoreEventLoggerEntities } from '../index'
|
|
6
6
|
import { DataStoreEventLoggerMigrations } from '../migrations'
|
|
7
|
-
import {
|
|
8
|
-
activityEventEntityFrom,
|
|
9
|
-
auditEventEntityFrom,
|
|
10
|
-
AuditEventEntity
|
|
11
|
-
} from '../entities/eventLogger/AuditEventEntity'
|
|
7
|
+
import { AuditEventEntity } from '../entities/eventLogger/AuditEventEntity'
|
|
12
8
|
import { NonPersistedAuditLoggingEvent, NonPersistedActivityLoggingEvent } from '../types'
|
|
9
|
+
import { activityEventEntityFrom, auditEventEntityFrom } from '../utils/eventLogger/MappingUtils'
|
|
13
10
|
|
|
14
11
|
describe('Database entities tests', (): void => {
|
|
15
12
|
let dbConnection: DataSource
|
|
@@ -80,7 +77,7 @@ describe('Database entities tests', (): void => {
|
|
|
80
77
|
})
|
|
81
78
|
|
|
82
79
|
it('should save activity event to database', async (): Promise<void> => {
|
|
83
|
-
const
|
|
80
|
+
const activityEvent: NonPersistedActivityLoggingEvent = {
|
|
84
81
|
timestamp: new Date(),
|
|
85
82
|
level: LogLevel.DEBUG,
|
|
86
83
|
originalCredential: 'test_credential_string',
|
|
@@ -104,28 +101,31 @@ describe('Database entities tests', (): void => {
|
|
|
104
101
|
diagnosticData: { data: 'test_data_string' },
|
|
105
102
|
}
|
|
106
103
|
|
|
107
|
-
const activityEventEntity: AuditEventEntity = activityEventEntityFrom(
|
|
104
|
+
const activityEventEntity: AuditEventEntity = activityEventEntityFrom(activityEvent)
|
|
108
105
|
const fromDb: AuditEventEntity = await dbConnection.getRepository(AuditEventEntity).save(activityEventEntity)
|
|
109
106
|
|
|
110
107
|
expect(fromDb).toBeDefined()
|
|
111
108
|
expect(fromDb?.id).not.toBeNull()
|
|
112
109
|
expect(fromDb?.type).toEqual(LoggingEventType.ACTIVITY)
|
|
113
|
-
expect(fromDb?.timestamp).toEqual(
|
|
114
|
-
expect(fromDb?.level).toEqual(
|
|
115
|
-
expect(fromDb?.correlationId).toEqual(
|
|
116
|
-
expect(fromDb?.system).toEqual(
|
|
117
|
-
expect(fromDb?.subSystemType).toEqual(
|
|
118
|
-
expect(fromDb?.actionType).toEqual(
|
|
119
|
-
expect(fromDb?.actionSubType).toEqual(
|
|
120
|
-
expect(fromDb?.initiatorType).toEqual(
|
|
121
|
-
expect(fromDb?.systemCorrelationIdType).toEqual(
|
|
122
|
-
expect(fromDb?.systemCorrelationId).toEqual(
|
|
123
|
-
expect(fromDb?.systemAlias).toEqual(
|
|
124
|
-
expect(fromDb?.partyCorrelationType).toEqual(
|
|
125
|
-
expect(fromDb?.partyCorrelationId).toEqual(
|
|
126
|
-
expect(fromDb?.partyAlias).toEqual(
|
|
127
|
-
expect(fromDb?.description).toEqual(
|
|
128
|
-
expect(fromDb?.data).toEqual(JSON.stringify(
|
|
129
|
-
expect(fromDb?.diagnosticData).toEqual(JSON.stringify(
|
|
110
|
+
expect(fromDb?.timestamp).toEqual(activityEvent.timestamp)
|
|
111
|
+
expect(fromDb?.level).toEqual(activityEvent.level)
|
|
112
|
+
expect(fromDb?.correlationId).toEqual(activityEvent.correlationId)
|
|
113
|
+
expect(fromDb?.system).toEqual(activityEvent.system)
|
|
114
|
+
expect(fromDb?.subSystemType).toEqual(activityEvent.subSystemType)
|
|
115
|
+
expect(fromDb?.actionType).toEqual(activityEvent.actionType)
|
|
116
|
+
expect(fromDb?.actionSubType).toEqual(activityEvent.actionSubType)
|
|
117
|
+
expect(fromDb?.initiatorType).toEqual(activityEvent.initiatorType)
|
|
118
|
+
expect(fromDb?.systemCorrelationIdType).toEqual(activityEvent.systemCorrelationIdType)
|
|
119
|
+
expect(fromDb?.systemCorrelationId).toEqual(activityEvent.systemCorrelationId)
|
|
120
|
+
expect(fromDb?.systemAlias).toEqual(activityEvent.systemAlias)
|
|
121
|
+
expect(fromDb?.partyCorrelationType).toEqual(activityEvent.partyCorrelationType)
|
|
122
|
+
expect(fromDb?.partyCorrelationId).toEqual(activityEvent.partyCorrelationId)
|
|
123
|
+
expect(fromDb?.partyAlias).toEqual(activityEvent.partyAlias)
|
|
124
|
+
expect(fromDb?.description).toEqual(activityEvent.description)
|
|
125
|
+
expect(fromDb?.data).toEqual(JSON.stringify(activityEvent.data))
|
|
126
|
+
expect(fromDb?.diagnosticData).toEqual(JSON.stringify(activityEvent.diagnosticData))
|
|
127
|
+
expect(fromDb?.credentialHash).toEqual(activityEvent.credentialHash)
|
|
128
|
+
expect(fromDb?.parentCredentialHash).toEqual(activityEvent.parentCredentialHash)
|
|
129
|
+
expect(fromDb?.credentialType).toEqual(activityEvent.credentialType)
|
|
130
130
|
})
|
|
131
131
|
})
|
|
@@ -468,6 +468,10 @@ describe('Database entities tests', (): void => {
|
|
|
468
468
|
localeBranding: [
|
|
469
469
|
{
|
|
470
470
|
alias: 'issuerAlias',
|
|
471
|
+
clientUri: 'test_uri',
|
|
472
|
+
tosUri: 'test_uri',
|
|
473
|
+
policyUri: 'test_uri',
|
|
474
|
+
contacts: ['test_email_address1', 'test_email_address2'],
|
|
471
475
|
locale: 'en-US',
|
|
472
476
|
logo: {
|
|
473
477
|
uri: 'data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/4huQSUNDX1BST0ZJTEUAAQEAABuAYXBwbAIQAABtbnRyUkdCIFhZWiAH4wADAA4ACwAKAAJhY3NwQVBQTAAAAABBUFBMAAAAAAAAAAAAAAAAAAAAAAAA9tYAAQAAAADTLWFwcGwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABFkZXNjAAABUAAAAGJkc2NtAAABtAAABIRjcHJ0AAAGOAAAACN3dHB0AAAGXAAAABRyWFlaAAAGcAAAABRnWFlaAAAGhAAAABRiWFlaAAAGmAAAABRyVFJDAAAGrAAACAxhYXJnAAAOuAAAACB2Y2d0AAAO2AAABhJuZGluAAAU7AAABj5jaGFkAAAbLAAAACxtbW9kAAAbWAAAAChiVFJDAAAGrAAACAxnVFJDAAAGrAAACAxhYWJnAAAOuAAAACBhYWdnAAAOuAAAACBkZXNjAAAAAAAAAAhEaXNwbGF5AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAbWx1YwAAAAAAAAAmAAAADGhySFIAAAAUAAAB2GtvS1IAAAAMAAAB7G5iTk8AAAASAAAB+GlkAAAAAAASAAACCmh1SFUAAAAUAAACHGNzQ1oAAAAWAAACMGRhREsAAAAcAAACRm5sTkwAAAAWAAACYmZpRkkAAAAQAAACeGl0SVQAAAAUAAACiGVzRVMAAAASAAACnHJvUk8AAAASAAACnGZyQ0EAAAAWAAACrmFyAAAAAAAUAAACxHVrVUEAAAAcAAAC2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sdxA11tInRKT3MoRkS5RzwAPBgsfilvgRNG8zNLHNA8k1kegn4THIwNi5Hl8WQudmksjLDuxGnyqvOPhtMyipwowyG4CUGSD87RC40OK5a/oiXnol1GeBPwmOUgbE5qYNPQFw+sjT/xPiEwg6LI3mp+b8tSD8ofPEn4THIQNhKp1MG6KaGNTsXpdsyZOtAdhZuJvRh8Gw7J/nBFZjpmqrREgriEBR0kl80vpQA0GrsJxJ+ExyEDYX4dSlKC6+rq6LaAgohEhGlC5Lh3WfkKvp4if+9IJ6XFskEt4p2zgBKvQCreQPNGfS2RqdzxJ+Ex7tr5qXJiWBiYKDcImAEAHQDiqe9SOzE91J3ropD92YT9FIRL276ur/nIwlhq4geNkAJd4Xf0E/CY5mT8Jj3ZQs2ySyw1lrRN2kSEyewsWLFixYsL6jBpNJpovriT8Jj3oEmjUQYKgwVBgqDBUGCoMFQYKAOJPwmOZgbBPwmPdxVBwySYNYfqpCC/oQCXYPaQQQQQQQQQhCnMhIkmy0rkYWYsSaSa5/qX/9k=',
|
|
@@ -507,6 +511,10 @@ describe('Database entities tests', (): void => {
|
|
|
507
511
|
expect(fromDb?.localeBranding).toBeDefined()
|
|
508
512
|
expect(fromDb?.localeBranding.length).toEqual(1)
|
|
509
513
|
expect(fromDb?.localeBranding[0].alias).toEqual(issuerBranding.localeBranding[0].alias)
|
|
514
|
+
expect(fromDb?.localeBranding[0].clientUri).toEqual(issuerBranding.localeBranding[0].clientUri)
|
|
515
|
+
expect(fromDb?.localeBranding[0].tosUri).toEqual(issuerBranding.localeBranding[0].tosUri)
|
|
516
|
+
expect(fromDb?.localeBranding[0].policyUri).toEqual(issuerBranding.localeBranding[0].policyUri)
|
|
517
|
+
expect(fromDb?.localeBranding[0].contacts).toEqual(issuerBranding.localeBranding[0].contacts)
|
|
510
518
|
expect(fromDb?.localeBranding[0].locale).toEqual(issuerBranding.localeBranding[0].locale)
|
|
511
519
|
expect(fromDb?.localeBranding[0].description).toEqual(issuerBranding.localeBranding[0].description)
|
|
512
520
|
expect(fromDb?.localeBranding[0].logo).toBeDefined()
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { typeormDate, typeOrmDateTime } from '@sphereon/ssi-sdk.agent-config'
|
|
1
2
|
import { BaseEntity, Column, CreateDateColumn, Entity, PrimaryGeneratedColumn, UpdateDateColumn } from 'typeorm'
|
|
2
3
|
import {
|
|
3
4
|
CredentialCorrelationType,
|
|
@@ -8,7 +9,6 @@ import {
|
|
|
8
9
|
DocumentType,
|
|
9
10
|
RegulationType,
|
|
10
11
|
} from '../../types'
|
|
11
|
-
import { typeormDate, typeOrmDateTime } from '@sphereon/ssi-sdk.agent-config'
|
|
12
12
|
|
|
13
13
|
@Entity('DigitalCredential')
|
|
14
14
|
export class DigitalCredentialEntity extends BaseEntity implements DigitalCredential {
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { ActionSubType, ActionType, InitiatorType, LoggingEventType, LogLevel, SubSystem, System, SystemCorrelationIdType } from '@sphereon/ssi-types'
|
|
2
|
-
import { BaseEntity, Column, CreateDateColumn, Entity, PrimaryGeneratedColumn, UpdateDateColumn } from 'typeorm'
|
|
3
2
|
import { CredentialType, PartyCorrelationType } from '@sphereon/ssi-sdk.core'
|
|
4
3
|
import { typeOrmDateTime } from '@sphereon/ssi-sdk.agent-config'
|
|
5
|
-
import {
|
|
4
|
+
import { BaseEntity, Column, CreateDateColumn, Entity, PrimaryGeneratedColumn, UpdateDateColumn } from 'typeorm'
|
|
6
5
|
|
|
7
6
|
//TODO this entity, also contains some optional fields that are related to another event type (Activity) later we might want to refactor and reorganize this.
|
|
8
7
|
// For now I've added a discriminator value called eventType that can be one of the three types of events: 1. General, 2. Audit, and 3. Activity
|
|
@@ -86,58 +85,3 @@ export class AuditEventEntity extends BaseEntity {
|
|
|
86
85
|
@UpdateDateColumn({ name: 'last_updated_at', nullable: false, type: typeOrmDateTime() })
|
|
87
86
|
lastUpdatedAt!: Date
|
|
88
87
|
}
|
|
89
|
-
|
|
90
|
-
export const auditEventEntityFrom = (args: NonPersistedAuditLoggingEvent): AuditEventEntity => {
|
|
91
|
-
const auditEventEntity: AuditEventEntity = new AuditEventEntity()
|
|
92
|
-
auditEventEntity.type = LoggingEventType.AUDIT
|
|
93
|
-
auditEventEntity.timestamp = args.timestamp
|
|
94
|
-
auditEventEntity.level = args.level
|
|
95
|
-
auditEventEntity.correlationId = args.correlationId
|
|
96
|
-
auditEventEntity.system = args.system
|
|
97
|
-
auditEventEntity.subSystemType = args.subSystemType
|
|
98
|
-
auditEventEntity.actionType = args.actionType
|
|
99
|
-
auditEventEntity.actionSubType = args.actionSubType
|
|
100
|
-
auditEventEntity.initiatorType = args.initiatorType
|
|
101
|
-
auditEventEntity.systemCorrelationIdType = args.systemCorrelationIdType
|
|
102
|
-
auditEventEntity.systemCorrelationId = args.systemCorrelationId
|
|
103
|
-
auditEventEntity.systemAlias = args.systemAlias
|
|
104
|
-
auditEventEntity.partyCorrelationType = args.partyCorrelationType
|
|
105
|
-
auditEventEntity.partyCorrelationId = args.partyCorrelationId
|
|
106
|
-
auditEventEntity.partyAlias = args.partyAlias
|
|
107
|
-
auditEventEntity.description = args.description
|
|
108
|
-
auditEventEntity.partyCorrelationType = args.partyCorrelationType
|
|
109
|
-
auditEventEntity.data = JSON.stringify(args.data)
|
|
110
|
-
auditEventEntity.diagnosticData = JSON.stringify(args.diagnosticData)
|
|
111
|
-
|
|
112
|
-
return auditEventEntity
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
export const activityEventEntityFrom = (args: NonPersistedActivityLoggingEvent): AuditEventEntity => {
|
|
116
|
-
const activityEventEntity: AuditEventEntity = new AuditEventEntity()
|
|
117
|
-
activityEventEntity.type = LoggingEventType.ACTIVITY
|
|
118
|
-
activityEventEntity.timestamp = args.timestamp
|
|
119
|
-
activityEventEntity.level = args.level
|
|
120
|
-
activityEventEntity.correlationId = args.correlationId
|
|
121
|
-
activityEventEntity.system = args.system
|
|
122
|
-
activityEventEntity.subSystemType = args.subSystemType
|
|
123
|
-
activityEventEntity.actionType = args.actionType
|
|
124
|
-
activityEventEntity.actionSubType = args.actionSubType
|
|
125
|
-
activityEventEntity.initiatorType = args.initiatorType
|
|
126
|
-
activityEventEntity.systemCorrelationIdType = args.systemCorrelationIdType
|
|
127
|
-
activityEventEntity.systemCorrelationId = args.systemCorrelationId
|
|
128
|
-
activityEventEntity.systemAlias = args.systemAlias
|
|
129
|
-
activityEventEntity.partyCorrelationType = args.partyCorrelationType
|
|
130
|
-
activityEventEntity.partyCorrelationId = args.partyCorrelationId
|
|
131
|
-
activityEventEntity.partyAlias = args.partyAlias
|
|
132
|
-
activityEventEntity.description = args.description
|
|
133
|
-
activityEventEntity.partyCorrelationType = args.partyCorrelationType
|
|
134
|
-
activityEventEntity.data = JSON.stringify(args.data)
|
|
135
|
-
activityEventEntity.sharePurpose = args.sharePurpose
|
|
136
|
-
activityEventEntity.credentialType = args.credentialType
|
|
137
|
-
activityEventEntity.originalCredential = args.originalCredential
|
|
138
|
-
activityEventEntity.credentialHash = args.credentialHash
|
|
139
|
-
activityEventEntity.parentCredentialHash = args.parentCredentialHash
|
|
140
|
-
activityEventEntity.diagnosticData = JSON.stringify(args.diagnosticData)
|
|
141
|
-
|
|
142
|
-
return activityEventEntity
|
|
143
|
-
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { BaseEntity, BeforeInsert, BeforeUpdate, Column, Entity, JoinColumn, OneToOne, PrimaryGeneratedColumn } from 'typeorm'
|
|
2
|
-
import {
|
|
3
|
-
import { ImageAttributesEntity, imageAttributesEntityFrom } from './ImageAttributesEntity'
|
|
2
|
+
import { ImageAttributesEntity } from './ImageAttributesEntity'
|
|
4
3
|
import { validate, Validate, ValidationError } from 'class-validator'
|
|
5
|
-
import {
|
|
4
|
+
import { IsNonEmptyStringConstraint } from '../validators'
|
|
6
5
|
|
|
7
6
|
@Entity('BackgroundAttributes')
|
|
8
7
|
export class BackgroundAttributesEntity extends BaseEntity {
|
|
@@ -32,11 +31,3 @@ export class BackgroundAttributesEntity extends BaseEntity {
|
|
|
32
31
|
return
|
|
33
32
|
}
|
|
34
33
|
}
|
|
35
|
-
|
|
36
|
-
export const backgroundAttributesEntityFrom = (args: IBasicBackgroundAttributes): BackgroundAttributesEntity => {
|
|
37
|
-
const backgroundAttributesEntity: BackgroundAttributesEntity = new BackgroundAttributesEntity()
|
|
38
|
-
backgroundAttributesEntity.color = isEmptyString(args.color) ? undefined : args.color
|
|
39
|
-
backgroundAttributesEntity.image = args.image ? imageAttributesEntityFrom(args.image) : undefined
|
|
40
|
-
|
|
41
|
-
return backgroundAttributesEntity
|
|
42
|
-
}
|
|
@@ -12,8 +12,7 @@ import {
|
|
|
12
12
|
} from 'typeorm'
|
|
13
13
|
import { ArrayMinSize, IsNotEmpty, validate, ValidationError } from 'class-validator'
|
|
14
14
|
import { typeOrmDateTime } from '@sphereon/ssi-sdk.agent-config'
|
|
15
|
-
import { CredentialLocaleBrandingEntity
|
|
16
|
-
import { IBasicCredentialBranding, IBasicCredentialLocaleBranding } from '../../types'
|
|
15
|
+
import { CredentialLocaleBrandingEntity } from './CredentialLocaleBrandingEntity'
|
|
17
16
|
|
|
18
17
|
@Entity('CredentialBranding')
|
|
19
18
|
@Index('IDX_CredentialBrandingEntity_vcHash', ['vcHash'])
|
|
@@ -66,14 +65,3 @@ export class CredentialBrandingEntity extends BaseEntity {
|
|
|
66
65
|
return
|
|
67
66
|
}
|
|
68
67
|
}
|
|
69
|
-
|
|
70
|
-
export const credentialBrandingEntityFrom = (args: IBasicCredentialBranding): CredentialBrandingEntity => {
|
|
71
|
-
const credentialBrandingEntity: CredentialBrandingEntity = new CredentialBrandingEntity()
|
|
72
|
-
credentialBrandingEntity.issuerCorrelationId = args.issuerCorrelationId
|
|
73
|
-
credentialBrandingEntity.vcHash = args.vcHash
|
|
74
|
-
credentialBrandingEntity.localeBranding = args.localeBranding.map((localeBranding: IBasicCredentialLocaleBranding) =>
|
|
75
|
-
credentialLocaleBrandingEntityFrom(localeBranding),
|
|
76
|
-
)
|
|
77
|
-
|
|
78
|
-
return credentialBrandingEntity
|
|
79
|
-
}
|
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
import { ChildEntity, Column, JoinColumn, ManyToOne, Index } from 'typeorm'
|
|
2
|
-
import { IBasicCredentialLocaleBranding } from '../../types'
|
|
3
|
-
import { backgroundAttributesEntityFrom } from './BackgroundAttributesEntity'
|
|
4
2
|
import { CredentialBrandingEntity } from './CredentialBrandingEntity'
|
|
5
|
-
import { imageAttributesEntityFrom } from './ImageAttributesEntity'
|
|
6
3
|
import { BaseLocaleBrandingEntity } from './BaseLocaleBrandingEntity'
|
|
7
|
-
import { textAttributesEntityFrom } from './TextAttributesEntity'
|
|
8
|
-
import { isEmptyString } from '../validators'
|
|
9
4
|
|
|
10
5
|
@ChildEntity('CredentialLocaleBranding')
|
|
11
6
|
@Index('IDX_CredentialLocaleBrandingEntity_credentialBranding_locale', ['credentialBranding', 'locale'], { unique: true })
|
|
@@ -19,15 +14,3 @@ export class CredentialLocaleBrandingEntity extends BaseLocaleBrandingEntity {
|
|
|
19
14
|
@Column('text', { name: 'credentialBrandingId', nullable: false })
|
|
20
15
|
credentialBrandingId!: string
|
|
21
16
|
}
|
|
22
|
-
|
|
23
|
-
export const credentialLocaleBrandingEntityFrom = (args: IBasicCredentialLocaleBranding): CredentialLocaleBrandingEntity => {
|
|
24
|
-
const credentialLocaleBrandingEntity: CredentialLocaleBrandingEntity = new CredentialLocaleBrandingEntity()
|
|
25
|
-
credentialLocaleBrandingEntity.alias = isEmptyString(args.alias) ? undefined : args.alias
|
|
26
|
-
credentialLocaleBrandingEntity.locale = args.locale ? args.locale : ''
|
|
27
|
-
credentialLocaleBrandingEntity.logo = args.logo ? imageAttributesEntityFrom(args.logo) : undefined
|
|
28
|
-
credentialLocaleBrandingEntity.description = isEmptyString(args.description) ? undefined : args.description
|
|
29
|
-
credentialLocaleBrandingEntity.background = args.background ? backgroundAttributesEntityFrom(args.background) : undefined
|
|
30
|
-
credentialLocaleBrandingEntity.text = args.text ? textAttributesEntityFrom(args.text) : undefined
|
|
31
|
-
|
|
32
|
-
return credentialLocaleBrandingEntity
|
|
33
|
-
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { BaseEntity, BeforeInsert, BeforeUpdate, Column, Entity, JoinColumn, OneToOne, PrimaryGeneratedColumn } from 'typeorm'
|
|
2
|
-
import {
|
|
3
|
-
import { ImageDimensionsEntity, imageDimensionsEntityFrom } from './ImageDimensionsEntity'
|
|
2
|
+
import { ImageDimensionsEntity } from './ImageDimensionsEntity'
|
|
4
3
|
import { validate, Validate, ValidationError } from 'class-validator'
|
|
5
|
-
import {
|
|
4
|
+
import { IsNonEmptyStringConstraint } from '../validators'
|
|
6
5
|
|
|
7
6
|
@Entity('ImageAttributes')
|
|
8
7
|
export class ImageAttributesEntity extends BaseEntity {
|
|
@@ -44,14 +43,3 @@ export class ImageAttributesEntity extends BaseEntity {
|
|
|
44
43
|
return
|
|
45
44
|
}
|
|
46
45
|
}
|
|
47
|
-
|
|
48
|
-
export const imageAttributesEntityFrom = (args: IBasicImageAttributes): ImageAttributesEntity => {
|
|
49
|
-
const imageAttributesEntity: ImageAttributesEntity = new ImageAttributesEntity()
|
|
50
|
-
imageAttributesEntity.uri = isEmptyString(args.uri) ? undefined : args.uri
|
|
51
|
-
imageAttributesEntity.dataUri = isEmptyString(args.dataUri) ? undefined : args.dataUri
|
|
52
|
-
imageAttributesEntity.mediaType = isEmptyString(args.mediaType) ? undefined : args.mediaType
|
|
53
|
-
imageAttributesEntity.alt = isEmptyString(args.alt) ? undefined : args.alt
|
|
54
|
-
imageAttributesEntity.dimensions = args.dimensions ? imageDimensionsEntityFrom(args.dimensions) : undefined
|
|
55
|
-
|
|
56
|
-
return imageAttributesEntity
|
|
57
|
-
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { BaseEntity, Column, Entity, PrimaryGeneratedColumn } from 'typeorm'
|
|
2
|
-
import { IBasicImageDimensions } from '../../types'
|
|
3
2
|
|
|
4
3
|
@Entity('ImageDimensions')
|
|
5
4
|
export class ImageDimensionsEntity extends BaseEntity {
|
|
@@ -12,11 +11,3 @@ export class ImageDimensionsEntity extends BaseEntity {
|
|
|
12
11
|
@Column('integer', { name: 'height', nullable: false, unique: false })
|
|
13
12
|
height!: number
|
|
14
13
|
}
|
|
15
|
-
|
|
16
|
-
export const imageDimensionsEntityFrom = (args: IBasicImageDimensions): ImageDimensionsEntity => {
|
|
17
|
-
const imageDimensionsEntity: ImageDimensionsEntity = new ImageDimensionsEntity()
|
|
18
|
-
imageDimensionsEntity.width = args.width
|
|
19
|
-
imageDimensionsEntity.height = args.height
|
|
20
|
-
|
|
21
|
-
return imageDimensionsEntity
|
|
22
|
-
}
|
|
@@ -12,8 +12,7 @@ import {
|
|
|
12
12
|
} from 'typeorm'
|
|
13
13
|
import { ArrayMinSize, IsNotEmpty, validate, ValidationError } from 'class-validator'
|
|
14
14
|
import { typeOrmDateTime } from '@sphereon/ssi-sdk.agent-config'
|
|
15
|
-
import { IssuerLocaleBrandingEntity
|
|
16
|
-
import { IBasicIssuerBranding, IBasicIssuerLocaleBranding } from '../../types'
|
|
15
|
+
import { IssuerLocaleBrandingEntity } from './IssuerLocaleBrandingEntity'
|
|
17
16
|
|
|
18
17
|
@Entity('IssuerBranding')
|
|
19
18
|
@Index('IDX_IssuerBrandingEntity_issuerCorrelationId', ['issuerCorrelationId'])
|
|
@@ -61,13 +60,3 @@ export class IssuerBrandingEntity extends BaseEntity {
|
|
|
61
60
|
return
|
|
62
61
|
}
|
|
63
62
|
}
|
|
64
|
-
|
|
65
|
-
export const issuerBrandingEntityFrom = (args: IBasicIssuerBranding): IssuerBrandingEntity => {
|
|
66
|
-
const issuerBrandingEntity: IssuerBrandingEntity = new IssuerBrandingEntity()
|
|
67
|
-
issuerBrandingEntity.issuerCorrelationId = args.issuerCorrelationId
|
|
68
|
-
issuerBrandingEntity.localeBranding = args.localeBranding.map((localeBranding: IBasicIssuerLocaleBranding) =>
|
|
69
|
-
issuerLocaleBrandingEntityFrom(localeBranding),
|
|
70
|
-
)
|
|
71
|
-
|
|
72
|
-
return issuerBrandingEntity
|
|
73
|
-
}
|
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
import { ChildEntity, Column, Index, JoinColumn, ManyToOne } from 'typeorm'
|
|
2
|
-
import { IBasicIssuerLocaleBranding } from '../../types'
|
|
3
|
-
import { backgroundAttributesEntityFrom } from './BackgroundAttributesEntity'
|
|
4
|
-
import { imageAttributesEntityFrom } from './ImageAttributesEntity'
|
|
5
2
|
import { IssuerBrandingEntity } from './IssuerBrandingEntity'
|
|
6
3
|
import { BaseLocaleBrandingEntity } from './BaseLocaleBrandingEntity'
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
4
|
+
import { IsNonEmptyStringConstraint } from '../validators'
|
|
5
|
+
import { Validate } from 'class-validator'
|
|
9
6
|
|
|
10
7
|
@ChildEntity('IssuerLocaleBranding')
|
|
11
8
|
@Index('IDX_IssuerLocaleBrandingEntity_issuerBranding_locale', ['issuerBranding', 'locale'], { unique: true })
|
|
@@ -16,18 +13,21 @@ export class IssuerLocaleBrandingEntity extends BaseLocaleBrandingEntity {
|
|
|
16
13
|
@JoinColumn({ name: 'issuerBrandingId' })
|
|
17
14
|
issuerBranding!: IssuerBrandingEntity
|
|
18
15
|
|
|
19
|
-
@Column('text', { name: '
|
|
20
|
-
|
|
21
|
-
|
|
16
|
+
@Column('text', { name: 'client_uri', nullable: true, unique: false })
|
|
17
|
+
@Validate(IsNonEmptyStringConstraint, { message: 'Blank client uris are not allowed' })
|
|
18
|
+
clientUri?: string
|
|
19
|
+
|
|
20
|
+
@Column('text', { name: 'tos_uri', nullable: true, unique: false })
|
|
21
|
+
@Validate(IsNonEmptyStringConstraint, { message: 'Blank tos uris are not allowed' })
|
|
22
|
+
tosUri?: string
|
|
22
23
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
issuerLocaleBrandingEntity.locale = args.locale ? args.locale : ''
|
|
27
|
-
issuerLocaleBrandingEntity.logo = args.logo ? imageAttributesEntityFrom(args.logo) : undefined
|
|
28
|
-
issuerLocaleBrandingEntity.description = isEmptyString(args.description) ? undefined : args.description
|
|
29
|
-
issuerLocaleBrandingEntity.background = args.background ? backgroundAttributesEntityFrom(args.background) : undefined
|
|
30
|
-
issuerLocaleBrandingEntity.text = args.text ? textAttributesEntityFrom(args.text) : undefined
|
|
24
|
+
@Column('text', { name: 'policy_uri', nullable: true, unique: false })
|
|
25
|
+
@Validate(IsNonEmptyStringConstraint, { message: 'Blank policy uris are not allowed' })
|
|
26
|
+
policyUri?: string
|
|
31
27
|
|
|
32
|
-
|
|
28
|
+
@Column('simple-array', { name: 'contacts', nullable: true, unique: false })
|
|
29
|
+
contacts?: Array<string>
|
|
30
|
+
|
|
31
|
+
@Column('text', { name: 'issuerBrandingId', nullable: false })
|
|
32
|
+
issuerBrandingId!: string
|
|
33
33
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { BaseEntity, BeforeInsert, BeforeUpdate, Column, Entity, PrimaryGeneratedColumn } from 'typeorm'
|
|
2
|
-
import { IBasicTextAttributes } from '../../types'
|
|
3
2
|
import { validate, Validate, ValidationError } from 'class-validator'
|
|
4
|
-
import {
|
|
3
|
+
import { IsNonEmptyStringConstraint } from '../validators'
|
|
5
4
|
|
|
6
5
|
@Entity('TextAttributes')
|
|
7
6
|
export class TextAttributesEntity extends BaseEntity {
|
|
@@ -22,10 +21,3 @@ export class TextAttributesEntity extends BaseEntity {
|
|
|
22
21
|
return
|
|
23
22
|
}
|
|
24
23
|
}
|
|
25
|
-
|
|
26
|
-
export const textAttributesEntityFrom = (args: IBasicTextAttributes): TextAttributesEntity => {
|
|
27
|
-
const textAttributesEntity: TextAttributesEntity = new TextAttributesEntity()
|
|
28
|
-
textAttributesEntity.color = isEmptyString(args.color) ? undefined : args.color
|
|
29
|
-
|
|
30
|
-
return textAttributesEntity
|
|
31
|
-
}
|
|
@@ -3,12 +3,13 @@ import { LoggingEventType, OrPromise } from '@sphereon/ssi-types'
|
|
|
3
3
|
import Debug, { Debugger } from 'debug'
|
|
4
4
|
import { DataSource } from 'typeorm'
|
|
5
5
|
import { AbstractEventLoggerStore } from './AbstractEventLoggerStore'
|
|
6
|
+
import { AuditEventEntity } from '../entities/eventLogger/AuditEventEntity'
|
|
6
7
|
import {
|
|
7
8
|
activityEventEntityFrom,
|
|
8
|
-
|
|
9
|
-
auditEventEntityFrom
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
activityEventFrom,
|
|
10
|
+
auditEventEntityFrom,
|
|
11
|
+
auditEventFrom
|
|
12
|
+
} from '../utils/eventLogger/MappingUtils'
|
|
12
13
|
import {
|
|
13
14
|
GetActivityEventsArgs,
|
|
14
15
|
GetAuditEventsArgs,
|
package/src/index.ts
CHANGED
|
@@ -8,14 +8,14 @@ import { DidAuthConfigEntity } from './entities/contact/DidAuthConfigEntity'
|
|
|
8
8
|
import { IdentityEntity } from './entities/contact/IdentityEntity'
|
|
9
9
|
import { IdentityMetadataItemEntity } from './entities/contact/IdentityMetadataItemEntity'
|
|
10
10
|
import { OpenIdConfigEntity } from './entities/contact/OpenIdConfigEntity'
|
|
11
|
-
import { BackgroundAttributesEntity
|
|
12
|
-
import { CredentialBrandingEntity
|
|
13
|
-
import { CredentialLocaleBrandingEntity
|
|
14
|
-
import { ImageAttributesEntity
|
|
15
|
-
import { ImageDimensionsEntity
|
|
16
|
-
import { IssuerLocaleBrandingEntity
|
|
17
|
-
import { IssuerBrandingEntity
|
|
18
|
-
import { TextAttributesEntity
|
|
11
|
+
import { BackgroundAttributesEntity } from './entities/issuanceBranding/BackgroundAttributesEntity'
|
|
12
|
+
import { CredentialBrandingEntity } from './entities/issuanceBranding/CredentialBrandingEntity'
|
|
13
|
+
import { CredentialLocaleBrandingEntity } from './entities/issuanceBranding/CredentialLocaleBrandingEntity'
|
|
14
|
+
import { ImageAttributesEntity } from './entities/issuanceBranding/ImageAttributesEntity'
|
|
15
|
+
import { ImageDimensionsEntity } from './entities/issuanceBranding/ImageDimensionsEntity'
|
|
16
|
+
import { IssuerLocaleBrandingEntity } from './entities/issuanceBranding/IssuerLocaleBrandingEntity'
|
|
17
|
+
import { IssuerBrandingEntity } from './entities/issuanceBranding/IssuerBrandingEntity'
|
|
18
|
+
import { TextAttributesEntity } from './entities/issuanceBranding/TextAttributesEntity'
|
|
19
19
|
import { StatusListEntity } from './entities/statusList2021/StatusList2021Entity'
|
|
20
20
|
import { StatusListEntryEntity } from './entities/statusList2021/StatusList2021EntryEntity'
|
|
21
21
|
import { MachineStateInfoEntity } from './entities/machineState/MachineStateInfoEntity'
|
|
@@ -33,10 +33,8 @@ export { DigitalCredentialStore } from './digitalCredential/DigitalCredentialSto
|
|
|
33
33
|
export { AbstractIssuanceBrandingStore } from './issuanceBranding/AbstractIssuanceBrandingStore'
|
|
34
34
|
export { IssuanceBrandingStore } from './issuanceBranding/IssuanceBrandingStore'
|
|
35
35
|
export { StatusListStore } from './statusList/StatusListStore'
|
|
36
|
-
import { AuditEventEntity
|
|
36
|
+
import { AuditEventEntity } from './entities/eventLogger/AuditEventEntity'
|
|
37
37
|
import { DigitalCredentialEntity } from './entities/digitalCredential/DigitalCredentialEntity'
|
|
38
|
-
import { digitalCredentialFrom, digitalCredentialsFrom, nonPersistedDigitalCredentialEntityFromAddArgs } from './utils/digitalCredential/MappingUtils'
|
|
39
|
-
import { isPresentationDefinitionEqual } from './utils/presentationDefinition/MappingUtils'
|
|
40
38
|
import { PresentationDefinitionItemEntity } from './entities/presentationDefinition/PresentationDefinitionItemEntity'
|
|
41
39
|
import { ContactMetadataItemEntity } from './entities/contact/ContactMetadataItemEntity'
|
|
42
40
|
export { AbstractEventLoggerStore } from './eventLogger/AbstractEventLoggerStore'
|
|
@@ -59,6 +57,10 @@ export {
|
|
|
59
57
|
export * from './types'
|
|
60
58
|
export * from './utils/contact/MappingUtils'
|
|
61
59
|
export * from './utils/digitalCredential/MappingUtils'
|
|
60
|
+
export * from './utils/eventLogger/MappingUtils'
|
|
61
|
+
export * from './utils/issuanceBranding/MappingUtils'
|
|
62
|
+
export * from './utils/presentationDefinition/MappingUtils'
|
|
63
|
+
export * from './utils/hasher'
|
|
62
64
|
|
|
63
65
|
export const DataStoreContactEntities = [
|
|
64
66
|
BaseConfigEntity,
|
|
@@ -133,28 +135,13 @@ export {
|
|
|
133
135
|
IssuerLocaleBrandingEntity,
|
|
134
136
|
ElectronicAddressEntity,
|
|
135
137
|
PhysicalAddressEntity,
|
|
136
|
-
backgroundAttributesEntityFrom,
|
|
137
|
-
credentialBrandingEntityFrom,
|
|
138
|
-
imageAttributesEntityFrom,
|
|
139
|
-
imageDimensionsEntityFrom,
|
|
140
|
-
issuerBrandingEntityFrom,
|
|
141
|
-
textAttributesEntityFrom,
|
|
142
|
-
issuerLocaleBrandingEntityFrom,
|
|
143
|
-
credentialLocaleBrandingEntityFrom,
|
|
144
138
|
IStatusListEntity,
|
|
145
139
|
IStatusListEntryEntity,
|
|
146
140
|
StatusListEntity,
|
|
147
141
|
StatusListEntryEntity,
|
|
148
142
|
AuditEventEntity,
|
|
149
|
-
auditEventEntityFrom,
|
|
150
143
|
DigitalCredentialEntity,
|
|
151
|
-
digitalCredentialFrom,
|
|
152
|
-
digitalCredentialsFrom,
|
|
153
|
-
nonPersistedDigitalCredentialEntityFromAddArgs,
|
|
154
144
|
MachineStateInfoEntity,
|
|
155
145
|
PresentationDefinitionItemEntity,
|
|
156
|
-
isPresentationDefinitionEqual,
|
|
157
146
|
ContactMetadataItemEntity,
|
|
158
147
|
}
|
|
159
|
-
|
|
160
|
-
export * from './utils/hasher'
|
|
@@ -1,17 +1,25 @@
|
|
|
1
|
+
import { OrPromise } from '@sphereon/ssi-types'
|
|
1
2
|
import Debug from 'debug'
|
|
2
3
|
import { DataSource, DeleteResult, In, Not, Repository } from 'typeorm'
|
|
3
|
-
import {
|
|
4
|
+
import {
|
|
5
|
+
credentialBrandingEntityFrom,
|
|
6
|
+
credentialBrandingFrom,
|
|
7
|
+
credentialLocaleBrandingEntityFrom,
|
|
8
|
+
issuerBrandingEntityFrom,
|
|
9
|
+
issuerBrandingFrom,
|
|
10
|
+
issuerLocaleBrandingEntityFrom,
|
|
11
|
+
localeBrandingFrom
|
|
12
|
+
} from '../utils/issuanceBranding/MappingUtils'
|
|
4
13
|
import { BackgroundAttributesEntity } from '../entities/issuanceBranding/BackgroundAttributesEntity'
|
|
5
14
|
import { ImageAttributesEntity } from '../entities/issuanceBranding/ImageAttributesEntity'
|
|
6
15
|
import { ImageDimensionsEntity } from '../entities/issuanceBranding/ImageDimensionsEntity'
|
|
7
|
-
import { IssuerBrandingEntity
|
|
8
|
-
import { CredentialBrandingEntity
|
|
9
|
-
import { CredentialLocaleBrandingEntity
|
|
10
|
-
import { IssuerLocaleBrandingEntity
|
|
16
|
+
import { IssuerBrandingEntity } from '../entities/issuanceBranding/IssuerBrandingEntity'
|
|
17
|
+
import { CredentialBrandingEntity } from '../entities/issuanceBranding/CredentialBrandingEntity'
|
|
18
|
+
import { CredentialLocaleBrandingEntity } from '../entities/issuanceBranding/CredentialLocaleBrandingEntity'
|
|
19
|
+
import { IssuerLocaleBrandingEntity } from '../entities/issuanceBranding/IssuerLocaleBrandingEntity'
|
|
11
20
|
import { BaseLocaleBrandingEntity } from '../entities/issuanceBranding/BaseLocaleBrandingEntity'
|
|
12
21
|
import { TextAttributesEntity } from '../entities/issuanceBranding/TextAttributesEntity'
|
|
13
22
|
import { AbstractIssuanceBrandingStore } from './AbstractIssuanceBrandingStore'
|
|
14
|
-
import { credentialBrandingFrom, issuerBrandingFrom, localeBrandingFrom } from '../utils/issuanceBranding/MappingUtils'
|
|
15
23
|
import {
|
|
16
24
|
IAddCredentialBrandingArgs,
|
|
17
25
|
IAddCredentialLocaleBrandingArgs,
|
|
@@ -19,7 +19,7 @@ export class CreateIssuanceBranding1685628974232 implements MigrationInterface {
|
|
|
19
19
|
`CREATE TABLE "TextAttributes" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "color" character varying(255), CONSTRAINT "PK_TextAttributes_id" PRIMARY KEY ("id"))`,
|
|
20
20
|
)
|
|
21
21
|
await queryRunner.query(
|
|
22
|
-
`CREATE TABLE "BaseLocaleBranding" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "alias" character varying(255), "locale" character varying(255) NOT NULL, "description" character varying(255), "created_at" TIMESTAMP NOT NULL DEFAULT now(), "last_updated_at" TIMESTAMP NOT NULL DEFAULT now(), "credentialBrandingId" uuid, "issuerBrandingId" uuid, "type" character varying NOT NULL, "logoId" uuid, "backgroundId" uuid, "textId" uuid, CONSTRAINT "UQ_logoId" UNIQUE ("logoId"), CONSTRAINT "UQ_backgroundId" UNIQUE ("backgroundId"), CONSTRAINT "UQ_textId" UNIQUE ("textId"), CONSTRAINT "PK_BaseLocaleBranding_id" PRIMARY KEY ("id"))`,
|
|
22
|
+
`CREATE TABLE "BaseLocaleBranding" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "alias" character varying(255), "locale" character varying(255) NOT NULL, "description" character varying(255), "created_at" TIMESTAMP NOT NULL DEFAULT now(), "last_updated_at" TIMESTAMP NOT NULL DEFAULT now(), "credentialBrandingId" uuid, "issuerBrandingId" uuid, "type" character varying NOT NULL, "logoId" uuid, "backgroundId" uuid, "textId" uuid, "client_uri" character varying, "tos_uri" character varying, "policy_uri" character varying, "contacts" character varying, CONSTRAINT "UQ_logoId" UNIQUE ("logoId"), CONSTRAINT "UQ_backgroundId" UNIQUE ("backgroundId"), CONSTRAINT "UQ_textId" UNIQUE ("textId"), CONSTRAINT "PK_BaseLocaleBranding_id" PRIMARY KEY ("id"))`,
|
|
23
23
|
)
|
|
24
24
|
await queryRunner.query(
|
|
25
25
|
`CREATE UNIQUE INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale" ON "BaseLocaleBranding" ("credentialBrandingId", "locale")`,
|
|
@@ -7,7 +7,7 @@ export class CreateDigitalCredential1708525189001 implements MigrationInterface
|
|
|
7
7
|
await queryRunner.query(`CREATE TYPE "digital_document_type" AS ENUM('VC', 'VP', 'C', 'P')`)
|
|
8
8
|
await queryRunner.query(`CREATE TYPE "digital_regulation_type" AS ENUM('PID', 'QEAA', 'EAA', 'NON_REGULATED')`)
|
|
9
9
|
await queryRunner.query(`CREATE TYPE "digital_credential_document_format" AS ENUM('JSON_LD', 'JWT', 'SD_JWT', 'MSO_MDOC')`)
|
|
10
|
-
await queryRunner.query(`CREATE TYPE "digital_credential_credential_role" AS ENUM('ISSUER', 'VERIFIER', 'HOLDER')`)
|
|
10
|
+
await queryRunner.query(`CREATE TYPE "digital_credential_credential_role" AS ENUM('ISSUER', 'VERIFIER', 'HOLDER', 'FEDERATION_TRUST_ANCHOR')`)
|
|
11
11
|
await queryRunner.query(`CREATE TYPE "digital_credential_correlation_type" AS ENUM('DID', 'KID', 'URL', 'X509_SAN')`)
|
|
12
12
|
await queryRunner.query(`CREATE TYPE "digital_credential_state_type" AS ENUM('REVOKED', 'VERIFIED', 'EXPIRED')`)
|
|
13
13
|
|