tango-api-schema 1.0.11 → 1.0.12

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
@@ -5,6 +5,8 @@ import clientModel from "./schema/client.model.js";
5
5
  import dailyAuditFilesModel from "./schema/dailyAuditFiles.model.js";
6
6
  import dailyAuditStoreFilesModel from "./schema/dailyAuditStoreFiles.model.js";
7
7
  import tokenModel from "./schema/token.model.js";
8
+ import nobModel from './schema/nob.model.js';
9
+ import nobClientModel from './schema/nobClient.model.js';
8
10
 
9
11
  export default {
10
12
  clientModel,
@@ -14,4 +16,6 @@ export default {
14
16
  dailyAuditFilesModel,
15
17
  dailyAuditStoreFilesModel,
16
18
  tokenModel,
19
+ nobModel,
20
+ nobClientModel
17
21
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tango-api-schema",
3
- "version": "1.0.11",
3
+ "version": "1.0.12",
4
4
  "description": "tangoEye model schema",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -0,0 +1,39 @@
1
+ import { Schema, model } from 'mongoose';
2
+
3
+ const nobSchema=new Schema( {
4
+
5
+ client: { // client_Id changed to clientId
6
+ type: 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: Schema.Types.ObjectId,
23
+ ref: 'Store',
24
+ },
25
+ nobCount: {
26
+ type: Number,
27
+ trim: true,
28
+ },
29
+ nobAmount: {
30
+ type: Schema.Types.Decimal128,
31
+ default: '0.0',
32
+ },
33
+ }, {
34
+ strict: true,
35
+ versionKey: false,
36
+ timestamps: true,
37
+ } );
38
+
39
+ export default model( 'nobBilling', nobSchema, 'nobBilling' );
@@ -0,0 +1,26 @@
1
+ /**
2
+ * @name api_stores_models_store
3
+ * @description Store Schema
4
+ */
5
+
6
+ // NPM Modules
7
+ import { Schema, model } from 'mongoose';
8
+
9
+ // Schema
10
+ const collection = new Schema(
11
+ {
12
+ source: {
13
+ type: Object,
14
+ trim: true,
15
+ },
16
+ },
17
+ {
18
+ timestamps: true,
19
+ versionKey: false,
20
+ strict: true,
21
+ },
22
+ );
23
+
24
+ // collection.plugin(uniqueValidator);
25
+
26
+ export default model( 'nobClient', collection, 'nobClient' );