tango-api-schema 2.0.152 → 2.0.154

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.
Files changed (39) hide show
  1. package/index.js +76 -76
  2. package/package.json +27 -27
  3. package/schema/applicationDefault.model.js +24 -24
  4. package/schema/assignAudit.model.js +55 -55
  5. package/schema/auditLogs.model.js +72 -72
  6. package/schema/auditStoreData.model.js +54 -54
  7. package/schema/authentication.model.js +27 -27
  8. package/schema/basePricing.model.js +29 -29
  9. package/schema/billing.model.js +99 -99
  10. package/schema/camera.model.js +146 -146
  11. package/schema/client.model.js +479 -479
  12. package/schema/clientRequest.model.js +40 -40
  13. package/schema/countryCodes.model.js +28 -28
  14. package/schema/dailyPricing.model.js +88 -88
  15. package/schema/edgeAppVersion.model.js +33 -33
  16. package/schema/edgeappAuth.model.js +32 -32
  17. package/schema/externalParameter.model.js +202 -202
  18. package/schema/fitting.model.js +52 -52
  19. package/schema/group.model.js +36 -36
  20. package/schema/infraReason.model.js +44 -44
  21. package/schema/internalAuth.model.js +36 -36
  22. package/schema/invoice.model.js +106 -106
  23. package/schema/ipLogs.model.js +39 -39
  24. package/schema/lead.model.js +75 -75
  25. package/schema/matLog.model.js +26 -26
  26. package/schema/otp.model.js +27 -27
  27. package/schema/paymentAccount.model.js +60 -60
  28. package/schema/quality.model.js +57 -57
  29. package/schema/report.model.js +30 -30
  30. package/schema/standaredRole.model.js +56 -56
  31. package/schema/store.model.js +318 -314
  32. package/schema/storeAudit.model.js +61 -61
  33. package/schema/tagging.model.js +38 -38
  34. package/schema/tangoTicket.model.js +210 -210
  35. package/schema/transaction.model.js +54 -51
  36. package/schema/user.model.js +95 -95
  37. package/schema/userAssignedStore.model.js +41 -41
  38. package/schema/userAudit.model.js +76 -76
  39. package/schema/workstation.model.js +77 -77
@@ -1,52 +1,55 @@
1
- import mongoose from 'mongoose';
2
-
3
- const transactionSchema = new mongoose.Schema(
4
- {
5
- orderId: {
6
- type: String
7
- },
8
- paymentId: {
9
- type: String
10
- },
11
- debtType: {
12
- type: String,
13
- enum: [ 'wallet', 'razor' ],
14
- },
15
- billingDate: {
16
- type: Date
17
- },
18
- invoice: {
19
- type: String
20
- },
21
- groupName: {
22
- type: String
23
- },
24
- groupId: {
25
- type: mongoose.Types.ObjectId
26
- },
27
- amount: {
28
- type: Number
29
- },
30
- currency: {
31
- type: String,
32
- enum: [ 'dollar', 'inr' ],
33
- },
34
- transactionType: {
35
- type: String,
36
- enum: [ 'credit', 'debt' ],
37
- },
38
- balanceCredit: {
39
- type: Number
40
- },
41
- balanceCreditCurrency: {
42
- type: String,
43
- enum: [ 'dollar', 'inr' ],
44
- },
45
- }, {
46
- strict: true,
47
- versionKey: false,
48
- timestamps: true,
49
- }
50
- )
51
-
1
+ import mongoose from 'mongoose';
2
+
3
+ const transactionSchema = new mongoose.Schema(
4
+ {
5
+ clientId: {
6
+ type: String
7
+ },
8
+ orderId: {
9
+ type: String
10
+ },
11
+ paymentId: {
12
+ type: String
13
+ },
14
+ debtType: {
15
+ type: String,
16
+ enum: [ 'wallet', 'razor' ],
17
+ },
18
+ billingDate: {
19
+ type: Date
20
+ },
21
+ invoice: {
22
+ type: String
23
+ },
24
+ groupName: {
25
+ type: String
26
+ },
27
+ groupId: {
28
+ type: mongoose.Types.ObjectId
29
+ },
30
+ amount: {
31
+ type: Number
32
+ },
33
+ currency: {
34
+ type: String,
35
+ enum: [ 'dollar', 'inr' ],
36
+ },
37
+ transactionType: {
38
+ type: String,
39
+ enum: [ 'credit', 'debt' ],
40
+ },
41
+ balanceCredit: {
42
+ type: Number
43
+ },
44
+ balanceCreditCurrency: {
45
+ type: String,
46
+ enum: [ 'dollar', 'inr' ],
47
+ },
48
+ }, {
49
+ strict: true,
50
+ versionKey: false,
51
+ timestamps: true,
52
+ }
53
+ )
54
+
52
55
  export default mongoose.model('transaction', transactionSchema);
@@ -1,95 +1,95 @@
1
- import mongoose from 'mongoose';
2
- import mongooseUniqueValidator from 'mongoose-unique-validator';
3
-
4
- const user = new mongoose.Schema(
5
- {
6
- userName: {
7
- type: String,
8
- },
9
- email: {
10
- type: String,
11
- required: true,
12
- unique: true,
13
- },
14
- userProfile:{
15
- type:String
16
- },
17
- countryCode: {
18
- type: String,
19
- },
20
- mobileNumber: {
21
- type: String,
22
- required: true,
23
- },
24
- clientId: {
25
- type: String,
26
- },
27
- role: {
28
- type: String,
29
- enum: [ 'superadmin', 'admin', 'user' ],
30
- default: 'user',
31
- },
32
- isActive: {
33
- type: Boolean,
34
- default: true,
35
- },
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
- ],
62
- userType:{
63
- type: String,
64
- enum:['tango','client','lead']
65
- },
66
- password: {
67
- type: String
68
- },
69
- refreshToken:{
70
- type: String
71
- },
72
- twoFactorAuthentication : {
73
- code: {
74
- type: String
75
- },
76
- isEnable : {
77
- type: Boolean
78
- }
79
- },
80
- emailAlert: {
81
- infra: {
82
- type: Boolean,
83
- default: false
84
- }
85
- },
86
- },
87
- {
88
- strict: true,
89
- versionKey: false,
90
- timestamps: true,
91
- },
92
- );
93
-
94
- user.plugin( mongooseUniqueValidator );
95
- export default mongoose.model( 'user', user );
1
+ import mongoose from 'mongoose';
2
+ import mongooseUniqueValidator from 'mongoose-unique-validator';
3
+
4
+ const user = new mongoose.Schema(
5
+ {
6
+ userName: {
7
+ type: String,
8
+ },
9
+ email: {
10
+ type: String,
11
+ required: true,
12
+ unique: true,
13
+ },
14
+ userProfile:{
15
+ type:String
16
+ },
17
+ countryCode: {
18
+ type: String,
19
+ },
20
+ mobileNumber: {
21
+ type: String,
22
+ required: true,
23
+ },
24
+ clientId: {
25
+ type: String,
26
+ },
27
+ role: {
28
+ type: String,
29
+ enum: [ 'superadmin', 'admin', 'user' ],
30
+ default: 'user',
31
+ },
32
+ isActive: {
33
+ type: Boolean,
34
+ default: true,
35
+ },
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
+ ],
62
+ userType:{
63
+ type: String,
64
+ enum:['tango','client','lead']
65
+ },
66
+ password: {
67
+ type: String
68
+ },
69
+ refreshToken:{
70
+ type: String
71
+ },
72
+ twoFactorAuthentication : {
73
+ code: {
74
+ type: String
75
+ },
76
+ isEnable : {
77
+ type: Boolean
78
+ }
79
+ },
80
+ emailAlert: {
81
+ infra: {
82
+ type: Boolean,
83
+ default: false
84
+ }
85
+ },
86
+ },
87
+ {
88
+ strict: true,
89
+ versionKey: false,
90
+ timestamps: true,
91
+ },
92
+ );
93
+
94
+ user.plugin( mongooseUniqueValidator );
95
+ export default mongoose.model( 'user', user );
@@ -1,41 +1,41 @@
1
- import mongoose from 'mongoose';
2
-
3
-
4
- const userAssigned = new mongoose.Schema(
5
- {
6
- userEmail: {
7
- type: String,
8
- required: true,
9
- },
10
- clientId:{
11
- type: String
12
- },
13
- assignedType: {
14
- type: String,
15
- enum: [ 'store', 'group', 'client'],
16
- },
17
- assignedValue: {
18
- type: String
19
- },
20
- userType:{
21
- type: String,
22
- enum:['tango','client']
23
- },
24
- tangoUserType: {
25
- type: String,
26
- enum: ['user', 'csm'],
27
- default: 'user'
28
- },
29
- isClientApproved: {
30
- type: Boolean,
31
- default: false
32
- },
33
- },
34
- {
35
- strict: true,
36
- versionKey: false,
37
- timestamps: true,
38
- },
39
- );
40
-
41
- export default mongoose.model( 'userAssignedStore', userAssigned ,'userAssignedStore');
1
+ import mongoose from 'mongoose';
2
+
3
+
4
+ const userAssigned = new mongoose.Schema(
5
+ {
6
+ userEmail: {
7
+ type: String,
8
+ required: true,
9
+ },
10
+ clientId:{
11
+ type: String
12
+ },
13
+ assignedType: {
14
+ type: String,
15
+ enum: [ 'store', 'group', 'client'],
16
+ },
17
+ assignedValue: {
18
+ type: String
19
+ },
20
+ userType:{
21
+ type: String,
22
+ enum:['tango','client']
23
+ },
24
+ tangoUserType: {
25
+ type: String,
26
+ enum: ['user', 'csm'],
27
+ default: 'user'
28
+ },
29
+ isClientApproved: {
30
+ type: Boolean,
31
+ default: false
32
+ },
33
+ },
34
+ {
35
+ strict: true,
36
+ versionKey: false,
37
+ timestamps: true,
38
+ },
39
+ );
40
+
41
+ export default mongoose.model( 'userAssignedStore', userAssigned ,'userAssignedStore');
@@ -1,76 +1,76 @@
1
- /**
2
- * @name api_audit
3
- */
4
-
5
- // NPM Modules
6
- import mongoose from 'mongoose';
7
-
8
- // Schema
9
- const userAuditSchem = new mongoose.Schema( {
10
- userId: {
11
- type: mongoose.Schema.Types.ObjectId,
12
- },
13
- clientId: {
14
- type: String,
15
- },
16
- storeId: {
17
- type: String,
18
- },
19
- zoneName:{
20
- type: String,
21
- },
22
- moduleType:{
23
- type: String,
24
- enum: [ 'traffic', 'zone' ],
25
- },
26
- auditType: {
27
- type: String,
28
- },
29
- fileDate: {
30
- type: String,
31
- },
32
- fileDateISO: {
33
- type: Date,
34
- },
35
- queueName: {
36
- type: String,
37
- },
38
- isDraft: {
39
- type: Boolean,
40
- default: false,
41
- },
42
- auditStatus: {
43
- type: String,
44
- enum: [ 'inprogress', 'drafted', 'completed', 'skipped' ],
45
- },
46
- beforeCount: {
47
- type: Number,
48
- },
49
- afterCount: {
50
- type: Number,
51
- },
52
- startTime: {
53
- type: Date,
54
- },
55
- endTime: {
56
- type: Date,
57
- },
58
- timeSpent: {
59
- type: Number,
60
- default: 0,
61
- },
62
- dueHour: {
63
- type: String
64
- },
65
- userCommands: {
66
- type: String,
67
- },
68
- },
69
- {
70
- timestamps: true,
71
- strict: true,
72
- versionKey: false,
73
- } );
74
-
75
-
76
- export default mongoose.model( 'userAudit', userAuditSchem, 'userAudit' );
1
+ /**
2
+ * @name api_audit
3
+ */
4
+
5
+ // NPM Modules
6
+ import mongoose from 'mongoose';
7
+
8
+ // Schema
9
+ const userAuditSchem = new mongoose.Schema( {
10
+ userId: {
11
+ type: mongoose.Schema.Types.ObjectId,
12
+ },
13
+ clientId: {
14
+ type: String,
15
+ },
16
+ storeId: {
17
+ type: String,
18
+ },
19
+ zoneName:{
20
+ type: String,
21
+ },
22
+ moduleType:{
23
+ type: String,
24
+ enum: [ 'traffic', 'zone' ],
25
+ },
26
+ auditType: {
27
+ type: String,
28
+ },
29
+ fileDate: {
30
+ type: String,
31
+ },
32
+ fileDateISO: {
33
+ type: Date,
34
+ },
35
+ queueName: {
36
+ type: String,
37
+ },
38
+ isDraft: {
39
+ type: Boolean,
40
+ default: false,
41
+ },
42
+ auditStatus: {
43
+ type: String,
44
+ enum: [ 'inprogress', 'drafted', 'completed', 'skipped' ],
45
+ },
46
+ beforeCount: {
47
+ type: Number,
48
+ },
49
+ afterCount: {
50
+ type: Number,
51
+ },
52
+ startTime: {
53
+ type: Date,
54
+ },
55
+ endTime: {
56
+ type: Date,
57
+ },
58
+ timeSpent: {
59
+ type: Number,
60
+ default: 0,
61
+ },
62
+ dueHour: {
63
+ type: String
64
+ },
65
+ userCommands: {
66
+ type: String,
67
+ },
68
+ },
69
+ {
70
+ timestamps: true,
71
+ strict: true,
72
+ versionKey: false,
73
+ } );
74
+
75
+
76
+ export default mongoose.model( 'userAudit', userAuditSchem, 'userAudit' );
@@ -1,77 +1,77 @@
1
- import { Schema, model } from "mongoose";
2
- import mongooseUniqueValidator from "mongoose-unique-validator";
3
- const workStationModel = new Schema(
4
- {
5
- workStationId: {
6
- type: String,
7
- trim: true,
8
- required: true,
9
- unique: true,
10
- },
11
- appId: {
12
- type: String,
13
- trim: true,
14
- required: true,
15
- unique: true,
16
- },
17
- ip: {
18
- type: String,
19
- require: true,
20
- },
21
- macAddress: {
22
- type: String,
23
- require: true,
24
- },
25
- serverType: {
26
- type: Boolean,
27
- default: false,
28
- },
29
- active: {
30
- type: Boolean,
31
- default: true,
32
- },
33
- updateAppVersion: {
34
- type: String,
35
- trim: true,
36
- },
37
- appVersion: {
38
- type: String,
39
- trim: true,
40
- },
41
- architecture: {
42
- type: String,
43
- trim: true,
44
- enum: [ 'x32', 'x64' ],
45
- },
46
- triggerProcessId:{
47
- type: String,
48
- trim: true,
49
- },
50
- isRestartRequired:{
51
- type: Boolean,
52
- default: false,
53
- },
54
- deleteInterval:{
55
- type: Number,
56
- trim: true,
57
- },
58
- deleteExe:{
59
- type: Boolean,
60
- default: false,
61
- },
62
- isSocketEnable:{
63
- type: Boolean,
64
- default: false,
65
- },
66
- },
67
- {
68
- strict: true,
69
- versionKey: false,
70
- timestamps: true,
71
- }
72
- );
73
-
74
- workStationModel.index({ workStationId: 1, appId: 1 });
75
- workStationModel.plugin(mongooseUniqueValidator);
76
-
77
- export default model("workstation", workStationModel);
1
+ import { Schema, model } from "mongoose";
2
+ import mongooseUniqueValidator from "mongoose-unique-validator";
3
+ const workStationModel = new Schema(
4
+ {
5
+ workStationId: {
6
+ type: String,
7
+ trim: true,
8
+ required: true,
9
+ unique: true,
10
+ },
11
+ appId: {
12
+ type: String,
13
+ trim: true,
14
+ required: true,
15
+ unique: true,
16
+ },
17
+ ip: {
18
+ type: String,
19
+ require: true,
20
+ },
21
+ macAddress: {
22
+ type: String,
23
+ require: true,
24
+ },
25
+ serverType: {
26
+ type: Boolean,
27
+ default: false,
28
+ },
29
+ active: {
30
+ type: Boolean,
31
+ default: true,
32
+ },
33
+ updateAppVersion: {
34
+ type: String,
35
+ trim: true,
36
+ },
37
+ appVersion: {
38
+ type: String,
39
+ trim: true,
40
+ },
41
+ architecture: {
42
+ type: String,
43
+ trim: true,
44
+ enum: [ 'x32', 'x64' ],
45
+ },
46
+ triggerProcessId:{
47
+ type: String,
48
+ trim: true,
49
+ },
50
+ isRestartRequired:{
51
+ type: Boolean,
52
+ default: false,
53
+ },
54
+ deleteInterval:{
55
+ type: Number,
56
+ trim: true,
57
+ },
58
+ deleteExe:{
59
+ type: Boolean,
60
+ default: false,
61
+ },
62
+ isSocketEnable:{
63
+ type: Boolean,
64
+ default: false,
65
+ },
66
+ },
67
+ {
68
+ strict: true,
69
+ versionKey: false,
70
+ timestamps: true,
71
+ }
72
+ );
73
+
74
+ workStationModel.index({ workStationId: 1, appId: 1 });
75
+ workStationModel.plugin(mongooseUniqueValidator);
76
+
77
+ export default model("workstation", workStationModel);