@things-factory/auth-base 6.2.24 → 6.2.27

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/auth-base",
3
- "version": "6.2.24",
3
+ "version": "6.2.27",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "dist-client/index.js",
6
6
  "things-factory": true,
@@ -30,11 +30,11 @@
30
30
  "migration:create": "node ../../node_modules/typeorm/cli.js migration:create -d ./server/migrations"
31
31
  },
32
32
  "dependencies": {
33
- "@things-factory/email-base": "^6.2.24",
34
- "@things-factory/env": "^6.2.0",
35
- "@things-factory/i18n-base": "^6.2.24",
36
- "@things-factory/shell": "^6.2.24",
37
- "@things-factory/utils": "^6.2.0",
33
+ "@things-factory/email-base": "^6.2.27",
34
+ "@things-factory/env": "^6.2.27",
35
+ "@things-factory/i18n-base": "^6.2.27",
36
+ "@things-factory/shell": "^6.2.27",
37
+ "@things-factory/utils": "^6.2.27",
38
38
  "jsonwebtoken": "^9.0.0",
39
39
  "koa-passport": "^6.0.0",
40
40
  "koa-session": "^6.4.0",
@@ -42,5 +42,5 @@
42
42
  "passport-jwt": "^4.0.0",
43
43
  "passport-local": "^1.0.0"
44
44
  },
45
- "gitHead": "f407983563cca529ba87ea8febb5be751ad3229e"
45
+ "gitHead": "6d414311ca45c329e93606fe46edd7ea53c819c5"
46
46
  }
@@ -10,10 +10,40 @@ import {
10
10
  PrimaryGeneratedColumn,
11
11
  UpdateDateColumn
12
12
  } from 'typeorm'
13
- import { ObjectType, Field, ID } from 'type-graphql'
13
+ import { ObjectType, InputType, Field, ID } from 'type-graphql'
14
14
  import { Role } from '../role/role'
15
15
  import { User } from '../user/user'
16
16
 
17
+ @ObjectType()
18
+ export class PrivilegeObject {
19
+ @Field({ nullable: true })
20
+ privilege?: string
21
+
22
+ @Field({ nullable: true })
23
+ category?: string
24
+
25
+ @Field({ nullable: true })
26
+ owner?: boolean
27
+
28
+ @Field({ nullable: true })
29
+ super?: boolean
30
+ }
31
+
32
+ @InputType()
33
+ export class PrivilegeInput {
34
+ @Field({ nullable: true })
35
+ privilege?: string
36
+
37
+ @Field({ nullable: true })
38
+ category?: string
39
+
40
+ @Field({ nullable: true })
41
+ owner?: boolean
42
+
43
+ @Field({ nullable: true })
44
+ super?: boolean
45
+ }
46
+
17
47
  @Entity()
18
48
  @Index('ix_privilege_0', (privilege: Privilege) => [privilege.name, privilege.category], {
19
49
  unique: false