@gls_spain/gps-common 35.14.1 → 35.14.3
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/CHANGELOG.md +33 -19
- package/package.json +1 -1
- package/schemas/definitions/sales.js +25 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,31 +1,45 @@
|
|
|
1
|
-
## [35.14.
|
|
1
|
+
## [35.14.3](https://github.com/GLS-Spain/gps-common/compare/v35.14.2...v35.14.3) (2025-09-01)
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
### Bug Fixes
|
|
5
5
|
|
|
6
|
-
*
|
|
6
|
+
* sales.discount fix ([7a7bceb](https://github.com/GLS-Spain/gps-common/commit/7a7bcebac719d42943b55f094ad201d7603b00cf))
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
## [35.14.2](https://github.com/GLS-Spain/gps-common/compare/v35.14.1...v35.14.2) (2025-09-01)
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
###
|
|
12
|
-
|
|
13
|
-
* add new properties in shopUsers ([951e609](https://github.com/GLS-Spain/gps-common/commit/951e6097b686932f0685117646c35154e56d9541))
|
|
14
|
-
|
|
15
|
-
# [35.13.0](https://github.com/GLS-Spain/gps-common/compare/v35.12.0...v35.13.0) (2025-08-07)
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
### Features
|
|
19
|
-
|
|
20
|
-
* add zipTieCode in expeditions schema ([fe3b311](https://github.com/GLS-Spain/gps-common/commit/fe3b311e569b92309cf1fbb06a60fb59a456b3d5))
|
|
21
|
-
|
|
22
|
-
# [35.12.0](https://github.com/GLS-Spain/gps-common/compare/v35.11.0...v35.12.0) (2025-08-07)
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
### Features
|
|
11
|
+
### Bug Fixes
|
|
26
12
|
|
|
27
|
-
*
|
|
13
|
+
* fix sales.discount ([4b9c09e](https://github.com/GLS-Spain/gps-common/commit/4b9c09eb7c172369784f5d597f6f21f8801af55d))
|
|
28
14
|
|
|
15
|
+
## [35.14.1](https://github.com/GLS-Spain/gps-common/compare/v35.14.0...v35.14.1) (2025-08-20)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
* change naming activateRoleMFA ([e1f1d57](https://github.com/GLS-Spain/gps-common/commit/e1f1d57137c42483d9c64bf401d03c0ebc1fbae7))
|
|
21
|
+
|
|
22
|
+
# [35.14.0](https://github.com/GLS-Spain/gps-common/compare/v35.13.0...v35.14.0) (2025-08-20)
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Features
|
|
26
|
+
|
|
27
|
+
* add new properties in shopUsers ([951e609](https://github.com/GLS-Spain/gps-common/commit/951e6097b686932f0685117646c35154e56d9541))
|
|
28
|
+
|
|
29
|
+
# [35.13.0](https://github.com/GLS-Spain/gps-common/compare/v35.12.0...v35.13.0) (2025-08-07)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
### Features
|
|
33
|
+
|
|
34
|
+
* add zipTieCode in expeditions schema ([fe3b311](https://github.com/GLS-Spain/gps-common/commit/fe3b311e569b92309cf1fbb06a60fb59a456b3d5))
|
|
35
|
+
|
|
36
|
+
# [35.12.0](https://github.com/GLS-Spain/gps-common/compare/v35.11.0...v35.12.0) (2025-08-07)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
### Features
|
|
40
|
+
|
|
41
|
+
* add new property zipTieCode in expeditions ([d00549b](https://github.com/GLS-Spain/gps-common/commit/d00549b2780a54638f4256e66a99d6e632f9e310))
|
|
42
|
+
|
|
29
43
|
# [35.11.0](https://github.com/GLS-Spain/gps-common/compare/v35.10.9...v35.11.0) (2025-07-25)
|
|
30
44
|
|
|
31
45
|
|
package/package.json
CHANGED
|
@@ -32,6 +32,30 @@ const parcelShopData = () => ({
|
|
|
32
32
|
required: ['_id', 'email', 'name', 'phone', 'postalCode'],
|
|
33
33
|
});
|
|
34
34
|
|
|
35
|
+
const carrefourDiscount = () => ({
|
|
36
|
+
type: 'object',
|
|
37
|
+
properties: {
|
|
38
|
+
type: { type: 'string', enum: ['carrefour'] },
|
|
39
|
+
code: { type: 'string' },
|
|
40
|
+
price: { type: 'integer', minimum: 0 },
|
|
41
|
+
percentage: { type: 'number', minimum: 0 },
|
|
42
|
+
clientPrice: { type: 'integer', minimum: 0 },
|
|
43
|
+
},
|
|
44
|
+
required: ['type', 'code', 'price'],
|
|
45
|
+
additionalProperties: false,
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
const campaignDiscount = () => ({
|
|
49
|
+
type: 'object',
|
|
50
|
+
properties: {
|
|
51
|
+
type: { type: 'string', enum: ['campaign'] },
|
|
52
|
+
code: { type: 'string' },
|
|
53
|
+
price: { type: 'integer', minimum: 0 },
|
|
54
|
+
},
|
|
55
|
+
required: ['type', 'code', 'price'],
|
|
56
|
+
additionalProperties: false,
|
|
57
|
+
});
|
|
58
|
+
|
|
35
59
|
const sale = () => ({
|
|
36
60
|
title: 'sale',
|
|
37
61
|
type: 'object',
|
|
@@ -152,14 +176,7 @@ const sale = () => ({
|
|
|
152
176
|
typeService: { type: 'string', enum: ['parcel', 'traveller'] },
|
|
153
177
|
// 2025-07-25 JL descuentos (campañas/carrefour)
|
|
154
178
|
discount: {
|
|
155
|
-
|
|
156
|
-
properties: {
|
|
157
|
-
type: { type: 'string' },
|
|
158
|
-
code: { type: 'string' },
|
|
159
|
-
price: { type: 'integer', minimum: 0 },
|
|
160
|
-
},
|
|
161
|
-
required: ['type', 'code', 'price'],
|
|
162
|
-
additionalProperties: false,
|
|
179
|
+
oneOf: [campaignDiscount(), carrefourDiscount()],
|
|
163
180
|
},
|
|
164
181
|
},
|
|
165
182
|
required: [
|