hvp-shared 4.2.0 → 5.0.0
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.
|
@@ -10,15 +10,17 @@
|
|
|
10
10
|
*/
|
|
11
11
|
export declare enum UsageType {
|
|
12
12
|
/** Direct sale to customer */
|
|
13
|
-
|
|
13
|
+
DIRECT_SALE = "directSale",
|
|
14
14
|
/** Optional sale (may or may not be charged) */
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
|
|
15
|
+
OPTIONAL_SALE = "optionalSale",
|
|
16
|
+
/** Auto-deducted from inventory when another item is sold (escandallos) */
|
|
17
|
+
AUTO_DEDUCT = "autoDeduct",
|
|
18
18
|
/** Internal consumption (cleaning supplies, etc.) */
|
|
19
|
-
|
|
19
|
+
INTERNAL_USE = "internalUse",
|
|
20
20
|
/** Fixed asset (equipment, furniture) */
|
|
21
|
-
|
|
21
|
+
FIXED_ASSET = "fixedAsset",
|
|
22
|
+
/** Not applicable (e.g., external services) */
|
|
23
|
+
NOT_APPLICABLE = "notApplicable"
|
|
22
24
|
}
|
|
23
25
|
/**
|
|
24
26
|
* All UsageType values as array (for dropdowns)
|
|
@@ -14,15 +14,17 @@ exports.SYNC_STATUS_LABELS = exports.SYNC_STATUS_VALUES = exports.SyncStatus = e
|
|
|
14
14
|
var UsageType;
|
|
15
15
|
(function (UsageType) {
|
|
16
16
|
/** Direct sale to customer */
|
|
17
|
-
UsageType["
|
|
17
|
+
UsageType["DIRECT_SALE"] = "directSale";
|
|
18
18
|
/** Optional sale (may or may not be charged) */
|
|
19
|
-
UsageType["
|
|
20
|
-
/**
|
|
21
|
-
UsageType["
|
|
19
|
+
UsageType["OPTIONAL_SALE"] = "optionalSale";
|
|
20
|
+
/** Auto-deducted from inventory when another item is sold (escandallos) */
|
|
21
|
+
UsageType["AUTO_DEDUCT"] = "autoDeduct";
|
|
22
22
|
/** Internal consumption (cleaning supplies, etc.) */
|
|
23
|
-
UsageType["
|
|
23
|
+
UsageType["INTERNAL_USE"] = "internalUse";
|
|
24
24
|
/** Fixed asset (equipment, furniture) */
|
|
25
|
-
UsageType["
|
|
25
|
+
UsageType["FIXED_ASSET"] = "fixedAsset";
|
|
26
|
+
/** Not applicable (e.g., external services) */
|
|
27
|
+
UsageType["NOT_APPLICABLE"] = "notApplicable";
|
|
26
28
|
})(UsageType || (exports.UsageType = UsageType = {}));
|
|
27
29
|
/**
|
|
28
30
|
* All UsageType values as array (for dropdowns)
|
|
@@ -32,11 +34,12 @@ exports.USAGE_TYPE_VALUES = Object.values(UsageType);
|
|
|
32
34
|
* UsageType labels in Spanish (for UI)
|
|
33
35
|
*/
|
|
34
36
|
exports.USAGE_TYPE_LABELS = {
|
|
35
|
-
[UsageType.
|
|
36
|
-
[UsageType.
|
|
37
|
-
[UsageType.
|
|
38
|
-
[UsageType.
|
|
39
|
-
[UsageType.
|
|
37
|
+
[UsageType.DIRECT_SALE]: 'Venta Directa',
|
|
38
|
+
[UsageType.OPTIONAL_SALE]: 'Venta Opcional',
|
|
39
|
+
[UsageType.AUTO_DEDUCT]: 'Solo Escandallos',
|
|
40
|
+
[UsageType.INTERNAL_USE]: 'Consumo Interno',
|
|
41
|
+
[UsageType.FIXED_ASSET]: 'Activo Fijo',
|
|
42
|
+
[UsageType.NOT_APPLICABLE]: 'No Aplica',
|
|
40
43
|
};
|
|
41
44
|
/**
|
|
42
45
|
* ArticleType - Type of article in QVET
|
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
* Request DTOs for catalog item endpoints.
|
|
5
5
|
*/
|
|
6
6
|
import { UsageType, SyncStatus } from '../../constants/catalog-item.constants';
|
|
7
|
+
import { MarketCompetition } from '../../constants/market-competition.constants';
|
|
8
|
+
import { PricingRuleCode } from '../../constants/pricing-rule.constants';
|
|
7
9
|
/**
|
|
8
10
|
* Query filters for listing catalog items
|
|
9
11
|
*
|
|
@@ -41,24 +43,46 @@ export interface CatalogItemQueryFilters {
|
|
|
41
43
|
export interface UpdateCatalogItemRequest {
|
|
42
44
|
/** Update description (sets pending) */
|
|
43
45
|
description?: string;
|
|
46
|
+
/** Update secondary description (sets pending) */
|
|
47
|
+
description2?: string;
|
|
48
|
+
/** Update observations (sets pending) */
|
|
49
|
+
observations?: string;
|
|
50
|
+
/** Update barcode (sets pending) */
|
|
51
|
+
barcode?: string;
|
|
52
|
+
/** Update reference (sets pending) */
|
|
53
|
+
reference?: string;
|
|
54
|
+
/** Update brand (sets pending) */
|
|
55
|
+
brand?: string;
|
|
56
|
+
/** Update active status (sets pending) */
|
|
57
|
+
isActive?: boolean;
|
|
44
58
|
/** Update sale price PVP - con IVA (sets pending) */
|
|
45
59
|
salePricePVP?: number;
|
|
60
|
+
/** Update minimum sale price PVP - con IVA (sets pending) */
|
|
61
|
+
minimumPricePVP?: number;
|
|
46
62
|
/** Update purchase price BI - sin IVA (sets pending) */
|
|
47
63
|
purchasePriceBI?: number;
|
|
64
|
+
/** VAT percentage for sales */
|
|
65
|
+
vatSale?: number;
|
|
66
|
+
/** VAT percentage for purchases */
|
|
67
|
+
vatPurchase?: number;
|
|
68
|
+
/** Purchase unit */
|
|
69
|
+
purchaseUnit?: string;
|
|
70
|
+
/** Sale unit */
|
|
71
|
+
saleUnit?: string;
|
|
72
|
+
/** Conversion factor (purchase to sale units) */
|
|
73
|
+
conversionFactor?: number;
|
|
48
74
|
/** Update section (sets pending) */
|
|
49
75
|
section?: string;
|
|
50
76
|
/** Update family (sets pending) */
|
|
51
77
|
family?: string;
|
|
52
78
|
/** Update subfamily (sets pending) */
|
|
53
79
|
subfamily?: string;
|
|
54
|
-
/**
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
|
|
58
|
-
/**
|
|
59
|
-
|
|
60
|
-
/** Update active status (sets pending) */
|
|
61
|
-
isActive?: boolean;
|
|
80
|
+
/** Visible in sales */
|
|
81
|
+
visibleInSales?: boolean;
|
|
82
|
+
/** Visible in purchases */
|
|
83
|
+
visibleInPurchases?: boolean;
|
|
84
|
+
/** Visible in sections (e.g., "WEB,APP") */
|
|
85
|
+
visibleIn?: string;
|
|
62
86
|
/** Update stock control type (sets pending) */
|
|
63
87
|
stockControlType?: string;
|
|
64
88
|
}
|
|
@@ -74,6 +98,12 @@ export interface UpdateCatalogItemHvpDataRequest {
|
|
|
74
98
|
notes?: string;
|
|
75
99
|
/** Internal category */
|
|
76
100
|
internalCategory?: string;
|
|
101
|
+
/** Market competition level */
|
|
102
|
+
marketCompetition?: MarketCompetition;
|
|
103
|
+
/** Pricing rule code */
|
|
104
|
+
pricingRuleCode?: PricingRuleCode;
|
|
105
|
+
/** Recommended price (calculated from pricing rule) */
|
|
106
|
+
recommendedPrice?: number;
|
|
77
107
|
}
|
|
78
108
|
/**
|
|
79
109
|
* Update stock levels for a warehouse (sets pending)
|