@dynamatix/gb-schemas 2.0.43 → 2.0.45

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.
@@ -1,33 +1,22 @@
1
1
  import { RoleGroupEntity } from './role-group.entity';
2
2
  import { SystemParameterEntity } from '../shared/system-parameter.entity';
3
- export declare class ClaimEntity {
4
- id: string;
5
- key: string;
6
- value: string;
7
- userId: string;
8
- createdAt: Date;
9
- updatedAt: Date;
10
- constructor(partial: Partial<ClaimEntity>);
11
- }
12
3
  export declare class UserEntity {
13
4
  id: string;
14
5
  accountId: number;
15
6
  email: string;
16
7
  fullName: string;
17
- password: string;
18
8
  organisationId?: string;
19
- status: string;
9
+ status: number;
20
10
  modifiedOn?: Date;
21
- modifiedById?: string;
11
+ modifiedById?: number;
22
12
  createdOnInApprivo?: Date;
23
- createdById?: string;
13
+ createdById?: number;
24
14
  deletedOn?: Date;
25
- deletedById?: string;
15
+ deletedById?: number;
26
16
  token?: string;
27
17
  createdAt: Date;
28
18
  updatedAt: Date;
29
19
  groups?: RoleGroupEntity[];
30
- claims?: ClaimEntity[];
31
20
  createdSystemParameters?: SystemParameterEntity[];
32
21
  updatedSystemParameters?: SystemParameterEntity[];
33
22
  constructor(partial: Partial<UserEntity>);
@@ -1 +1 @@
1
- {"version":3,"file":"user.entity.d.ts","sourceRoot":"","sources":["../../../entities/users/user.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;AAE1E,qBAAa,WAAW;IACpB,EAAE,EAAG,MAAM,CAAC;IACZ,GAAG,EAAG,MAAM,CAAC;IACb,KAAK,EAAG,MAAM,CAAC;IACf,MAAM,EAAG,MAAM,CAAC;IAChB,SAAS,EAAG,IAAI,CAAC;IACjB,SAAS,EAAG,IAAI,CAAC;gBAEL,OAAO,EAAE,OAAO,CAAC,WAAW,CAAC;C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C,EAAE,MAAM,CAAC;IACtB,kBAAkB,CAAC,EAAE,IAAI,CAAC;IAC1B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,IAAI,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,EAAG,IAAI,CAAC;IACjB,SAAS,EAAG,IAAI,CAAC;IAGjB,MAAM,CAAC,EAAE,eAAe,EAAE,CAAC;IAC3B,uBAAuB,CAAC,EAAE,qBAAqB,EAAE,CAAC;IAClD,uBAAuB,CAAC,EAAE,qBAAqB,EAAE,CAAC;gBAEtC,OAAO,EAAE,OAAO,CAAC,UAAU,CAAC;CAG3C"}
@@ -1,8 +1,3 @@
1
- export class ClaimEntity {
2
- constructor(partial) {
3
- Object.assign(this, partial);
4
- }
5
- }
6
1
  export class UserEntity {
7
2
  constructor(partial) {
8
3
  Object.assign(this, partial);
@@ -1,40 +1,24 @@
1
1
  import { RoleGroupEntity } from './role-group.entity';
2
2
  import { SystemParameterEntity } from '../shared/system-parameter.entity';
3
-
4
- export class ClaimEntity {
5
- id!: string;
6
- key!: string;
7
- value!: string;
8
- userId!: string;
9
- createdAt!: Date;
10
- updatedAt!: Date;
11
-
12
- constructor(partial: Partial<ClaimEntity>) {
13
- Object.assign(this, partial);
14
- }
15
- }
16
-
17
3
  export class UserEntity {
18
4
  id!: string;
19
5
  accountId!: number;
20
6
  email!: string;
21
7
  fullName!: string;
22
- password!: string;
23
8
  organisationId?: string;
24
- status!: string;
9
+ status!: number;
25
10
  modifiedOn?: Date;
26
- modifiedById?: string;
11
+ modifiedById?: number;
27
12
  createdOnInApprivo?: Date;
28
- createdById?: string;
13
+ createdById?: number;
29
14
  deletedOn?: Date;
30
- deletedById?: string;
15
+ deletedById?: number;
31
16
  token?: string;
32
17
  createdAt!: Date;
33
18
  updatedAt!: Date;
34
19
 
35
20
  // Relations
36
21
  groups?: RoleGroupEntity[];
37
- claims?: ClaimEntity[];
38
22
  createdSystemParameters?: SystemParameterEntity[];
39
23
  updatedSystemParameters?: SystemParameterEntity[];
40
24
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamatix/gb-schemas",
3
- "version": "2.0.43",
3
+ "version": "2.0.45",
4
4
  "description": "All the schemas for gatehouse bank back-end",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -0,0 +1,15 @@
1
+ /*
2
+ Warnings:
3
+
4
+ - You are about to drop the column `password` on the `users` table. All the data in the column will be lost.
5
+ - You are about to drop the `claims` table. If the table is not empty, all the data it contains will be lost.
6
+
7
+ */
8
+ -- DropForeignKey
9
+ ALTER TABLE "claims" DROP CONSTRAINT "claims_user_id_fkey";
10
+
11
+ -- AlterTable
12
+ ALTER TABLE "users" DROP COLUMN "password";
13
+
14
+ -- DropTable
15
+ DROP TABLE "claims";
@@ -0,0 +1,18 @@
1
+ /*
2
+ Warnings:
3
+
4
+ - The `modified_by_id` column on the `users` table would be dropped and recreated. This will lead to data loss if there is data in the column.
5
+ - The `created_by_id` column on the `users` table would be dropped and recreated. This will lead to data loss if there is data in the column.
6
+ - The `deleted_by_id` column on the `users` table would be dropped and recreated. This will lead to data loss if there is data in the column.
7
+ - Changed the type of `status` on the `users` table. No cast exists, the column would be dropped and recreated, which cannot be done if there is data, since the column is required.
8
+
9
+ */
10
+ -- AlterTable
11
+ ALTER TABLE "users" DROP COLUMN "status",
12
+ ADD COLUMN "status" INTEGER NOT NULL,
13
+ DROP COLUMN "modified_by_id",
14
+ ADD COLUMN "modified_by_id" INTEGER,
15
+ DROP COLUMN "created_by_id",
16
+ ADD COLUMN "created_by_id" INTEGER,
17
+ DROP COLUMN "deleted_by_id",
18
+ ADD COLUMN "deleted_by_id" INTEGER;
@@ -350,22 +350,20 @@ model User {
350
350
  accountId Int @unique @map("account_id")
351
351
  email String @unique
352
352
  fullName String @map("full_name")
353
- password String
354
353
  organisationId String? @map("organisation_id")
355
- status String
354
+ status Int
356
355
  modifiedOn DateTime? @map("modified_on")
357
- modifiedById String? @map("modified_by_id")
356
+ modifiedById Int? @map("modified_by_id")
358
357
  createdOnInApprivo DateTime? @map("created_on_in_apprivo")
359
- createdById String? @map("created_by_id")
358
+ createdById Int? @map("created_by_id")
360
359
  deletedOn DateTime? @map("deleted_on")
361
- deletedById String? @map("deleted_by_id")
360
+ deletedById Int? @map("deleted_by_id")
362
361
  token String?
363
362
  createdAt DateTime @default(now()) @map("created_at")
364
363
  updatedAt DateTime @updatedAt @map("updated_at")
365
364
 
366
365
  // Relations
367
366
  groups RoleGroup[] @relation("UserToRoleGroup")
368
- claims Claim[]
369
367
  createdSystemParameters SystemParameter[] @relation("CreatedByUser")
370
368
  updatedSystemParameters SystemParameter[] @relation("UpdatedByUser")
371
369
  createdNotes ApplicationNote[] @relation("CreatedByUser")
@@ -374,20 +372,6 @@ model User {
374
372
  underwriters Underwriter[] @relation("UserUnderwriters")
375
373
 
376
374
  @@map("users")
377
- }
378
-
379
- model Claim {
380
- id String @id @default(uuid())
381
- key String
382
- value String
383
- userId String @map("user_id")
384
- createdAt DateTime @default(now()) @map("created_at")
385
- updatedAt DateTime @updatedAt @map("updated_at")
386
-
387
- // Relations
388
- user User @relation(fields: [userId], references: [id])
389
-
390
- @@map("claims")
391
375
  }
392
376
 
393
377
  // From prisma/product-catalogues/product-catalogue.prisma
@@ -3,22 +3,20 @@ model User {
3
3
  accountId Int @unique @map("account_id")
4
4
  email String @unique
5
5
  fullName String @map("full_name")
6
- password String
7
6
  organisationId String? @map("organisation_id")
8
- status String
7
+ status Int
9
8
  modifiedOn DateTime? @map("modified_on")
10
- modifiedById String? @map("modified_by_id")
9
+ modifiedById Int? @map("modified_by_id")
11
10
  createdOnInApprivo DateTime? @map("created_on_in_apprivo")
12
- createdById String? @map("created_by_id")
11
+ createdById Int? @map("created_by_id")
13
12
  deletedOn DateTime? @map("deleted_on")
14
- deletedById String? @map("deleted_by_id")
13
+ deletedById Int? @map("deleted_by_id")
15
14
  token String?
16
15
  createdAt DateTime @default(now()) @map("created_at")
17
16
  updatedAt DateTime @updatedAt @map("updated_at")
18
17
 
19
18
  // Relations
20
19
  groups RoleGroup[] @relation("UserToRoleGroup")
21
- claims Claim[]
22
20
  createdSystemParameters SystemParameter[] @relation("CreatedByUser")
23
21
  updatedSystemParameters SystemParameter[] @relation("UpdatedByUser")
24
22
  createdNotes ApplicationNote[] @relation("CreatedByUser")
@@ -28,17 +26,3 @@ model User {
28
26
 
29
27
  @@map("users")
30
28
  }
31
-
32
- model Claim {
33
- id String @id @default(uuid())
34
- key String
35
- value String
36
- userId String @map("user_id")
37
- createdAt DateTime @default(now()) @map("created_at")
38
- updatedAt DateTime @updatedAt @map("updated_at")
39
-
40
- // Relations
41
- user User @relation(fields: [userId], references: [id])
42
-
43
- @@map("claims")
44
- }