@merkaly/api 0.3.4 → 0.3.6
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/abstract.repository.d.ts +3 -13
- package/dist/abstract.validator.d.ts +4 -1
- package/dist/account/address/index.js +1 -2
- package/dist/account/cart/index.js +1 -2
- package/dist/account/payment/index.js +1 -2
- package/dist/account/payment/payment.entity.d.ts +5 -4
- package/dist/account/payment/payment.validator.d.ts +12 -5
- package/dist/account/user/index.js +1 -2
- package/dist/account/user/user.validator.d.ts +4 -4
- package/dist/account/wishlist/index.js +1 -2
- package/dist/assets/asset/asset.entity.d.ts +0 -1
- package/dist/assets/asset/asset.enum.js +2 -6
- package/dist/assets/asset/index.js +1 -7
- package/dist/finance/invoice/index.d.ts +3 -0
- package/dist/finance/invoice/index.js +1 -0
- package/dist/finance/invoice/invoice.entity.d.ts +15 -0
- package/dist/finance/invoice/invoice.enum.d.ts +14 -0
- package/dist/finance/invoice/invoice.enum.js +16 -0
- package/dist/finance/invoice/invoice.validator.d.ts +21 -0
- package/dist/finance/payment/index.d.ts +4 -0
- package/dist/finance/payment/index.js +1 -0
- package/dist/finance/payment/payment.entity.d.ts +19 -0
- package/dist/{billing → finance}/payment/payment.enum.d.ts +7 -2
- package/dist/finance/payment/payment.enum.js +23 -0
- package/dist/finance/payment/payment.validator.d.ts +20 -0
- package/dist/finance/refund/index.d.ts +3 -0
- package/dist/finance/refund/index.js +1 -0
- package/dist/finance/refund/refund.entity.d.ts +12 -0
- package/dist/finance/refund/refund.enum.d.ts +16 -0
- package/dist/finance/refund/refund.enum.js +18 -0
- package/dist/finance/refund/refund.validator.d.ts +19 -0
- package/dist/finance/subscription/index.d.ts +3 -0
- package/dist/finance/subscription/index.js +1 -0
- package/dist/finance/subscription/subscription.entity.d.ts +15 -0
- package/dist/finance/subscription/subscription.enum.d.ts +15 -0
- package/dist/finance/subscription/subscription.enum.js +17 -0
- package/dist/finance/subscription/subscription.validator.d.ts +19 -0
- package/dist/finance/tax/index.d.ts +3 -0
- package/dist/finance/tax/index.js +1 -0
- package/dist/finance/tax/tax.entity.d.ts +10 -0
- package/dist/finance/tax/tax.enum.d.ts +8 -0
- package/dist/finance/tax/tax.enum.js +9 -0
- package/dist/finance/tax/tax.validator.d.ts +17 -0
- package/dist/index.js +1 -2
- package/dist/inventory/catalog/attribute/attribute.entity.d.ts +1 -3
- package/dist/inventory/catalog/attribute/attribute.validator.d.ts +5 -7
- package/dist/inventory/catalog/attribute/index.js +1 -2
- package/dist/inventory/catalog/brand/brand.validator.d.ts +4 -4
- package/dist/inventory/catalog/brand/index.js +1 -2
- package/dist/inventory/catalog/category/category.validator.d.ts +4 -4
- package/dist/inventory/catalog/category/index.js +1 -2
- package/dist/inventory/catalog/collection/collection.validator.d.ts +4 -4
- package/dist/inventory/catalog/collection/index.js +1 -2
- package/dist/inventory/catalog/product/index.js +1 -7
- package/dist/inventory/catalog/product/product.entity.d.ts +4 -3
- package/dist/inventory/catalog/product/product.status.enum.js +2 -6
- package/dist/inventory/catalog/product/product.validator.d.ts +9 -11
- package/dist/inventory/catalog/variant/index.d.ts +2 -0
- package/dist/inventory/catalog/variant/index.js +1 -0
- package/dist/inventory/catalog/variant/variant.entity.d.ts +19 -0
- package/dist/inventory/catalog/variant/variant.validator.d.ts +27 -0
- package/dist/inventory/configuration/label/index.js +1 -2
- package/dist/inventory/configuration/measurement/index.js +1 -2
- package/dist/inventory/configuration/measurement/measurement.validator.d.ts +4 -4
- package/dist/inventory/configuration/unit/index.js +1 -2
- package/dist/inventory/stock/transfer/index.js +1 -2
- package/dist/inventory/stock/transfer/transfer.validator.d.ts +5 -4
- package/dist/inventory/stock/warehouse/index.js +1 -2
- package/dist/inventory/stock/warehouse/warehouse.validator.d.ts +4 -4
- package/dist/order/purchase/item/index.js +1 -2
- package/dist/order/purchase/item/item.entity.d.ts +2 -0
- package/dist/order/purchase/item/item.validator.d.ts +1 -0
- package/dist/order/purchase/transaction/index.js +1 -7
- package/dist/order/purchase/transaction/transaction.entity.d.ts +1 -1
- package/dist/order/purchase/transaction/transaction.enum.js +2 -6
- package/dist/order/purchase/transaction/transaction.validator.d.ts +0 -2
- package/dist/order/purchase/vendor/index.js +1 -2
- package/dist/order/sale/address/index.js +1 -2
- package/dist/order/sale/customer/customer.entity.d.ts +2 -0
- package/dist/order/sale/customer/customer.enum.d.ts +4 -0
- package/dist/order/sale/customer/customer.enum.js +5 -0
- package/dist/order/sale/customer/customer.validator.d.ts +2 -0
- package/dist/order/sale/customer/index.d.ts +1 -0
- package/dist/order/sale/customer/index.js +1 -2
- package/dist/order/sale/item/index.js +1 -2
- package/dist/order/sale/item/item.entity.d.ts +7 -0
- package/dist/order/sale/item/item.validator.d.ts +2 -1
- package/dist/order/sale/payment/index.js +1 -2
- package/dist/order/sale/payment/payment.validator.d.ts +3 -12
- package/dist/order/sale/shipping/index.d.ts +4 -0
- package/dist/order/sale/shipping/index.js +1 -0
- package/dist/order/sale/shipping/shipping.entity.d.ts +18 -0
- package/dist/{logistic/shipment/shipment.enum.d.ts → order/sale/shipping/shipping.enum.d.ts} +2 -2
- package/dist/order/sale/shipping/shipping.enum.js +18 -0
- package/dist/{logistic/shipment/shipment.validator.d.ts → order/sale/shipping/shipping.validator.d.ts} +7 -7
- package/dist/order/sale/transaction/index.js +1 -7
- package/dist/order/sale/transaction/transaction.entity.d.ts +5 -5
- package/dist/order/sale/transaction/transaction.enum.js +2 -6
- package/dist/order/sale/transaction/transaction.validator.d.ts +11 -10
- package/dist/settings/organization/index.d.ts +3 -0
- package/dist/settings/organization/index.js +1 -0
- package/dist/settings/organization/organization.entity.d.ts +5 -0
- package/dist/settings/organization/organization.enum.d.ts +13 -0
- package/dist/settings/organization/organization.enum.js +14 -0
- package/dist/settings/organization/organization.validator.d.ts +13 -0
- package/package.json +26 -17
- package/dist/billing/payment/index.d.ts +0 -2
- package/dist/billing/payment/index.js +0 -7
- package/dist/billing/payment/payment.enum.js +0 -21
- package/dist/billing/payment/transaction.entity.d.ts +0 -15
- package/dist/billing/status/index.d.ts +0 -1
- package/dist/billing/status/index.js +0 -2
- package/dist/billing/status/status.entity.d.ts +0 -8
- package/dist/inventory/configuration/label/label.entity.d.ts +0 -7
- package/dist/inventory/configuration/label/label.validator.d.ts +0 -14
- package/dist/inventory/stock/backorder/backorder.entity.d.ts +0 -33
- package/dist/inventory/stock/backorder/backorder.validator.d.ts +0 -24
- package/dist/inventory/stock/backorder/index.d.ts +0 -2
- package/dist/inventory/stock/backorder/index.js +0 -2
- package/dist/logistic/carrier/carrier.entity.d.ts +0 -10
- package/dist/logistic/carrier/carrier.validator.d.ts +0 -17
- package/dist/logistic/carrier/index.d.ts +0 -2
- package/dist/logistic/carrier/index.js +0 -2
- package/dist/logistic/shipment/index.d.ts +0 -3
- package/dist/logistic/shipment/index.js +0 -7
- package/dist/logistic/shipment/shipment.entity.d.ts +0 -19
- package/dist/logistic/shipment/shipment.enum.js +0 -22
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { CatalogCategoryEntity } from './';
|
|
2
2
|
import { AbstractValidator, ReadValidator, SearchValidator } from '../../..';
|
|
3
|
-
export declare class
|
|
3
|
+
export declare class SearchCatalogCategoryValidator extends SearchValidator<CatalogCategoryEntity> {
|
|
4
4
|
}
|
|
5
|
-
export declare class
|
|
5
|
+
export declare class ReadCatalogCategoryValidator extends ReadValidator<CatalogCategoryEntity> {
|
|
6
6
|
}
|
|
7
|
-
export declare class
|
|
7
|
+
export declare class CreateCatalogCategoryValidator extends AbstractValidator {
|
|
8
8
|
name: string;
|
|
9
9
|
description: string;
|
|
10
10
|
}
|
|
11
|
-
export declare class
|
|
11
|
+
export declare class UpdateCatalogCategoryValidator extends CreateCatalogCategoryValidator {
|
|
12
12
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { CatalogCollectionEntity } from './';
|
|
2
2
|
import { AbstractValidator, ReadValidator, SearchValidator } from '../../..';
|
|
3
|
-
export declare class
|
|
3
|
+
export declare class SearchCatalogCollectionValidator extends SearchValidator<CatalogCollectionEntity> {
|
|
4
4
|
}
|
|
5
|
-
export declare class
|
|
5
|
+
export declare class ReadCatalogCollectionValidator extends ReadValidator<CatalogCollectionEntity> {
|
|
6
6
|
}
|
|
7
|
-
export declare class
|
|
7
|
+
export declare class CreateCatalogCollectionValidator extends AbstractValidator {
|
|
8
8
|
name: string;
|
|
9
9
|
description: string;
|
|
10
10
|
products: string[];
|
|
11
11
|
}
|
|
12
|
-
export declare class
|
|
12
|
+
export declare class UpdateCatalogCollectionValidator extends CreateCatalogCollectionValidator {
|
|
13
13
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
var product_status_enum_1 = require("./product.status.enum");
|
|
4
|
-
Object.keys(product_status_enum_1).forEach(function (key) {
|
|
5
|
-
if (key === "default" || key === "__esModule") return;
|
|
6
|
-
Object.defineProperty(exports, key, { enumerable: true, get: function () { return product_status_enum_1[key]; } });
|
|
7
|
-
});
|
|
1
|
+
export * from './product.status.enum.js';
|
|
@@ -5,6 +5,7 @@ import { AbstractEntity } from '../../..';
|
|
|
5
5
|
import { CatalogAttributeEntity } from '../attribute';
|
|
6
6
|
import type { CatalogBrandEntity } from '../brand';
|
|
7
7
|
import type { CatalogCategoryEntity } from '../category';
|
|
8
|
+
import type { CatalogVariantEntity } from '../variant';
|
|
8
9
|
import type { ConfigurationMeasurementEntity } from '../../configuration/measurement';
|
|
9
10
|
import type { MongoEntity } from '../../..';
|
|
10
11
|
export declare class CatalogProductEntity extends AbstractEntity {
|
|
@@ -16,8 +17,8 @@ export declare class CatalogProductEntity extends AbstractEntity {
|
|
|
16
17
|
category?: MongoEntity<CatalogCategoryEntity>;
|
|
17
18
|
brand?: MongoEntity<CatalogBrandEntity>;
|
|
18
19
|
attributes: {
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
type: MongoEntity<CatalogAttributeEntity>;
|
|
21
|
+
values: string[];
|
|
21
22
|
}[];
|
|
22
23
|
measure?: {
|
|
23
24
|
amount: number;
|
|
@@ -26,6 +27,6 @@ export declare class CatalogProductEntity extends AbstractEntity {
|
|
|
26
27
|
};
|
|
27
28
|
hashtags: string[];
|
|
28
29
|
status: CatalogProductStatus;
|
|
29
|
-
|
|
30
|
+
variants: MongoEntity<CatalogVariantEntity>[];
|
|
30
31
|
readonly wishlist?: AccountWishlistEntity[];
|
|
31
32
|
}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.CatalogProductStatus = void 0;
|
|
4
|
-
var CatalogProductStatus;
|
|
1
|
+
export var CatalogProductStatus;
|
|
5
2
|
(function (CatalogProductStatus) {
|
|
6
3
|
CatalogProductStatus["Draft"] = "draft";
|
|
7
4
|
CatalogProductStatus["Published"] = "published";
|
|
@@ -9,5 +6,4 @@ var CatalogProductStatus;
|
|
|
9
6
|
CatalogProductStatus["OutOfStock"] = "out_of_stock";
|
|
10
7
|
CatalogProductStatus["Discontinued"] = "discontinued";
|
|
11
8
|
CatalogProductStatus["ComingSoon"] = "coming_soon";
|
|
12
|
-
})(CatalogProductStatus || (
|
|
13
|
-
//# sourceMappingURL=product.status.enum.js.map
|
|
9
|
+
})(CatalogProductStatus || (CatalogProductStatus = {}));
|
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
import { CatalogProductEntity } from './';
|
|
2
2
|
import { CatalogProductStatus } from './';
|
|
3
3
|
import { AbstractValidator, ReadValidator, SearchValidator } from '../../..';
|
|
4
|
-
export declare class
|
|
4
|
+
export declare class SearchCatalogProductValidator extends SearchValidator<CatalogProductEntity> {
|
|
5
5
|
}
|
|
6
|
-
export declare class
|
|
6
|
+
export declare class ReadCatalogProductValidator extends ReadValidator<CatalogProductEntity> {
|
|
7
7
|
}
|
|
8
|
-
export declare class
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
required: boolean;
|
|
8
|
+
export declare class ProductAttributeValidator extends AbstractValidator {
|
|
9
|
+
type: string;
|
|
10
|
+
values: string[];
|
|
12
11
|
}
|
|
13
|
-
export declare class
|
|
12
|
+
export declare class CreateCatalogProductValidator extends AbstractValidator {
|
|
14
13
|
sku?: string;
|
|
15
14
|
name: string;
|
|
16
|
-
description
|
|
15
|
+
description?: string;
|
|
17
16
|
price: number;
|
|
18
17
|
measure?: {
|
|
19
18
|
amount: number;
|
|
@@ -21,14 +20,13 @@ export declare class CreateProductValidator extends AbstractValidator {
|
|
|
21
20
|
unit: string;
|
|
22
21
|
};
|
|
23
22
|
pictures: string[];
|
|
24
|
-
stock: number;
|
|
25
23
|
category?: string;
|
|
26
24
|
brand?: string;
|
|
27
25
|
hashtags: string[];
|
|
28
|
-
attributes:
|
|
26
|
+
attributes: ProductAttributeValidator[];
|
|
29
27
|
status: CatalogProductStatus;
|
|
30
28
|
}
|
|
31
|
-
export declare class
|
|
29
|
+
export declare class UpdateCatalogProductValidator extends CreateCatalogProductValidator {
|
|
32
30
|
name: string;
|
|
33
31
|
price: number;
|
|
34
32
|
measure: {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { AssetEntity } from '../../../assets/asset';
|
|
2
|
+
import { AbstractEntity } from '../../..';
|
|
3
|
+
import type { CatalogAttributeEntity } from '../attribute';
|
|
4
|
+
import type { CatalogProductEntity } from '../product';
|
|
5
|
+
import type { MongoEntity } from '../../..';
|
|
6
|
+
export declare class CatalogVariantEntity extends AbstractEntity {
|
|
7
|
+
product?: MongoEntity<CatalogProductEntity>;
|
|
8
|
+
sku: string;
|
|
9
|
+
price: number;
|
|
10
|
+
stock: number;
|
|
11
|
+
options: {
|
|
12
|
+
type: MongoEntity<CatalogAttributeEntity>;
|
|
13
|
+
value: string;
|
|
14
|
+
}[];
|
|
15
|
+
active: boolean;
|
|
16
|
+
barcode?: string;
|
|
17
|
+
pictures: MongoEntity<AssetEntity>[];
|
|
18
|
+
readonly finalPrice: number;
|
|
19
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { CatalogVariantEntity } from './';
|
|
2
|
+
import { AbstractValidator, ReadValidator, SearchValidator } from '../../..';
|
|
3
|
+
export declare class VariantOptionValidator {
|
|
4
|
+
type: string;
|
|
5
|
+
value: string;
|
|
6
|
+
}
|
|
7
|
+
export declare class SearchCatalogVariantValidator extends SearchValidator<CatalogVariantEntity> {
|
|
8
|
+
}
|
|
9
|
+
export declare class ReadCatalogVariantValidator extends ReadValidator<CatalogVariantEntity> {
|
|
10
|
+
}
|
|
11
|
+
export declare class CreateCatalogVariantValidator extends AbstractValidator {
|
|
12
|
+
product?: string;
|
|
13
|
+
sku: string;
|
|
14
|
+
price?: number;
|
|
15
|
+
stock?: number;
|
|
16
|
+
options?: VariantOptionValidator[];
|
|
17
|
+
active?: boolean;
|
|
18
|
+
barcode?: string;
|
|
19
|
+
}
|
|
20
|
+
export declare class UpdateCatalogVariantValidator extends AbstractValidator {
|
|
21
|
+
sku?: string;
|
|
22
|
+
price?: number;
|
|
23
|
+
stock?: number;
|
|
24
|
+
options?: VariantOptionValidator[];
|
|
25
|
+
active?: boolean;
|
|
26
|
+
barcode?: string;
|
|
27
|
+
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -7,15 +7,15 @@ export declare class ConfigurationUnitValidator extends AbstractValidator {
|
|
|
7
7
|
active?: boolean;
|
|
8
8
|
isBaseUnit?: boolean;
|
|
9
9
|
}
|
|
10
|
-
export declare class
|
|
10
|
+
export declare class SearchConfigurationMeasurementValidator extends SearchValidator<ConfigurationMeasurementEntity> {
|
|
11
11
|
}
|
|
12
|
-
export declare class
|
|
12
|
+
export declare class ReadConfigurationMeasurementValidator extends ReadValidator<ConfigurationMeasurementEntity> {
|
|
13
13
|
}
|
|
14
|
-
export declare class
|
|
14
|
+
export declare class CreateConfigurationMeasurementValidator extends AbstractValidator {
|
|
15
15
|
name: string;
|
|
16
16
|
description?: string;
|
|
17
17
|
active?: boolean;
|
|
18
18
|
units?: ConfigurationUnitValidator[];
|
|
19
19
|
}
|
|
20
|
-
export declare class
|
|
20
|
+
export declare class UpdateConfigurationMeasurementValidator extends CreateConfigurationMeasurementValidator {
|
|
21
21
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -5,11 +5,11 @@ export declare class StockTransferItemValidator {
|
|
|
5
5
|
quantity: number;
|
|
6
6
|
notes?: string;
|
|
7
7
|
}
|
|
8
|
-
export declare class
|
|
8
|
+
export declare class SearchStockTransferValidator extends SearchValidator<StockTransferEntity> {
|
|
9
9
|
}
|
|
10
|
-
export declare class
|
|
10
|
+
export declare class ReadStockTransferValidator extends ReadValidator<StockTransferEntity> {
|
|
11
11
|
}
|
|
12
|
-
export declare class
|
|
12
|
+
export declare class CreateStockTransferValidator extends AbstractValidator {
|
|
13
13
|
sourceWarehouse: string;
|
|
14
14
|
destinationWarehouse: string;
|
|
15
15
|
items: StockTransferItemValidator[];
|
|
@@ -17,9 +17,10 @@ export declare class CreateTransferValidator extends AbstractValidator {
|
|
|
17
17
|
requestedDate?: string;
|
|
18
18
|
user: string;
|
|
19
19
|
}
|
|
20
|
-
export declare class
|
|
20
|
+
export declare class UpdateStockTransferValidator extends AbstractValidator {
|
|
21
21
|
status?: TransferStatusEnum;
|
|
22
22
|
notes?: string;
|
|
23
23
|
shippedDate?: string;
|
|
24
24
|
receivedDate?: string;
|
|
25
|
+
items: StockTransferItemValidator[];
|
|
25
26
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -11,11 +11,11 @@ export declare class StockWarehouseAddressValidator {
|
|
|
11
11
|
latitude?: number;
|
|
12
12
|
longitude?: number;
|
|
13
13
|
}
|
|
14
|
-
export declare class
|
|
14
|
+
export declare class SearchStockWarehouseValidator extends SearchValidator<StockWarehouseEntity> {
|
|
15
15
|
}
|
|
16
|
-
export declare class
|
|
16
|
+
export declare class ReadStockWarehouseValidator extends ReadValidator<StockWarehouseEntity> {
|
|
17
17
|
}
|
|
18
|
-
export declare class
|
|
18
|
+
export declare class CreateStockWarehouseValidator extends AbstractValidator {
|
|
19
19
|
name: string;
|
|
20
20
|
code: string;
|
|
21
21
|
description?: string;
|
|
@@ -23,5 +23,5 @@ export declare class CreateWarehouseValidator extends AbstractValidator {
|
|
|
23
23
|
isDefault?: boolean;
|
|
24
24
|
active?: boolean;
|
|
25
25
|
}
|
|
26
|
-
export declare class
|
|
26
|
+
export declare class UpdateStockWarehouseValidator extends CreateStockWarehouseValidator {
|
|
27
27
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { CatalogProductEntity } from '../../../inventory/catalog/product';
|
|
2
|
+
import { CatalogVariantEntity } from '../../../inventory/catalog/variant';
|
|
2
3
|
import { AbstractEntity } from '../../..';
|
|
3
4
|
import type { MongoEntity } from '../../..';
|
|
4
5
|
export declare class PurchaseItemEntity extends AbstractEntity {
|
|
5
6
|
product: MongoEntity<CatalogProductEntity>;
|
|
7
|
+
variant: MongoEntity<CatalogVariantEntity>;
|
|
6
8
|
cost: number;
|
|
7
9
|
quantity: number;
|
|
8
10
|
notes?: string;
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
var transaction_enum_1 = require("./transaction.enum");
|
|
4
|
-
Object.keys(transaction_enum_1).forEach(function (key) {
|
|
5
|
-
if (key === "default" || key === "__esModule") return;
|
|
6
|
-
Object.defineProperty(exports, key, { enumerable: true, get: function () { return transaction_enum_1[key]; } });
|
|
7
|
-
});
|
|
1
|
+
export * from './transaction.enum.js';
|
|
@@ -11,7 +11,7 @@ export declare class PurchaseTransactionEntity extends AbstractEntity {
|
|
|
11
11
|
sequence: number;
|
|
12
12
|
notes?: string;
|
|
13
13
|
status: PurchaseTransactionStatusEnum;
|
|
14
|
-
expectedDeliveryDate?: Date;
|
|
15
14
|
readonly number: string;
|
|
16
15
|
readonly total: number;
|
|
16
|
+
readonly payment: import('src/domain/finance/entities/payment.entity').FinancePaymentEntity;
|
|
17
17
|
}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PurchaseTransactionStatusEnum = void 0;
|
|
4
|
-
var PurchaseTransactionStatusEnum;
|
|
1
|
+
export var PurchaseTransactionStatusEnum;
|
|
5
2
|
(function (PurchaseTransactionStatusEnum) {
|
|
6
3
|
PurchaseTransactionStatusEnum["DRAFT"] = "DRAFT";
|
|
7
4
|
PurchaseTransactionStatusEnum["PENDING"] = "PENDING";
|
|
@@ -9,5 +6,4 @@ var PurchaseTransactionStatusEnum;
|
|
|
9
6
|
PurchaseTransactionStatusEnum["SHIPPED"] = "SHIPPED";
|
|
10
7
|
PurchaseTransactionStatusEnum["RECEIVED"] = "RECEIVED";
|
|
11
8
|
PurchaseTransactionStatusEnum["CANCELLED"] = "CANCELLED";
|
|
12
|
-
})(PurchaseTransactionStatusEnum || (
|
|
13
|
-
//# sourceMappingURL=transaction.enum.js.map
|
|
9
|
+
})(PurchaseTransactionStatusEnum || (PurchaseTransactionStatusEnum = {}));
|
|
@@ -12,10 +12,8 @@ export declare class CreatePurchaseTransactionValidator extends AbstractValidato
|
|
|
12
12
|
user: string;
|
|
13
13
|
vendor?: string;
|
|
14
14
|
status: PurchaseTransactionStatusEnum;
|
|
15
|
-
expectedDeliveryDate?: Date;
|
|
16
15
|
}
|
|
17
16
|
export declare class UpdatePurchaseTransactionValidator extends AbstractValidator {
|
|
18
17
|
notes?: string;
|
|
19
18
|
status?: PurchaseTransactionStatusEnum;
|
|
20
|
-
expectedDeliveryDate?: Date;
|
|
21
19
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { SaleCustomerEntity } from './';
|
|
2
|
+
import { SaleCustomerTypeEnum } from './';
|
|
2
3
|
import { AbstractValidator, ReadValidator, SearchValidator } from '../../..';
|
|
3
4
|
export declare class SearchSaleCustomerValidator extends SearchValidator<SaleCustomerEntity> {
|
|
4
5
|
}
|
|
@@ -6,6 +7,7 @@ export declare class ReadSaleCustomerValidator extends ReadValidator<SaleCustome
|
|
|
6
7
|
}
|
|
7
8
|
export declare class CreateSaleCustomerValidator extends AbstractValidator {
|
|
8
9
|
name: string;
|
|
10
|
+
type: SaleCustomerTypeEnum;
|
|
9
11
|
description: string;
|
|
10
12
|
email: string;
|
|
11
13
|
logo: string;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
export * from './customer.enum.js';
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,10 +1,17 @@
|
|
|
1
|
+
import { CatalogAttributeEntity } from '../../../inventory/catalog/attribute';
|
|
1
2
|
import { CatalogProductEntity } from '../../../inventory/catalog/product';
|
|
2
3
|
import { AbstractEntity } from '../../..';
|
|
4
|
+
import type { CatalogVariantEntity } from '../../../inventory/catalog/variant';
|
|
3
5
|
import type { MongoEntity } from '../../..';
|
|
4
6
|
export declare class SaleItemEntity extends AbstractEntity {
|
|
5
7
|
product: MongoEntity<CatalogProductEntity>;
|
|
8
|
+
variant: MongoEntity<CatalogVariantEntity>;
|
|
6
9
|
price: number;
|
|
7
10
|
quantity: number;
|
|
8
11
|
notes?: string;
|
|
12
|
+
options: {
|
|
13
|
+
type: MongoEntity<CatalogAttributeEntity>;
|
|
14
|
+
value: string;
|
|
15
|
+
}[];
|
|
9
16
|
readonly total: number;
|
|
10
17
|
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
|
|
@@ -1,16 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import type { BillingPaymentEntity } from '../../../billing/payment';
|
|
4
|
-
export declare class CreatePaymentValidator {
|
|
1
|
+
import { FinancePaymentMethodEnum } from '../../../finance/payment';
|
|
2
|
+
export declare class SalePaymentValidator {
|
|
5
3
|
order?: string;
|
|
6
|
-
type:
|
|
4
|
+
type: FinancePaymentMethodEnum;
|
|
7
5
|
details?: unknown;
|
|
8
6
|
total?: number;
|
|
9
7
|
}
|
|
10
|
-
export declare class UpdatePaymentValidator extends CreatePaymentValidator {
|
|
11
|
-
}
|
|
12
|
-
export declare class UpdatePaymentStatusValidator {
|
|
13
|
-
type: BillingPaymentStatusEnum;
|
|
14
|
-
}
|
|
15
|
-
export declare class ReadPaymentValidator extends ReadValidator<BillingPaymentEntity> {
|
|
16
|
-
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './shipping.enum.js';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { SaleTransactionEntity } from '../transaction';
|
|
2
|
+
import { AbstractEntity } from '../../..';
|
|
3
|
+
import { CreateEntityArgs } from '../../..';
|
|
4
|
+
import { AddressEntity } from '../../..';
|
|
5
|
+
import { SaleShippingStatusEnum, SaleShippingTypeEnum } from './';
|
|
6
|
+
import type { MongoEntity } from '../../..';
|
|
7
|
+
export declare class SaleShippingEntity extends AbstractEntity {
|
|
8
|
+
order: MongoEntity<SaleTransactionEntity>;
|
|
9
|
+
status: SaleShippingStatusEnum;
|
|
10
|
+
date: Date;
|
|
11
|
+
destinationAddress: CreateEntityArgs<AddressEntity>;
|
|
12
|
+
originAddress: AddressEntity;
|
|
13
|
+
cost: number;
|
|
14
|
+
distance: number;
|
|
15
|
+
type: SaleShippingTypeEnum;
|
|
16
|
+
sequence: number;
|
|
17
|
+
readonly number: string;
|
|
18
|
+
}
|
package/dist/{logistic/shipment/shipment.enum.d.ts → order/sale/shipping/shipping.enum.d.ts}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare enum
|
|
1
|
+
export declare enum SaleShippingStatusEnum {
|
|
2
2
|
OPEN = "OPEN",
|
|
3
3
|
NOT_REQUIRED = "NOT_REQUIRED",
|
|
4
4
|
PROCESSING = "PROCESSING",
|
|
@@ -9,7 +9,7 @@ export declare enum LogisticShippingStatusEnum {
|
|
|
9
9
|
RETURNED = "RETURNED",
|
|
10
10
|
CANCELLED = "CANCELLED"
|
|
11
11
|
}
|
|
12
|
-
export declare enum
|
|
12
|
+
export declare enum SaleShippingTypeEnum {
|
|
13
13
|
PICKUP = "PICKUP",
|
|
14
14
|
DELIVERY = "DELIVERY",
|
|
15
15
|
DROPOFF = "DROPOFF"
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export var SaleShippingStatusEnum;
|
|
2
|
+
(function (SaleShippingStatusEnum) {
|
|
3
|
+
SaleShippingStatusEnum["OPEN"] = "OPEN";
|
|
4
|
+
SaleShippingStatusEnum["NOT_REQUIRED"] = "NOT_REQUIRED";
|
|
5
|
+
SaleShippingStatusEnum["PROCESSING"] = "PROCESSING";
|
|
6
|
+
SaleShippingStatusEnum["SHIPPED"] = "SHIPPED";
|
|
7
|
+
SaleShippingStatusEnum["IN_TRANSIT"] = "IN_TRANSIT";
|
|
8
|
+
SaleShippingStatusEnum["DELIVERED"] = "DELIVERED";
|
|
9
|
+
SaleShippingStatusEnum["FAILED"] = "FAILED";
|
|
10
|
+
SaleShippingStatusEnum["RETURNED"] = "RETURNED";
|
|
11
|
+
SaleShippingStatusEnum["CANCELLED"] = "CANCELLED";
|
|
12
|
+
})(SaleShippingStatusEnum || (SaleShippingStatusEnum = {}));
|
|
13
|
+
export var SaleShippingTypeEnum;
|
|
14
|
+
(function (SaleShippingTypeEnum) {
|
|
15
|
+
SaleShippingTypeEnum["PICKUP"] = "PICKUP";
|
|
16
|
+
SaleShippingTypeEnum["DELIVERY"] = "DELIVERY";
|
|
17
|
+
SaleShippingTypeEnum["DROPOFF"] = "DROPOFF";
|
|
18
|
+
})(SaleShippingTypeEnum || (SaleShippingTypeEnum = {}));
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { SaleOrderAddressValidator } from '
|
|
3
|
-
import { AbstractValidator, ReadValidator } from '
|
|
4
|
-
import type {
|
|
1
|
+
import { SaleShippingStatusEnum, SaleShippingTypeEnum } from './';
|
|
2
|
+
import { SaleOrderAddressValidator } from '../address';
|
|
3
|
+
import { AbstractValidator, ReadValidator } from '../../..';
|
|
4
|
+
import type { SaleShippingEntity } from './';
|
|
5
5
|
export declare class CreateShippingValidator extends AbstractValidator {
|
|
6
6
|
order?: string;
|
|
7
7
|
warehouse?: string;
|
|
8
|
-
type:
|
|
8
|
+
type: SaleShippingTypeEnum;
|
|
9
9
|
address: SaleOrderAddressValidator;
|
|
10
10
|
cost?: number;
|
|
11
11
|
}
|
|
12
12
|
export declare class UpdateShippingValidator extends CreateShippingValidator {
|
|
13
13
|
}
|
|
14
14
|
export declare class UpdateShippingStatusValidator {
|
|
15
|
-
type:
|
|
15
|
+
type: SaleShippingStatusEnum;
|
|
16
16
|
}
|
|
17
|
-
export declare class ReadShippingValidator extends ReadValidator<
|
|
17
|
+
export declare class ReadShippingValidator extends ReadValidator<SaleShippingEntity> {
|
|
18
18
|
}
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
var transaction_enum_1 = require("./transaction.enum");
|
|
4
|
-
Object.keys(transaction_enum_1).forEach(function (key) {
|
|
5
|
-
if (key === "default" || key === "__esModule") return;
|
|
6
|
-
Object.defineProperty(exports, key, { enumerable: true, get: function () { return transaction_enum_1[key]; } });
|
|
7
|
-
});
|
|
1
|
+
export * from './transaction.enum.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AccountUserEntity } from '../../../account/user';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { FinancePaymentEntity } from '../../../finance/payment';
|
|
3
|
+
import { SaleShippingEntity } from '../shipping';
|
|
4
4
|
import { AbstractEntity } from '../../..';
|
|
5
5
|
import { SaleTransactionStatusEnum } from './';
|
|
6
6
|
import { SaleCustomerEntity } from '../customer';
|
|
@@ -8,7 +8,7 @@ import { SaleItemEntity } from '../item';
|
|
|
8
8
|
import type { MongoEntity } from '../../..';
|
|
9
9
|
export declare class SaleTransactionEntity extends AbstractEntity {
|
|
10
10
|
user: MongoEntity<AccountUserEntity>;
|
|
11
|
-
|
|
11
|
+
customer: MongoEntity<SaleCustomerEntity>;
|
|
12
12
|
items: SaleItemEntity[];
|
|
13
13
|
sequence: number;
|
|
14
14
|
notes?: string;
|
|
@@ -16,6 +16,6 @@ export declare class SaleTransactionEntity extends AbstractEntity {
|
|
|
16
16
|
readonly number: string;
|
|
17
17
|
readonly subtotal: number;
|
|
18
18
|
readonly total: number;
|
|
19
|
-
readonly shipping?: MongoEntity<
|
|
20
|
-
readonly payment?: MongoEntity<
|
|
19
|
+
readonly shipping?: MongoEntity<SaleShippingEntity>;
|
|
20
|
+
readonly payment?: MongoEntity<FinancePaymentEntity>;
|
|
21
21
|
}
|