tango-api-schema 1.0.38 → 1.0.40

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 CHANGED
@@ -11,6 +11,7 @@ import applicationDefaultModel from "./schema/applicationDefault.model.js";
11
11
  import userModel from "./schema/user.model.js";
12
12
  import userRoleModel from "./schema/userRole.model.js";
13
13
  import edgeappVersionModel from "./schema/edgeappVersion.model.js";
14
+ import nobClientHourlyModel from "./schema/nobClientHourly.model.js";
14
15
 
15
16
  export default {
16
17
  clientModel,
@@ -25,5 +26,6 @@ export default {
25
26
  applicationDefaultModel,
26
27
  userModel,
27
28
  userRoleModel,
28
- edgeappVersionModel
29
+ edgeappVersionModel,
30
+ nobClientHourlyModel
29
31
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tango-api-schema",
3
- "version": "1.0.38",
3
+ "version": "1.0.40",
4
4
  "description": "tangoEye model schema",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -28,6 +28,10 @@ const clientSchema = new mongoose.Schema(
28
28
  default: true,
29
29
  },
30
30
  profileDetail: {
31
+ image: {
32
+ type: String,
33
+ trim: true,
34
+ },
31
35
  registeredCompanyName: {
32
36
  type: String,
33
37
  trim: true,
@@ -106,6 +110,14 @@ const clientSchema = new mongoose.Schema(
106
110
  trim: true,
107
111
  default: "trial",
108
112
  },
113
+ assignedUsers: {
114
+ csm: {
115
+ type: Object,
116
+ },
117
+ ops: {
118
+ type: Array,
119
+ },
120
+ },
109
121
  reportConfigs: {
110
122
  report: {
111
123
  type: Boolean,
@@ -113,7 +125,7 @@ const clientSchema = new mongoose.Schema(
113
125
  },
114
126
  reportName: {
115
127
  type: String,
116
- required: true,
128
+ default: "",
117
129
  },
118
130
  },
119
131
  auditConfigs: {
@@ -134,14 +146,14 @@ const clientSchema = new mongoose.Schema(
134
146
  default: "",
135
147
  },
136
148
  ratio: {
137
- type:mongoose.Schema.Types.Number,
149
+ type: mongoose.Schema.Types.Number,
138
150
  default: 0.75,
139
151
  },
140
152
  },
141
153
  ticketConfigs: {
142
154
  liveTickets: {
143
155
  type: Boolean,
144
- default: false,
156
+ default: true,
145
157
  },
146
158
  infraTickets: {
147
159
  // infratickets needs to create for a day t-1
@@ -178,6 +190,11 @@ const clientSchema = new mongoose.Schema(
178
190
  type: Number,
179
191
  },
180
192
  },
193
+ store_added_status: {
194
+ // if it is true after add a store against brand
195
+ type: Boolean,
196
+ default: false,
197
+ },
181
198
  },
182
199
  {
183
200
  strict: true,
@@ -0,0 +1,43 @@
1
+ import mongoose from 'mongoose';
2
+
3
+ const nobSchema=new mongoose.Schema( {
4
+
5
+ client: { // client_Id changed to clientId
6
+ type: mongoose.Schema.Types.ObjectId,
7
+ ref: 'Brand',
8
+ },
9
+ clientId: {
10
+ type: String,
11
+ trim: true,
12
+ },
13
+ storeId: {
14
+ type: String,
15
+ trim: true,
16
+ },
17
+ nobDate: {
18
+ type: Date,
19
+ required: true,
20
+ },
21
+ store: {
22
+ type: mongoose.Schema.Types.ObjectId,
23
+ ref: 'Store',
24
+ },
25
+ nobCount: {
26
+ type: Number,
27
+ trim: true,
28
+ },
29
+ nobHour: {
30
+ type: Number,
31
+ trim: true,
32
+ },
33
+ nobAmount: {
34
+ type: mongoose.Schema.Types.Decimal128,
35
+ //default: '0.0',
36
+ },
37
+ }, {
38
+ strict: true,
39
+ versionKey: false,
40
+ timestamps: true,
41
+ } );
42
+
43
+ export default mongoose.model( 'nobBillingHourly', nobSchema, 'nobBillingHourly' );
@@ -9,230 +9,230 @@ import mongoose from "mongoose";
9
9
  // Schema
10
10
  const collection = new mongoose.Schema(
11
11
  {
12
- //////////////////////
13
- admin: {
14
- type: mongoose.Schema.Types.ObjectId,
15
- ref: "User",
16
- },
17
- client_id: {
18
- type: String,
19
- trim: true,
20
- },
21
- id: {
22
- type: String,
23
- trim: true,
24
- required: true,
25
- unique: true,
26
- },
27
- reference_code: {
28
- type: String,
29
- trim: true,
30
- },
12
+ //////////////////////
13
+ admin: {
14
+ type: mongoose.Schema.Types.ObjectId,
15
+ ref: "User",
16
+ },
17
+ client_id: {
18
+ type: String,
19
+ trim: true,
20
+ },
21
+ id: {
22
+ type: String,
23
+ trim: true,
24
+ required: true,
25
+ unique: true,
26
+ },
27
+ reference_code: {
28
+ type: String,
29
+ trim: true,
30
+ },
31
+ name: {
32
+ type: String,
33
+ trim: true,
34
+ required: true,
35
+ },
36
+ location: {
37
+ type: String,
38
+ trim: true,
39
+ },
40
+ country: {
41
+ type: String,
42
+ trim: true,
43
+ },
44
+ state: {
45
+ type: String,
46
+ trim: true,
47
+ },
48
+ city: {
49
+ type: String,
50
+ trim: true,
51
+ },
52
+ pincode: {
53
+ type: String,
54
+ trim: true,
55
+ },
56
+ timezone: {
57
+ type: String,
58
+ required: false,
59
+ default: "Asia/Kolkata",
60
+ },
61
+ country_code: {
62
+ type: String,
63
+ trim: true,
64
+ required: true,
65
+ default: "IN",
66
+ },
67
+ latitude: {
68
+ type: Number,
69
+ trim: true,
70
+ required: false,
71
+ default: 0.0,
72
+ },
73
+ longitude: {
74
+ type: Number,
75
+ trim: true,
76
+ required: false,
77
+ default: 0.0,
78
+ },
79
+ spoc: {
31
80
  name: {
32
81
  type: String,
33
82
  trim: true,
34
83
  required: true,
35
84
  },
36
- location: {
37
- type: String,
38
- trim: true,
39
- },
40
- country: {
41
- type: String,
42
- trim: true,
43
- },
44
- state: {
45
- type: String,
46
- trim: true,
47
- },
48
- city: {
49
- type: String,
50
- trim: true,
51
- },
52
- pincode: {
53
- type: String,
54
- trim: true,
55
- },
56
- timezone: {
57
- type: String,
58
- required: false,
59
- default: "Asia/Kolkata",
60
- },
61
- country_code: {
85
+ email: {
62
86
  type: String,
63
87
  trim: true,
64
88
  required: true,
65
- default: "IN",
66
89
  },
67
- latitude: {
68
- type: Number,
69
- trim: true,
70
- required: false,
71
- default: 0.0,
72
- },
73
- longitude: {
74
- type: Number,
75
- trim: true,
76
- required: false,
77
- default: 0.0,
78
- },
79
- spoc: {
80
- name: {
81
- type: String,
82
- trim: true,
83
- required: true,
84
- },
85
- email: {
86
- type: String,
87
- trim: true,
88
- required: true,
89
- },
90
- contact: {
91
- type: String,
92
- trim: true,
93
- required: true,
94
- },
95
- },
96
- appId: {
90
+ contact: {
97
91
  type: String,
98
92
  trim: true,
99
93
  required: true,
100
- unique: true,
101
- },
102
- appVersion: {
103
- type: String,
104
- trim: true,
105
- },
106
- architecture: {
107
- type:String,
108
- trim: true,
109
- enum: ['x32','x64'],
110
94
  },
111
- paired: {
112
- type: Boolean,
113
- default: false,
114
- },
115
- configured: {
95
+ },
96
+ appId: {
97
+ type: String,
98
+ trim: true,
99
+ required: true,
100
+ unique: true,
101
+ },
102
+ appVersion: {
103
+ type: String,
104
+ trim: true,
105
+ },
106
+ architecture: {
107
+ type:String,
108
+ trim: true,
109
+ enum: ['x32','x64'],
110
+ },
111
+ paired: {
112
+ type: Boolean,
113
+ default: false,
114
+ },
115
+ configured: {
116
+ type: Boolean,
117
+ default: false,
118
+ },
119
+ storeType: {
120
+ type: String,
121
+ trim: true,
122
+ },
123
+ hibernet: {
124
+ enabled: {
116
125
  type: Boolean,
117
- default: false,
118
126
  },
119
- storeType: {
127
+ startTime: {
120
128
  type: String,
121
129
  trim: true,
122
130
  },
123
- hibernet: {
124
- enabled: {
125
- type: Boolean,
126
- },
127
- startTime: {
128
- type: String,
129
- trim: true,
130
- },
131
- endTime: {
132
- type: String,
133
- trim: true,
134
- },
135
- },
136
- camera: [
137
- {
138
- type: mongoose.Schema.Types.ObjectId,
139
- ref: "Camera",
140
- },
141
- ],
142
- brandId: {
143
- type: mongoose.Schema.Types.ObjectId,
144
- ref: "Brand",
145
- },
146
- client_id: {
147
- type: String,
148
- },
149
- triggerProcessId: {
150
- type: String,
151
- },
152
- isRestartRequired: {
153
- type: Boolean,
154
- default: false,
155
- },
156
- edgeAppToken: {
157
- type: String,
158
- },
159
- active: {
160
- type: Boolean,
161
- default: true,
162
- },
163
- deployed_date: {
164
- type: Date,
165
- default: Date.now,
166
- },
167
- deployedBy: {
168
- type: String,
169
- },
170
- deployedStatus: {
171
- type: Boolean,
172
- default: false,
173
- },
174
- client_reference_id: {
175
- type: String,
176
- },
177
- client_crm_name: {
178
- type: String,
179
- },
180
- client_sap_code: {
181
- type: String,
182
- },
183
- updateAppVersion: {
131
+ endTime: {
184
132
  type: String,
185
133
  trim: true,
186
134
  },
187
- ticketpaused: {
188
- type: Date,
189
- default: Date.now,
190
- },
191
- lastticket_generated: {
192
- type: Date,
193
- },
194
- serverType: {
195
- type: Boolean,
196
- default: false,
197
- },
198
- isdeletedstore: {
199
- type: Boolean,
200
- default: false,
201
- },
202
- camera_count: {
203
- type: Number,
204
- default: 0,
135
+ },
136
+ camera: [
137
+ {
138
+ type: mongoose.Schema.Types.ObjectId,
139
+ ref: "Camera",
205
140
  },
206
- deleteInterval: {
207
- type: Number,
208
- default: 0,
141
+ ],
142
+ brandId: {
143
+ type: mongoose.Schema.Types.ObjectId,
144
+ ref: "Brand",
145
+ },
146
+ client_id: {
147
+ type: String,
148
+ },
149
+ triggerProcessId: {
150
+ type: String,
151
+ },
152
+ isRestartRequired: {
153
+ type: Boolean,
154
+ default: false,
155
+ },
156
+ edgeAppToken: {
157
+ type: String,
158
+ },
159
+ active: {
160
+ type: Boolean,
161
+ default: true,
162
+ },
163
+ deployed_date: {
164
+ type: Date,
165
+ default: Date.now,
166
+ },
167
+ deployedBy: {
168
+ type: String,
169
+ },
170
+ deployedStatus: {
171
+ type: Boolean,
172
+ default: false,
173
+ },
174
+ client_reference_id: {
175
+ type: String,
176
+ },
177
+ client_crm_name: {
178
+ type: String,
179
+ },
180
+ client_sap_code: {
181
+ type: String,
182
+ },
183
+ updateAppVersion: {
184
+ type: String,
185
+ trim: true,
186
+ },
187
+ ticketpaused: {
188
+ type: Date,
189
+ default: Date.now,
190
+ },
191
+ lastticket_generated: {
192
+ type: Date,
193
+ },
194
+ serverType: {
195
+ type: Boolean,
196
+ default: false,
197
+ },
198
+ isdeletedstore: {
199
+ type: Boolean,
200
+ default: false,
201
+ },
202
+ camera_count: {
203
+ type: Number,
204
+ default: 0,
205
+ },
206
+ deleteInterval: {
207
+ type: Number,
208
+ default: 0,
209
+ },
210
+ timeElapsed: {
211
+ type: Number,
212
+ trim: true,
213
+ default: 13,
214
+ },
215
+ subscribed_features: {},
216
+ boundarybox_config: {
217
+ time_series: {
218
+ type: Array,
219
+ default: [],
209
220
  },
210
- timeElapsed: {
221
+ time_interval: {
211
222
  type: Number,
212
- trim: true,
213
- default: 13,
214
- },
215
- subscribed_features: {},
216
- boundarybox_config: {
217
- time_series: {
218
- type: Array,
219
- default: [],
220
- },
221
- time_interval: {
222
- type: Number,
223
- default: 1,
224
- },
225
- },
226
- weekday_yolofilter: {
227
- type: mongoose.Schema.Types.ObjectId,
228
- ref: "yolo_filters",
229
- },
230
- weekend_yolofilter: {
231
- type: mongoose.Schema.Types.ObjectId,
232
- ref: "yolo_filters",
223
+ default: 1,
233
224
  },
225
+ },
226
+ weekday_yolofilter: {
227
+ type: mongoose.Schema.Types.ObjectId,
228
+ ref: "yolo_filters",
229
+ },
230
+ weekend_yolofilter: {
231
+ type: mongoose.Schema.Types.ObjectId,
232
+ ref: "yolo_filters",
233
+ },
234
234
 
235
- ////////////////
235
+ ////////////////
236
236
  id: {
237
237
  type: String,
238
238
  trim: true,
@@ -273,13 +273,13 @@ const collection = new mongoose.Schema(
273
273
  },
274
274
  timezone: {
275
275
  type: String,
276
- default: "Asia/Kolkata",
276
+ default: 'Asia/Kolkata',
277
277
  },
278
278
  country_code: {
279
279
  type: String,
280
280
  trim: true,
281
281
  required: true,
282
- default: "IN",
282
+ default: 'IN',
283
283
  },
284
284
  latitude: {
285
285
  type: Number,
@@ -296,10 +296,6 @@ const collection = new mongoose.Schema(
296
296
  },
297
297
  spocDetails: [
298
298
  {
299
- _id: {
300
- type: mongoose.Schema.Types.ObjectId,
301
- default: new mongoose.Types.ObjectId(),
302
- },
303
299
  name: {
304
300
  type: String,
305
301
  required: true,
@@ -335,7 +331,7 @@ const collection = new mongoose.Schema(
335
331
  },
336
332
  brandId: {
337
333
  type: mongoose.Schema.Types.ObjectId,
338
- ref: "Brand",
334
+ ref: 'Brand',
339
335
  },
340
336
  client_id: {
341
337
  type: String,
@@ -346,8 +342,8 @@ const collection = new mongoose.Schema(
346
342
  },
347
343
  dataProcess: {
348
344
  type: String,
349
- enum: ["hold", "suspend", "active", "deActive"],
350
- default: "active",
345
+ enum: [ 'hold', 'suspend', 'active', 'deActive' ],
346
+ default: 'active',
351
347
  },
352
348
  ticketConfigs: {
353
349
  hibernation: {
@@ -361,6 +357,24 @@ const collection = new mongoose.Schema(
361
357
  type: Date,
362
358
  },
363
359
  },
360
+ configuration: {
361
+ storeOpenTime: {
362
+ type: String,
363
+ required: true,
364
+ },
365
+ storeCloseTime: {
366
+ type: String,
367
+ required: true,
368
+ },
369
+ storeOpenTimeIST: {
370
+ type: String,
371
+ required: true,
372
+ },
373
+ storeCloseTimeIST: {
374
+ type: String,
375
+ required: true,
376
+ },
377
+ },
364
378
  storeConnectionId: {
365
379
  anydeskId: {
366
380
  type: String,
@@ -373,7 +387,7 @@ const collection = new mongoose.Schema(
373
387
  timeZone: {
374
388
  type: String,
375
389
  required: false,
376
- // default: "Asia/Kolkata",
390
+ // default: 'Asia/Kolkata',
377
391
  },
378
392
  firstFileDate: {
379
393
  type: Date,
@@ -384,7 +398,7 @@ const collection = new mongoose.Schema(
384
398
  },
385
399
  status: {
386
400
  type: Boolean,
387
- // default: true,
401
+ // default: true,
388
402
  },
389
403
  timeDownload: {
390
404
  type: Date,
@@ -404,7 +418,7 @@ const collection = new mongoose.Schema(
404
418
  architecture: {
405
419
  type: String,
406
420
  trim: true,
407
- enum: ["x32", "x64"],
421
+ enum: [ 'x32', 'x64' ],
408
422
  },
409
423
  updateAppVersion: {
410
424
  type: String,
@@ -412,24 +426,19 @@ const collection = new mongoose.Schema(
412
426
  },
413
427
  triggerProcessId: {
414
428
  type: String,
415
- // default: "",
416
429
  },
417
430
  isRestartRequired: {
418
431
  type: Boolean,
419
- // default: false,
420
432
  },
421
433
  serverType: {
422
434
  type: Boolean,
423
- //default: false,
424
435
  },
425
436
  deleteInterval: {
426
437
  type: Number,
427
- // default: 0,
428
438
  },
429
439
  timeElapsed: {
430
440
  type: Number,
431
441
  trim: true,
432
- // default: 13,
433
442
  },
434
443
  lastLoginAt: {
435
444
  type: Date,
@@ -440,7 +449,6 @@ const collection = new mongoose.Schema(
440
449
  },
441
450
  handShake: {
442
451
  type: Boolean,
443
- // default: false,
444
452
  },
445
453
  speedTest: {
446
454
  type: Object,
@@ -453,7 +461,6 @@ const collection = new mongoose.Schema(
453
461
  },
454
462
  preRequisite: {
455
463
  type: Boolean,
456
- // default: false,
457
464
  },
458
465
  deviceSpec: {
459
466
  type: Object,
@@ -466,7 +473,6 @@ const collection = new mongoose.Schema(
466
473
  },
467
474
  deleteExe: {
468
475
  type: Boolean,
469
- //default: false,
470
476
  },
471
477
  camDetails: {
472
478
  type: Object,
@@ -483,7 +489,6 @@ const collection = new mongoose.Schema(
483
489
  },
484
490
  installEdge: {
485
491
  type: Boolean,
486
- // default: false,
487
492
  },
488
493
  systemTimeZone: {
489
494
  type: String,
@@ -499,11 +504,11 @@ const collection = new mongoose.Schema(
499
504
  pipelineTrigger: {
500
505
  pipelineType: {
501
506
  type: String,
502
- default: 'v2_eod',
507
+ default: 'v1_live',
503
508
  },
504
509
  processLiveFeature: {
505
510
  type: Boolean,
506
- default: true,
511
+ default: false,
507
512
  },
508
513
  processEodFeature: {
509
514
  type: Boolean,
@@ -519,19 +524,19 @@ const collection = new mongoose.Schema(
519
524
  },
520
525
  reidQueue: {
521
526
  type: String,
522
- default:"live-pipeline-reid-test.fifo"
527
+ default:"eod-reid"
523
528
  },
524
529
  yoloQueue: {
525
530
  type: String,
526
- default: 'eod-yolo.fifo',
531
+ default: 'YOLO_LIVE',
527
532
  },
528
533
  version: {
529
534
  type: String,
530
- default: 'v2'
535
+ default: 'v1'
531
536
  },
532
537
  filterType:{
533
538
  type: String,
534
- default:'dynamic'
539
+ default:'default'
535
540
  }
536
541
  },
537
542
  featurePackage: {