tt-entities 0.0.42 → 0.0.43
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/dist/libs/tatayab-entities-library/entities/inventory.entity.d.ts +3 -0
- package/dist/libs/tatayab-entities-library/entities/inventory.entity.js +10 -0
- package/dist/libs/tatayab-entities-library/entities/inventory.entity.js.map +1 -1
- package/dist/libs/tatayab-entities-library/entities/store-inventory.entity.d.ts +4 -0
- package/dist/libs/tatayab-entities-library/entities/store-inventory.entity.js +8 -0
- package/dist/libs/tatayab-entities-library/entities/store-inventory.entity.js.map +1 -1
- package/dist/src/main.js +21 -2
- package/libs/tatayab-entities-library/src/entities/inventory.entity.ts +10 -0
- package/libs/tatayab-entities-library/src/entities/store-inventory.entity.ts +7 -0
- package/package.json +1 -1
|
@@ -2,6 +2,7 @@ import { Model } from 'sequelize-typescript';
|
|
|
2
2
|
import { InventoryStock } from './inventory-stock.entity';
|
|
3
3
|
import { Store } from './store.entity';
|
|
4
4
|
import { Status } from '../utils/enums/status';
|
|
5
|
+
import { Country } from './country.entity';
|
|
5
6
|
export declare class Inventory extends Model {
|
|
6
7
|
nameEn: string;
|
|
7
8
|
nameAr: string;
|
|
@@ -10,6 +11,8 @@ export declare class Inventory extends Model {
|
|
|
10
11
|
contactPhone?: string;
|
|
11
12
|
contactEmail?: string;
|
|
12
13
|
status: Status;
|
|
14
|
+
countryId: number;
|
|
15
|
+
country: Country;
|
|
13
16
|
stocks: InventoryStock[];
|
|
14
17
|
stores: Store[];
|
|
15
18
|
}
|
|
@@ -15,6 +15,7 @@ const inventory_stock_entity_1 = require("./inventory-stock.entity");
|
|
|
15
15
|
const store_inventory_entity_1 = require("./store-inventory.entity");
|
|
16
16
|
const store_entity_1 = require("./store.entity");
|
|
17
17
|
const status_1 = require("../utils/enums/status");
|
|
18
|
+
const country_entity_1 = require("./country.entity");
|
|
18
19
|
let Inventory = class Inventory extends sequelize_typescript_1.Model {
|
|
19
20
|
};
|
|
20
21
|
exports.Inventory = Inventory;
|
|
@@ -49,6 +50,15 @@ __decorate([
|
|
|
49
50
|
}),
|
|
50
51
|
__metadata("design:type", String)
|
|
51
52
|
], Inventory.prototype, "status", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
(0, sequelize_typescript_1.ForeignKey)(() => country_entity_1.Country),
|
|
55
|
+
(0, sequelize_typescript_1.Column)({ allowNull: true }),
|
|
56
|
+
__metadata("design:type", Number)
|
|
57
|
+
], Inventory.prototype, "countryId", void 0);
|
|
58
|
+
__decorate([
|
|
59
|
+
(0, sequelize_typescript_1.BelongsTo)(() => country_entity_1.Country),
|
|
60
|
+
__metadata("design:type", country_entity_1.Country)
|
|
61
|
+
], Inventory.prototype, "country", void 0);
|
|
52
62
|
__decorate([
|
|
53
63
|
(0, sequelize_typescript_1.HasMany)(() => inventory_stock_entity_1.InventoryStock),
|
|
54
64
|
__metadata("design:type", Array)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inventory.entity.js","sourceRoot":"","sources":["../../../../libs/tatayab-entities-library/src/entities/inventory.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+
|
|
1
|
+
{"version":3,"file":"inventory.entity.js","sourceRoot":"","sources":["../../../../libs/tatayab-entities-library/src/entities/inventory.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAS8B;AAC9B,qEAA0D;AAC1D,qEAA0D;AAC1D,iDAAuC;AACvC,kDAA+C;AAC/C,qDAA2C;AAGpC,IAAM,SAAS,GAAf,MAAM,SAAU,SAAQ,4BAAK;CAuCnC,CAAA;AAvCY,8BAAS;AAEZ;IADP,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;yCACN;AAGf;IADP,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;yCACN;AAGf;IADP,IAAA,6BAAM,EAAC,EAAE,IAAI,EAAE,+BAAQ,CAAC,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;;4CACtB;AAGnB;IADP,IAAA,6BAAM,EAAC,EAAE,IAAI,EAAE,+BAAQ,CAAC,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;;4CACtB;AAGnB;IADP,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;;+CACE;AAGtB;IADP,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;;+CACE;AAMtB;IAJP,IAAA,6BAAM,EAAC;QACN,IAAI,EAAE,+BAAQ,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,eAAM,CAAC,CAAC;QAC7C,YAAY,EAAE,eAAM,CAAC,MAAM;KAC5B,CAAC;;yCACqB;AAIvB;IAFC,IAAA,iCAAU,EAAC,GAAG,EAAE,CAAC,wBAAO,CAAC;IACzB,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;;4CACV;AAKlB;IADC,IAAA,gCAAS,EAAC,GAAG,EAAE,CAAC,wBAAO,CAAC;8BAChB,wBAAO;0CAAC;AAGT;IADP,IAAA,8BAAO,EAAC,GAAG,EAAE,CAAC,uCAAc,CAAC;;yCACG;AAGzB;IADP,IAAA,oCAAa,EAAC,GAAG,EAAE,CAAC,oBAAK,EAAE,GAAG,EAAE,CAAC,uCAAc,CAAC;;yCACzB;oBAtCb,SAAS;IADrB,4BAAK;GACO,SAAS,CAuCrB"}
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import { Model } from 'sequelize-typescript';
|
|
2
|
+
import { Store } from './store.entity';
|
|
3
|
+
import { Inventory } from './inventory.entity';
|
|
2
4
|
export declare class StoreInventory extends Model {
|
|
3
5
|
storeId: number;
|
|
4
6
|
inventoryId: number;
|
|
5
7
|
priority: number;
|
|
8
|
+
inventory: Inventory;
|
|
9
|
+
store: Store;
|
|
6
10
|
}
|
|
@@ -30,6 +30,14 @@ __decorate([
|
|
|
30
30
|
(0, sequelize_typescript_1.Column)({ defaultValue: 1 }),
|
|
31
31
|
__metadata("design:type", Number)
|
|
32
32
|
], StoreInventory.prototype, "priority", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, sequelize_typescript_1.BelongsTo)(() => inventory_entity_1.Inventory),
|
|
35
|
+
__metadata("design:type", inventory_entity_1.Inventory)
|
|
36
|
+
], StoreInventory.prototype, "inventory", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, sequelize_typescript_1.BelongsTo)(() => store_entity_1.Store),
|
|
39
|
+
__metadata("design:type", store_entity_1.Store)
|
|
40
|
+
], StoreInventory.prototype, "store", void 0);
|
|
33
41
|
exports.StoreInventory = StoreInventory = __decorate([
|
|
34
42
|
sequelize_typescript_1.Table
|
|
35
43
|
], StoreInventory);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store-inventory.entity.js","sourceRoot":"","sources":["../../../../libs/tatayab-entities-library/src/entities/store-inventory.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+
|
|
1
|
+
{"version":3,"file":"store-inventory.entity.js","sourceRoot":"","sources":["../../../../libs/tatayab-entities-library/src/entities/store-inventory.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAO8B;AAC9B,iDAAuC;AACvC,yDAA+C;AAGxC,IAAM,cAAc,GAApB,MAAM,cAAe,SAAQ,4BAAK;CAkBxC,CAAA;AAlBY,wCAAc;AAGjB;IAFP,IAAA,iCAAU,EAAC,GAAG,EAAE,CAAC,oBAAK,CAAC;IACvB,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;+CACL;AAIhB;IAFP,IAAA,iCAAU,EAAC,GAAG,EAAE,CAAC,4BAAS,CAAC;IAC3B,IAAA,6BAAM,EAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;mDACD;AAIpB;IADP,IAAA,6BAAM,EAAC,EAAE,YAAY,EAAE,CAAC,EAAE,CAAC;;gDACH;AAGzB;IADC,IAAA,gCAAS,EAAC,GAAG,EAAE,CAAC,4BAAS,CAAC;8BAChB,4BAAS;iDAAC;AAGrB;IADC,IAAA,gCAAS,EAAC,GAAG,EAAE,CAAC,oBAAK,CAAC;8BAChB,oBAAK;6CAAC;yBAjBF,cAAc;IAD1B,4BAAK;GACO,cAAc,CAkB1B"}
|