tango-api-schema 2.1.31 → 2.1.33
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/index.js +5 -1
- package/package.json +1 -1
- package/schema/client.model.js +16 -16
- package/schema/cluster.model.js +61 -0
- package/schema/teams.model.js +54 -0
- package/schema/user.model.js +23 -0
package/index.js
CHANGED
|
@@ -45,6 +45,8 @@ import auditUserWalletModel from "./schema/auditUserWallet.model.js";
|
|
|
45
45
|
import mailOnlyuserModel from "./schema/mailOnlyuser.model.js";
|
|
46
46
|
import empDetectionOutputModel from "./schema/empDetectionOutput.model.js";
|
|
47
47
|
import auditUsersModel from "./schema/auditUsers.model.js";
|
|
48
|
+
import clusterModel from "./schema/cluster.model.js";
|
|
49
|
+
import teamsModel from "./schema/teams.model.js";
|
|
48
50
|
|
|
49
51
|
|
|
50
52
|
|
|
@@ -96,5 +98,7 @@ export default {
|
|
|
96
98
|
auditUserWalletModel,
|
|
97
99
|
mailOnlyuserModel,
|
|
98
100
|
empDetectionOutputModel,
|
|
99
|
-
auditUsersModel
|
|
101
|
+
auditUsersModel,
|
|
102
|
+
clusterModel,
|
|
103
|
+
teamsModel
|
|
100
104
|
};
|
package/package.json
CHANGED
package/schema/client.model.js
CHANGED
|
@@ -351,6 +351,22 @@ const client = new mongoose.Schema(
|
|
|
351
351
|
isNewDashboard:{
|
|
352
352
|
type:Boolean,
|
|
353
353
|
default:false
|
|
354
|
+
},
|
|
355
|
+
isFootfallAuditStores:{
|
|
356
|
+
type:Boolean,
|
|
357
|
+
default:false
|
|
358
|
+
},
|
|
359
|
+
isNewTraffic:{
|
|
360
|
+
type:Boolean,
|
|
361
|
+
default:false
|
|
362
|
+
},
|
|
363
|
+
isNewZone:{
|
|
364
|
+
type:Boolean,
|
|
365
|
+
default:false
|
|
366
|
+
},
|
|
367
|
+
isNewReports:{
|
|
368
|
+
type:Boolean,
|
|
369
|
+
default:false
|
|
354
370
|
},
|
|
355
371
|
},
|
|
356
372
|
document: {
|
|
@@ -501,22 +517,6 @@ const client = new mongoose.Schema(
|
|
|
501
517
|
default: false,
|
|
502
518
|
}
|
|
503
519
|
},
|
|
504
|
-
isFootfallAuditStores:{
|
|
505
|
-
type:Boolean,
|
|
506
|
-
default:false
|
|
507
|
-
},
|
|
508
|
-
isNewTraffic:{
|
|
509
|
-
type:Boolean,
|
|
510
|
-
default:false
|
|
511
|
-
},
|
|
512
|
-
isNewZone:{
|
|
513
|
-
type:Boolean,
|
|
514
|
-
default:false
|
|
515
|
-
},
|
|
516
|
-
isNewReports:{
|
|
517
|
-
type:Boolean,
|
|
518
|
-
default:false
|
|
519
|
-
},
|
|
520
520
|
},
|
|
521
521
|
{
|
|
522
522
|
strict: true,
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import mongoose from 'mongoose'
|
|
2
|
+
import mongooseUniqueValidator from 'mongoose-unique-validator'
|
|
3
|
+
|
|
4
|
+
let clusterSchema = new mongoose.Schema(
|
|
5
|
+
{
|
|
6
|
+
clientId: {
|
|
7
|
+
type: String
|
|
8
|
+
},
|
|
9
|
+
stores: [
|
|
10
|
+
{
|
|
11
|
+
storeId: {
|
|
12
|
+
type: String,
|
|
13
|
+
},
|
|
14
|
+
store: {
|
|
15
|
+
type: mongoose.Types.ObjectId
|
|
16
|
+
},
|
|
17
|
+
storeName: {
|
|
18
|
+
type: String
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
],
|
|
22
|
+
Teamlead: [
|
|
23
|
+
{
|
|
24
|
+
userName: {
|
|
25
|
+
type: String,
|
|
26
|
+
},
|
|
27
|
+
email: {
|
|
28
|
+
type: String,
|
|
29
|
+
},
|
|
30
|
+
userId: {
|
|
31
|
+
type: String
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
],
|
|
35
|
+
users: [
|
|
36
|
+
{
|
|
37
|
+
userName: {
|
|
38
|
+
type: String,
|
|
39
|
+
},
|
|
40
|
+
email: {
|
|
41
|
+
type: String,
|
|
42
|
+
},
|
|
43
|
+
userId: {
|
|
44
|
+
type: String
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
],
|
|
48
|
+
status: {
|
|
49
|
+
type: String
|
|
50
|
+
},
|
|
51
|
+
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
strict: true,
|
|
55
|
+
versionKey: false,
|
|
56
|
+
timestamps: true,
|
|
57
|
+
}
|
|
58
|
+
)
|
|
59
|
+
|
|
60
|
+
clusterSchema.plugin(mongooseUniqueValidator);
|
|
61
|
+
export default mongoose.model('cluster', clusterSchema);
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import mongoose from 'mongoose'
|
|
2
|
+
import mongooseUniqueValidator from 'mongoose-unique-validator'
|
|
3
|
+
|
|
4
|
+
let teamsSchema = new mongoose.Schema(
|
|
5
|
+
{
|
|
6
|
+
clientId: {
|
|
7
|
+
type: String
|
|
8
|
+
},
|
|
9
|
+
teamName: {
|
|
10
|
+
type: String
|
|
11
|
+
},
|
|
12
|
+
description: {
|
|
13
|
+
type: String
|
|
14
|
+
},
|
|
15
|
+
Teamlead: [
|
|
16
|
+
{
|
|
17
|
+
userName: {
|
|
18
|
+
type: String,
|
|
19
|
+
},
|
|
20
|
+
email: {
|
|
21
|
+
type: String,
|
|
22
|
+
},
|
|
23
|
+
userId: {
|
|
24
|
+
type: String
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
],
|
|
28
|
+
users: [
|
|
29
|
+
{
|
|
30
|
+
userName: {
|
|
31
|
+
type: String,
|
|
32
|
+
},
|
|
33
|
+
email: {
|
|
34
|
+
type: String,
|
|
35
|
+
},
|
|
36
|
+
userId: {
|
|
37
|
+
type: String
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
],
|
|
41
|
+
status: {
|
|
42
|
+
type: String
|
|
43
|
+
},
|
|
44
|
+
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
strict: true,
|
|
48
|
+
versionKey: false,
|
|
49
|
+
timestamps: true,
|
|
50
|
+
}
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
teamsSchema.plugin(mongooseUniqueValidator);
|
|
54
|
+
export default mongoose.model('teams', teamsSchema);
|
package/schema/user.model.js
CHANGED
|
@@ -59,6 +59,29 @@ const user = new mongoose.Schema(
|
|
|
59
59
|
],
|
|
60
60
|
},
|
|
61
61
|
],
|
|
62
|
+
rolespermission: [
|
|
63
|
+
{
|
|
64
|
+
featureName: {
|
|
65
|
+
type: String,
|
|
66
|
+
},
|
|
67
|
+
modules: [
|
|
68
|
+
{
|
|
69
|
+
name: {
|
|
70
|
+
type: String,
|
|
71
|
+
},
|
|
72
|
+
isAdd: {
|
|
73
|
+
type: Boolean,
|
|
74
|
+
},
|
|
75
|
+
isEdit: {
|
|
76
|
+
type: Boolean,
|
|
77
|
+
},
|
|
78
|
+
isDelete: {
|
|
79
|
+
type: Boolean,
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
],
|
|
83
|
+
},
|
|
84
|
+
],
|
|
62
85
|
userType:{
|
|
63
86
|
type: String,
|
|
64
87
|
enum:['tango','client','lead']
|