From 871c48c4e1e652ff05eee3c2badf3b71fbf5f1ca Mon Sep 17 00:00:00 2001 From: Trent Larson Date: Sun, 25 Apr 2021 19:06:21 -0600 Subject: [PATCH] add names to entities (so that code on devices succeeds) --- packages/data-store/src/entities/claim.ts | 2 +- packages/data-store/src/entities/credential.ts | 2 +- packages/data-store/src/entities/identifier.ts | 2 +- packages/data-store/src/entities/key.ts | 2 +- packages/data-store/src/entities/message.ts | 2 +- packages/data-store/src/entities/presentation.ts | 2 +- packages/data-store/src/entities/service.ts | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/data-store/src/entities/claim.ts b/packages/data-store/src/entities/claim.ts index 5e9bcc3d0..fa6fbf01f 100644 --- a/packages/data-store/src/entities/claim.ts +++ b/packages/data-store/src/entities/claim.ts @@ -2,7 +2,7 @@ import { Entity, Column, BaseEntity, ManyToOne, PrimaryColumn } from 'typeorm' import { Identifier } from './identifier' import { Credential } from './credential' -@Entity() +@Entity('claim') export class Claim extends BaseEntity { @PrimaryColumn() //@ts-ignore diff --git a/packages/data-store/src/entities/credential.ts b/packages/data-store/src/entities/credential.ts index 3b06c6fe0..0b9d18be8 100644 --- a/packages/data-store/src/entities/credential.ts +++ b/packages/data-store/src/entities/credential.ts @@ -6,7 +6,7 @@ import { Message } from './message' import { Presentation } from './presentation' import { Claim } from './claim' -@Entity() +@Entity('credential') export class Credential extends BaseEntity { @PrimaryColumn() //@ts-ignore diff --git a/packages/data-store/src/entities/identifier.ts b/packages/data-store/src/entities/identifier.ts index c77945cc0..d259d618e 100644 --- a/packages/data-store/src/entities/identifier.ts +++ b/packages/data-store/src/entities/identifier.ts @@ -17,7 +17,7 @@ import { Credential } from './credential' import { Claim } from './claim' import { Connection } from 'typeorm' -@Entity() +@Entity('identifier') @Index(['alias', 'provider'], { unique: true }) export class Identifier extends BaseEntity { @PrimaryColumn() diff --git a/packages/data-store/src/entities/key.ts b/packages/data-store/src/entities/key.ts index cb4af3640..d52aa21ea 100644 --- a/packages/data-store/src/entities/key.ts +++ b/packages/data-store/src/entities/key.ts @@ -3,7 +3,7 @@ import { Identifier } from './identifier' export type KeyType = 'Ed25519' | 'Secp256k1' -@Entity() +@Entity('key') export class Key extends BaseEntity { @PrimaryColumn() //@ts-ignore diff --git a/packages/data-store/src/entities/message.ts b/packages/data-store/src/entities/message.ts index 79aba3d04..110aa6a7a 100644 --- a/packages/data-store/src/entities/message.ts +++ b/packages/data-store/src/entities/message.ts @@ -21,7 +21,7 @@ export interface MetaData { value?: string } -@Entity() +@Entity('message') export class Message extends BaseEntity { @BeforeInsert() setId() { diff --git a/packages/data-store/src/entities/presentation.ts b/packages/data-store/src/entities/presentation.ts index e4c051755..2f22408a9 100644 --- a/packages/data-store/src/entities/presentation.ts +++ b/packages/data-store/src/entities/presentation.ts @@ -14,7 +14,7 @@ import { Identifier } from './identifier' import { Message } from './message' import { Credential, createCredentialEntity } from './credential' -@Entity() +@Entity('presentation') export class Presentation extends BaseEntity { @PrimaryColumn() //@ts-ignore diff --git a/packages/data-store/src/entities/service.ts b/packages/data-store/src/entities/service.ts index c96487987..810e66c7b 100644 --- a/packages/data-store/src/entities/service.ts +++ b/packages/data-store/src/entities/service.ts @@ -1,7 +1,7 @@ import { Entity, Column, PrimaryColumn, BaseEntity, ManyToOne } from 'typeorm' import { Identifier } from './identifier' -@Entity() +@Entity('service') export class Service extends BaseEntity { @PrimaryColumn() //@ts-ignore