@tillhub/schemas 6.100.2 → 6.103.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.
- package/CHANGELOG.md +28 -0
- package/lib/v0/product_addons/base.js +6 -1
- package/lib/v0/tse_exports/base.js +26 -56
- package/lib/v0/tse_exports/create.js +1 -1
- package/lib/v1/configurations/items/products.js +3 -3
- package/lib/v1/products/prices/book/base.js +8 -0
- package/lib/v1/products/search.js +3 -0
- package/lib/v1/transactions/components/embedded/addon/base.js +8 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,31 @@
|
|
|
1
|
+
# [6.103.0](https://github.com/tillhub/schemas/compare/v6.102.0...v6.103.0) (2021-11-08)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* **product_addons:** Extend add-ons with editable quantity functionality ([#645](https://github.com/tillhub/schemas/issues/645)) ([ba8a564](https://github.com/tillhub/schemas/commit/ba8a564))
|
|
7
|
+
|
|
8
|
+
# [6.102.0](https://github.com/tillhub/schemas/compare/v6.101.0...v6.102.0) (2021-11-03)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **pricebook:** add lowest_price, highest_price ([2c55b20](https://github.com/tillhub/schemas/commit/2c55b20))
|
|
14
|
+
|
|
15
|
+
# [6.101.0](https://github.com/tillhub/schemas/compare/v6.100.3...v6.101.0) (2021-10-29)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Features
|
|
19
|
+
|
|
20
|
+
* **pricebooks:** add branch groups #API-1115 ([fac9fd0](https://github.com/tillhub/schemas/commit/fac9fd0)), closes [#API-1115](https://github.com/tillhub/schemas/issues/API-1115)
|
|
21
|
+
|
|
22
|
+
## [6.100.3](https://github.com/tillhub/schemas/compare/v6.100.2...v6.100.3) (2021-10-22)
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Bug Fixes
|
|
26
|
+
|
|
27
|
+
* **products:** q is required property in products search request chema ([#641](https://github.com/tillhub/schemas/issues/641)) ([ceb3019](https://github.com/tillhub/schemas/commit/ceb3019))
|
|
28
|
+
|
|
1
29
|
## [6.100.2](https://github.com/tillhub/schemas/compare/v6.100.1...v6.100.2) (2021-10-22)
|
|
2
30
|
|
|
3
31
|
|
|
@@ -38,7 +38,7 @@ module.exports = {
|
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
40
|
),
|
|
41
|
-
|
|
41
|
+
stock_quantity: {
|
|
42
42
|
type: 'number',
|
|
43
43
|
description: 'How much of the product stock will be moved (defaults to 1 - only important if it affects stock). This value can be negative number!',
|
|
44
44
|
default: 1
|
|
@@ -53,6 +53,11 @@ module.exports = {
|
|
|
53
53
|
description: 'Can the cashier edit the quantity of the addon selected (only important if it affects stock)',
|
|
54
54
|
default: false
|
|
55
55
|
},
|
|
56
|
+
max_quantity: {
|
|
57
|
+
type: 'number',
|
|
58
|
+
description: 'Maximum count the product stock will be moved. Related to the allow_quantity_edit - only if it set to true',
|
|
59
|
+
default: 1
|
|
60
|
+
},
|
|
56
61
|
order_index: {
|
|
57
62
|
type: 'number',
|
|
58
63
|
description: 'Display the Addon in a specific order',
|
|
@@ -2,43 +2,30 @@ const { oneOf } = require('../../helpers/payload-or-null')
|
|
|
2
2
|
|
|
3
3
|
module.exports = {
|
|
4
4
|
client_id: {
|
|
5
|
-
description: 'An identifier used locally on POS for their own reference.',
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
type: 'string',
|
|
9
|
-
maxLength: 128
|
|
10
|
-
},
|
|
11
|
-
{
|
|
12
|
-
type: 'null'
|
|
13
|
-
}
|
|
14
|
-
]
|
|
5
|
+
description: 'An identifier used locally on POS for their own reference. Guaranteed to be there',
|
|
6
|
+
type: 'string',
|
|
7
|
+
maxLength: 128
|
|
15
8
|
},
|
|
16
|
-
balance_client_id: {
|
|
9
|
+
balance_client_id: oneOf({
|
|
17
10
|
type: 'string',
|
|
18
11
|
maxLength: 128,
|
|
19
|
-
description: 'A reference to the balance this exports belongs to.'
|
|
20
|
-
},
|
|
21
|
-
balance_number: {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
...oneOf({
|
|
37
|
-
type: 'integer',
|
|
38
|
-
example: 11,
|
|
39
|
-
description: 'The register number'
|
|
40
|
-
})
|
|
41
|
-
},
|
|
12
|
+
description: 'A reference to the balance this exports belongs to. Can be omitted for archives.'
|
|
13
|
+
}),
|
|
14
|
+
balance_number: oneOf({
|
|
15
|
+
type: 'integer',
|
|
16
|
+
example: 5,
|
|
17
|
+
description: 'The associated balance\'s counting number (receipt number) of this export. Can be omitted for archives.'
|
|
18
|
+
}),
|
|
19
|
+
branch_custom_id: oneOf({
|
|
20
|
+
type: 'integer',
|
|
21
|
+
example: 7,
|
|
22
|
+
description: 'The branch number'
|
|
23
|
+
}),
|
|
24
|
+
register_custom_id: oneOf({
|
|
25
|
+
type: 'integer',
|
|
26
|
+
example: 11,
|
|
27
|
+
description: 'The register number'
|
|
28
|
+
}),
|
|
42
29
|
register: {
|
|
43
30
|
type: 'string',
|
|
44
31
|
format: 'uuid',
|
|
@@ -65,47 +52,30 @@ module.exports = {
|
|
|
65
52
|
export: {
|
|
66
53
|
type: 'object',
|
|
67
54
|
properties: {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
example: 15,
|
|
71
|
-
description: 'The first TSE transaction number in this export'
|
|
72
|
-
},
|
|
73
|
-
transaction_number_last: {
|
|
74
|
-
type: 'integer',
|
|
75
|
-
example: 19,
|
|
76
|
-
description: 'The last TSE transaction number in this export'
|
|
77
|
-
},
|
|
78
|
-
date_start: {
|
|
79
|
-
description: 'Daterange start of the export.',
|
|
55
|
+
date_start: oneOf({
|
|
56
|
+
description: 'Daterange start of the export, omitted for archives.',
|
|
80
57
|
type: 'string',
|
|
81
58
|
format: 'date-time',
|
|
82
59
|
example: '2020-10-17T08:12:04.849Z'
|
|
83
|
-
},
|
|
60
|
+
}),
|
|
84
61
|
date_end: {
|
|
85
62
|
description: 'Daterange end of the export.',
|
|
86
63
|
type: 'string',
|
|
87
64
|
format: 'date-time',
|
|
88
65
|
example: '2020-10-17T21:12:04.849Z'
|
|
89
66
|
},
|
|
90
|
-
url: {
|
|
67
|
+
url: oneOf({
|
|
91
68
|
description: 'URL of the uploaded export tar file.',
|
|
92
69
|
type: 'string',
|
|
93
70
|
format: 'uri'
|
|
94
|
-
},
|
|
71
|
+
}),
|
|
95
72
|
type: {
|
|
96
73
|
type: 'string',
|
|
97
74
|
'enum': [
|
|
98
75
|
'archive',
|
|
99
|
-
'number',
|
|
100
|
-
'number_interval',
|
|
101
76
|
'time_period'
|
|
102
77
|
],
|
|
103
78
|
default: 'time_period'
|
|
104
|
-
},
|
|
105
|
-
client_id: {
|
|
106
|
-
description: 'An identifier used locally on the POS for their own reference.',
|
|
107
|
-
type: 'string',
|
|
108
|
-
maxLength: 128
|
|
109
79
|
}
|
|
110
80
|
}
|
|
111
81
|
}
|
|
@@ -23,6 +23,14 @@ module.exports = {
|
|
|
23
23
|
format: 'uuid'
|
|
24
24
|
}
|
|
25
25
|
}),
|
|
26
|
+
branch_groups: oneOf({
|
|
27
|
+
description: 'If defined then only these branch groups (plus specified locations if any) will be using this price book',
|
|
28
|
+
type: 'array',
|
|
29
|
+
items: {
|
|
30
|
+
type: 'string',
|
|
31
|
+
format: 'uuid'
|
|
32
|
+
}
|
|
33
|
+
}),
|
|
26
34
|
active: {
|
|
27
35
|
type: 'boolean'
|
|
28
36
|
},
|
|
@@ -33,6 +33,14 @@ module.exports = {
|
|
|
33
33
|
maxLength: 3
|
|
34
34
|
},
|
|
35
35
|
quantity: {
|
|
36
|
+
type: 'number',
|
|
37
|
+
description: 'Number of times the addon is applied to the cart item. Respects the max_quantity setting on the Addon',
|
|
38
|
+
example: 3.6,
|
|
39
|
+
minimum: -32767.000,
|
|
40
|
+
maximum: 32767.000,
|
|
41
|
+
multipleOf: 0.001
|
|
42
|
+
},
|
|
43
|
+
stock_quantity: {
|
|
36
44
|
type: 'number',
|
|
37
45
|
description: 'The quantity of this addon, e.g. 1 pc or 0.125kg - this does never affect the price (only used for stock).',
|
|
38
46
|
example: 3.6,
|