tango-api-schema 2.0.148-hotfix-dev → 2.0.148

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": "tango-api-schema",
3
- "version": "2.0.148-hotfix-dev",
3
+ "version": "2.0.148",
4
4
  "description": "tangoEye model schema",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -2,9 +2,6 @@ import mongoose from 'mongoose';
2
2
 
3
3
  const roles = new mongoose.Schema(
4
4
  {
5
- clientId:{
6
- type:String
7
- },
8
5
  roleName: {
9
6
  type: String,
10
7
  },
@@ -23,10 +20,6 @@ const roles = new mongoose.Schema(
23
20
  type:Boolean,
24
21
  default:false
25
22
  },
26
- isPrefilled:{
27
- type:Boolean,
28
- default:false
29
- },
30
23
  permission: [
31
24
  {
32
25
  featureName: {
@@ -26,38 +26,39 @@ const user = new mongoose.Schema(
26
26
  },
27
27
  role: {
28
28
  type: String,
29
+ enum: [ 'superadmin', 'admin', 'user' ],
29
30
  default: 'user',
30
31
  },
31
32
  isActive: {
32
33
  type: Boolean,
33
34
  default: true,
34
35
  },
35
- // permission: [
36
- // {
37
- // featureName: {
38
- // type: String,
39
- // },
40
- // product: [
41
- // {
42
- // name: {
43
- // type: String,
44
- // },
45
- // isView: {
46
- // type: Boolean,
47
- // },
48
- // isEdit: {
49
- // type: Boolean,
50
- // },
51
- // isDownload: {
52
- // type: Boolean,
53
- // },
54
- // isDelete: {
55
- // type: Boolean,
56
- // },
57
- // },
58
- // ],
59
- // },
60
- // ],
36
+ permission: [
37
+ {
38
+ featureName: {
39
+ type: String,
40
+ },
41
+ product: [
42
+ {
43
+ name: {
44
+ type: String,
45
+ },
46
+ isView: {
47
+ type: Boolean,
48
+ },
49
+ isEdit: {
50
+ type: Boolean,
51
+ },
52
+ isDownload: {
53
+ type: Boolean,
54
+ },
55
+ isDelete: {
56
+ type: Boolean,
57
+ },
58
+ },
59
+ ],
60
+ },
61
+ ],
61
62
  userType:{
62
63
  type: String,
63
64
  enum:['tango','client','lead']
@@ -81,10 +82,7 @@ const user = new mongoose.Schema(
81
82
  type: Boolean,
82
83
  default: false
83
84
  }
84
- },
85
- roleId:{
86
- type:mongoose.Types.ObjectId
87
- },
85
+ },
88
86
  },
89
87
  {
90
88
  strict: true,