@limetech/n8n-nodes-lime 2.7.0-dev.1 → 3.1.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/.devcontainer/devcontainer.json +44 -0
- package/.devcontainer/docker-compose.yml +27 -0
- package/.gitattributes +34 -0
- package/.nvmrc +1 -0
- package/CHANGELOG.md +17 -5
- package/README.md +40 -47
- package/credentials/index.ts +0 -1
- package/dist/credentials/index.d.ts +0 -1
- package/dist/credentials/index.js +0 -1
- package/dist/credentials/index.js.map +1 -1
- package/dist/nodes/index.d.ts +0 -1
- package/dist/nodes/index.js +0 -1
- package/dist/nodes/index.js.map +1 -1
- package/dist/nodes/lime-crm/LimeCrmNode.node.d.ts +1 -4
- package/dist/nodes/lime-crm/LimeCrmNode.node.js +0 -3
- package/dist/nodes/lime-crm/LimeCrmNode.node.js.map +1 -1
- package/dist/nodes/lime-crm/methods/getLimetypeProperties.d.ts +0 -2
- package/dist/nodes/lime-crm/methods/getLimetypeProperties.js +0 -43
- package/dist/nodes/lime-crm/methods/getLimetypeProperties.js.map +1 -1
- package/dist/nodes/lime-crm/methods/index.d.ts +2 -2
- package/dist/nodes/lime-crm/methods/index.js +1 -4
- package/dist/nodes/lime-crm/methods/index.js.map +1 -1
- package/dist/nodes/lime-crm/methods/resourceMapping.d.ts +0 -1
- package/dist/nodes/lime-crm/methods/resourceMapping.js +0 -46
- package/dist/nodes/lime-crm/methods/resourceMapping.js.map +1 -1
- package/dist/nodes/lime-crm/models/limetype.d.ts +0 -1
- package/dist/nodes/lime-crm/resources/data/index.d.ts +1 -1
- package/dist/nodes/lime-crm/resources/data/index.js +0 -20
- package/dist/nodes/lime-crm/resources/data/index.js.map +1 -1
- package/dist/nodes/lime-crm/resources/data/operations/index.d.ts +0 -4
- package/dist/nodes/lime-crm/resources/data/operations/index.js +1 -5
- package/dist/nodes/lime-crm/resources/data/operations/index.js.map +1 -1
- package/dist/nodes/lime-crm/transport/index.d.ts +0 -1
- package/dist/nodes/lime-crm/transport/index.js +1 -6
- package/dist/nodes/lime-crm/transport/index.js.map +1 -1
- package/dist/nodes/lime-crm/transport/limetypes.js +4 -15
- package/dist/nodes/lime-crm/transport/limetypes.js.map +1 -1
- package/dist/nodes/lime-forms/LimeFormsTrigger.node.js +3 -3
- package/dist/nodes/lime-forms/LimeFormsTrigger.node.js.map +1 -1
- package/dist/nodes/lime-forms/assets/lime-crm.svg +1 -0
- package/dist/package.json +5 -12
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/nodes/index.ts +0 -1
- package/nodes/lime-crm/LimeCrmNode.node.ts +0 -6
- package/nodes/lime-crm/methods/getLimetypeProperties.ts +0 -84
- package/nodes/lime-crm/methods/index.ts +0 -3
- package/nodes/lime-crm/methods/resourceMapping.ts +0 -76
- package/nodes/lime-crm/models/limetype.ts +0 -1
- package/nodes/lime-crm/resources/data/index.ts +1 -34
- package/nodes/lime-crm/resources/data/operations/index.ts +0 -17
- package/nodes/lime-crm/transport/index.ts +0 -8
- package/nodes/lime-crm/transport/limetypes.ts +8 -26
- package/nodes/lime-forms/LimeFormsTrigger.node.ts +3 -3
- package/nodes/lime-forms/assets/lime-crm.svg +1 -0
- package/package.json +6 -13
- package/credentials/FortnoxApi.credentials.ts +0 -61
- package/dist/credentials/FortnoxApi.credentials.d.ts +0 -9
- package/dist/credentials/FortnoxApi.credentials.js +0 -57
- package/dist/credentials/FortnoxApi.credentials.js.map +0 -1
- package/dist/nodes/fortnox/Fortnox.node.d.ts +0 -5
- package/dist/nodes/fortnox/Fortnox.node.js +0 -95
- package/dist/nodes/fortnox/Fortnox.node.js.map +0 -1
- package/dist/nodes/fortnox/Fortnox.node.json +0 -18
- package/dist/nodes/fortnox/FortnoxTrigger.node.d.ts +0 -5
- package/dist/nodes/fortnox/FortnoxTrigger.node.js +0 -155
- package/dist/nodes/fortnox/FortnoxTrigger.node.js.map +0 -1
- package/dist/nodes/fortnox/FortnoxTrigger.node.json +0 -18
- package/dist/nodes/fortnox/commons.d.ts +0 -25
- package/dist/nodes/fortnox/commons.js +0 -44
- package/dist/nodes/fortnox/commons.js.map +0 -1
- package/dist/nodes/fortnox/fortnoxLogo.svg +0 -15
- package/dist/nodes/fortnox/index.d.ts +0 -6
- package/dist/nodes/fortnox/index.js +0 -23
- package/dist/nodes/fortnox/index.js.map +0 -1
- package/dist/nodes/fortnox/model.d.ts +0 -20
- package/dist/nodes/fortnox/model.js +0 -3
- package/dist/nodes/fortnox/model.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/filterParameters.d.ts +0 -2
- package/dist/nodes/fortnox/resources/customers/filterParameters.js +0 -31
- package/dist/nodes/fortnox/resources/customers/filterParameters.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/index.d.ts +0 -7
- package/dist/nodes/fortnox/resources/customers/index.js +0 -85
- package/dist/nodes/fortnox/resources/customers/index.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/model.d.ts +0 -99
- package/dist/nodes/fortnox/resources/customers/model.js +0 -3
- package/dist/nodes/fortnox/resources/customers/model.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/operations/create.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/customers/operations/create.operation.js +0 -281
- package/dist/nodes/fortnox/resources/customers/operations/create.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/operations/delete.operation.d.ts +0 -9
- package/dist/nodes/fortnox/resources/customers/operations/delete.operation.js +0 -38
- package/dist/nodes/fortnox/resources/customers/operations/delete.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/operations/get.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/customers/operations/get.operation.js +0 -38
- package/dist/nodes/fortnox/resources/customers/operations/get.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/operations/getAll.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/customers/operations/getAll.operation.js +0 -68
- package/dist/nodes/fortnox/resources/customers/operations/getAll.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/operations/index.d.ts +0 -5
- package/dist/nodes/fortnox/resources/customers/operations/index.js +0 -42
- package/dist/nodes/fortnox/resources/customers/operations/index.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/operations/update.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/customers/operations/update.operation.js +0 -261
- package/dist/nodes/fortnox/resources/customers/operations/update.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/customers/sortParameters.d.ts +0 -2
- package/dist/nodes/fortnox/resources/customers/sortParameters.js +0 -30
- package/dist/nodes/fortnox/resources/customers/sortParameters.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/filterParameters.d.ts +0 -2
- package/dist/nodes/fortnox/resources/invoice/filterParameters.js +0 -72
- package/dist/nodes/fortnox/resources/invoice/filterParameters.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/index.d.ts +0 -7
- package/dist/nodes/fortnox/resources/invoice/index.js +0 -81
- package/dist/nodes/fortnox/resources/invoice/index.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/invoiceParameters.d.ts +0 -2
- package/dist/nodes/fortnox/resources/invoice/invoiceParameters.js +0 -193
- package/dist/nodes/fortnox/resources/invoice/invoiceParameters.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/model.d.ts +0 -147
- package/dist/nodes/fortnox/resources/invoice/model.js +0 -3
- package/dist/nodes/fortnox/resources/invoice/model.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/operations/create.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/invoice/operations/create.operation.js +0 -64
- package/dist/nodes/fortnox/resources/invoice/operations/create.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/operations/get.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/invoice/operations/get.operation.js +0 -37
- package/dist/nodes/fortnox/resources/invoice/operations/get.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/operations/getAll.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/invoice/operations/getAll.operation.js +0 -92
- package/dist/nodes/fortnox/resources/invoice/operations/getAll.operation.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/operations/index.d.ts +0 -4
- package/dist/nodes/fortnox/resources/invoice/operations/index.js +0 -41
- package/dist/nodes/fortnox/resources/invoice/operations/index.js.map +0 -1
- package/dist/nodes/fortnox/resources/invoice/operations/update.operation.d.ts +0 -10
- package/dist/nodes/fortnox/resources/invoice/operations/update.operation.js +0 -64
- package/dist/nodes/fortnox/resources/invoice/operations/update.operation.js.map +0 -1
- package/dist/nodes/fortnox/transport/errorCodes.d.ts +0 -1
- package/dist/nodes/fortnox/transport/errorCodes.js +0 -50
- package/dist/nodes/fortnox/transport/errorCodes.js.map +0 -1
- package/dist/nodes/fortnox/transport/index.d.ts +0 -3
- package/dist/nodes/fortnox/transport/index.js +0 -76
- package/dist/nodes/fortnox/transport/index.js.map +0 -1
- package/dist/nodes/lime-crm/resources/data/operations/bulkImportCommons.d.ts +0 -5
- package/dist/nodes/lime-crm/resources/data/operations/bulkImportCommons.js +0 -230
- package/dist/nodes/lime-crm/resources/data/operations/bulkImportCommons.js.map +0 -1
- package/dist/nodes/lime-crm/resources/data/operations/createManyObjects.operation.d.ts +0 -9
- package/dist/nodes/lime-crm/resources/data/operations/createManyObjects.operation.js +0 -16
- package/dist/nodes/lime-crm/resources/data/operations/createManyObjects.operation.js.map +0 -1
- package/dist/nodes/lime-crm/resources/data/operations/createOrUpdateManyObjects.operation.d.ts +0 -9
- package/dist/nodes/lime-crm/resources/data/operations/createOrUpdateManyObjects.operation.js +0 -16
- package/dist/nodes/lime-crm/resources/data/operations/createOrUpdateManyObjects.operation.js.map +0 -1
- package/dist/nodes/lime-crm/resources/data/operations/deprecated-startBulkImport.operation.d.ts +0 -9
- package/dist/nodes/lime-crm/resources/data/operations/deprecated-startBulkImport.operation.js +0 -241
- package/dist/nodes/lime-crm/resources/data/operations/deprecated-startBulkImport.operation.js.map +0 -1
- package/dist/nodes/lime-crm/resources/data/operations/updateManyObjects.operation.d.ts +0 -9
- package/dist/nodes/lime-crm/resources/data/operations/updateManyObjects.operation.js +0 -16
- package/dist/nodes/lime-crm/resources/data/operations/updateManyObjects.operation.js.map +0 -1
- package/dist/nodes/lime-crm/transport/bulkimport.d.ts +0 -41
- package/dist/nodes/lime-crm/transport/bulkimport.js +0 -86
- package/dist/nodes/lime-crm/transport/bulkimport.js.map +0 -1
- package/dist/nodes/lime-forms/lime-forms.svg +0 -6
- package/docker-compose.yml +0 -0
- package/nodes/fortnox/Fortnox.node.json +0 -18
- package/nodes/fortnox/Fortnox.node.ts +0 -102
- package/nodes/fortnox/FortnoxTrigger.node.json +0 -18
- package/nodes/fortnox/FortnoxTrigger.node.ts +0 -196
- package/nodes/fortnox/commons.ts +0 -94
- package/nodes/fortnox/fortnoxLogo.svg +0 -15
- package/nodes/fortnox/index.ts +0 -6
- package/nodes/fortnox/model.ts +0 -25
- package/nodes/fortnox/resources/customers/filterParameters.ts +0 -47
- package/nodes/fortnox/resources/customers/index.ts +0 -53
- package/nodes/fortnox/resources/customers/model.ts +0 -107
- package/nodes/fortnox/resources/customers/operations/create.operation.ts +0 -307
- package/nodes/fortnox/resources/customers/operations/delete.operation.ts +0 -49
- package/nodes/fortnox/resources/customers/operations/get.operation.ts +0 -50
- package/nodes/fortnox/resources/customers/operations/getAll.operation.ts +0 -79
- package/nodes/fortnox/resources/customers/operations/index.ts +0 -5
- package/nodes/fortnox/resources/customers/operations/update.operation.ts +0 -288
- package/nodes/fortnox/resources/customers/sortParameters.ts +0 -32
- package/nodes/fortnox/resources/invoice/filterParameters.ts +0 -88
- package/nodes/fortnox/resources/invoice/index.ts +0 -49
- package/nodes/fortnox/resources/invoice/invoiceParameters.ts +0 -214
- package/nodes/fortnox/resources/invoice/model.ts +0 -156
- package/nodes/fortnox/resources/invoice/operations/create.operation.ts +0 -71
- package/nodes/fortnox/resources/invoice/operations/get.operation.ts +0 -50
- package/nodes/fortnox/resources/invoice/operations/getAll.operation.ts +0 -100
- package/nodes/fortnox/resources/invoice/operations/index.ts +0 -4
- package/nodes/fortnox/resources/invoice/operations/update.operation.ts +0 -79
- package/nodes/fortnox/transport/errorCodes.ts +0 -62
- package/nodes/fortnox/transport/index.ts +0 -106
- package/nodes/lime-crm/resources/data/operations/bulkImportCommons.ts +0 -323
- package/nodes/lime-crm/resources/data/operations/createManyObjects.operation.ts +0 -44
- package/nodes/lime-crm/resources/data/operations/createOrUpdateManyObjects.operation.ts +0 -44
- package/nodes/lime-crm/resources/data/operations/deprecated-startBulkImport.operation.ts +0 -364
- package/nodes/lime-crm/resources/data/operations/updateManyObjects.operation.ts +0 -44
- package/nodes/lime-crm/transport/bulkimport.ts +0 -271
- package/nodes/lime-forms/lime-forms.svg +0 -6
|
@@ -1,261 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.properties = exports.description = void 0;
|
|
4
|
-
exports.execute = execute;
|
|
5
|
-
const n8n_workflow_1 = require("n8n-workflow");
|
|
6
|
-
const transport_1 = require("../../../transport");
|
|
7
|
-
const currency_codes_1 = require("currency-codes");
|
|
8
|
-
exports.description = {
|
|
9
|
-
name: 'Update Customer',
|
|
10
|
-
value: 'update',
|
|
11
|
-
description: 'Update an existing customer',
|
|
12
|
-
action: 'Update a customer',
|
|
13
|
-
};
|
|
14
|
-
const updateProperties = [
|
|
15
|
-
{
|
|
16
|
-
displayName: 'Name',
|
|
17
|
-
name: 'Name',
|
|
18
|
-
type: 'string',
|
|
19
|
-
default: '',
|
|
20
|
-
description: 'Customer name',
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
displayName: 'Active',
|
|
24
|
-
name: 'Active',
|
|
25
|
-
type: 'boolean',
|
|
26
|
-
default: true,
|
|
27
|
-
description: 'Whether the customer is active',
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
displayName: 'Address 1',
|
|
31
|
-
name: 'Address1',
|
|
32
|
-
type: 'string',
|
|
33
|
-
default: '',
|
|
34
|
-
description: "Customer's primary address",
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
displayName: 'Address 2',
|
|
38
|
-
name: 'Address2',
|
|
39
|
-
type: 'string',
|
|
40
|
-
default: '',
|
|
41
|
-
description: "Customer's secondary address",
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
displayName: 'City',
|
|
45
|
-
name: 'City',
|
|
46
|
-
type: 'string',
|
|
47
|
-
default: '',
|
|
48
|
-
description: "Customer's city",
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
displayName: 'Comments',
|
|
52
|
-
name: 'Comments',
|
|
53
|
-
type: 'string',
|
|
54
|
-
default: '',
|
|
55
|
-
description: 'Comments about the customer',
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
displayName: 'Currency',
|
|
59
|
-
name: 'Currency',
|
|
60
|
-
type: 'string',
|
|
61
|
-
default: '',
|
|
62
|
-
description: "Customer's currency code, e.g., SEK, EUR",
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
displayName: 'Cost Center',
|
|
66
|
-
name: 'CostCenter',
|
|
67
|
-
type: 'string',
|
|
68
|
-
default: '',
|
|
69
|
-
description: "Customer's cost center",
|
|
70
|
-
},
|
|
71
|
-
{
|
|
72
|
-
displayName: 'Country',
|
|
73
|
-
name: 'Country',
|
|
74
|
-
type: 'string',
|
|
75
|
-
default: '',
|
|
76
|
-
description: "Customer's country",
|
|
77
|
-
},
|
|
78
|
-
{
|
|
79
|
-
displayName: 'Country Code',
|
|
80
|
-
name: 'CountryCode',
|
|
81
|
-
type: 'string',
|
|
82
|
-
default: '',
|
|
83
|
-
description: "Customer's country code",
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
displayName: 'Email',
|
|
87
|
-
name: 'Email',
|
|
88
|
-
type: 'string',
|
|
89
|
-
default: '',
|
|
90
|
-
description: "Customer's email address",
|
|
91
|
-
},
|
|
92
|
-
{
|
|
93
|
-
displayName: 'External Reference',
|
|
94
|
-
name: 'ExternalReference',
|
|
95
|
-
type: 'string',
|
|
96
|
-
default: '',
|
|
97
|
-
description: 'External reference for the customer',
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
displayName: 'Fax',
|
|
101
|
-
name: 'Fax',
|
|
102
|
-
type: 'string',
|
|
103
|
-
default: '',
|
|
104
|
-
description: "Customer's fax number",
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
displayName: 'GLN',
|
|
108
|
-
name: 'GLN',
|
|
109
|
-
type: 'string',
|
|
110
|
-
default: '',
|
|
111
|
-
description: 'Global Location Number',
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
displayName: 'Organisation Number',
|
|
115
|
-
name: 'OrganisationNumber',
|
|
116
|
-
type: 'string',
|
|
117
|
-
default: '',
|
|
118
|
-
description: "Customer's organisation number",
|
|
119
|
-
},
|
|
120
|
-
{
|
|
121
|
-
displayName: 'Phone 1',
|
|
122
|
-
name: 'Phone1',
|
|
123
|
-
type: 'string',
|
|
124
|
-
default: '',
|
|
125
|
-
description: "Customer's primary phone number",
|
|
126
|
-
},
|
|
127
|
-
{
|
|
128
|
-
displayName: 'Phone 2',
|
|
129
|
-
name: 'Phone2',
|
|
130
|
-
type: 'string',
|
|
131
|
-
default: '',
|
|
132
|
-
description: "Customer's secondary phone number",
|
|
133
|
-
},
|
|
134
|
-
{
|
|
135
|
-
displayName: 'Type',
|
|
136
|
-
name: 'Type',
|
|
137
|
-
type: 'options',
|
|
138
|
-
options: [
|
|
139
|
-
{
|
|
140
|
-
name: 'Private',
|
|
141
|
-
value: 'PRIVATE',
|
|
142
|
-
},
|
|
143
|
-
{
|
|
144
|
-
name: 'Company',
|
|
145
|
-
value: 'COMPANY',
|
|
146
|
-
},
|
|
147
|
-
],
|
|
148
|
-
default: 'COMPANY',
|
|
149
|
-
description: 'Type of customer',
|
|
150
|
-
},
|
|
151
|
-
{
|
|
152
|
-
displayName: 'VAT Number',
|
|
153
|
-
name: 'VATNumber',
|
|
154
|
-
type: 'string',
|
|
155
|
-
default: '',
|
|
156
|
-
description: "Customer's VAT number",
|
|
157
|
-
},
|
|
158
|
-
{
|
|
159
|
-
displayName: 'VAT Type',
|
|
160
|
-
name: 'VATType',
|
|
161
|
-
type: 'options',
|
|
162
|
-
options: [
|
|
163
|
-
{
|
|
164
|
-
name: 'SE VAT',
|
|
165
|
-
value: 'SEVAT',
|
|
166
|
-
},
|
|
167
|
-
{
|
|
168
|
-
name: 'SE Reversed VAT',
|
|
169
|
-
value: 'SEREVERSEDVAT',
|
|
170
|
-
},
|
|
171
|
-
{
|
|
172
|
-
name: 'EU Reversed VAT',
|
|
173
|
-
value: 'EUREVERSEDVAT',
|
|
174
|
-
},
|
|
175
|
-
{
|
|
176
|
-
name: 'EU VAT',
|
|
177
|
-
value: 'EUVAT',
|
|
178
|
-
},
|
|
179
|
-
{
|
|
180
|
-
name: 'Export',
|
|
181
|
-
value: 'EXPORT',
|
|
182
|
-
},
|
|
183
|
-
],
|
|
184
|
-
default: 'SEVAT',
|
|
185
|
-
description: 'Type of VAT applied',
|
|
186
|
-
},
|
|
187
|
-
{
|
|
188
|
-
displayName: 'Website',
|
|
189
|
-
name: 'WWW',
|
|
190
|
-
type: 'string',
|
|
191
|
-
default: '',
|
|
192
|
-
description: "Customer's website URL",
|
|
193
|
-
},
|
|
194
|
-
{
|
|
195
|
-
displayName: 'ZIP Code',
|
|
196
|
-
name: 'ZipCode',
|
|
197
|
-
type: 'string',
|
|
198
|
-
default: '',
|
|
199
|
-
description: "Customer's ZIP/postal code",
|
|
200
|
-
},
|
|
201
|
-
];
|
|
202
|
-
exports.properties = [
|
|
203
|
-
{
|
|
204
|
-
displayName: 'Customer Number',
|
|
205
|
-
name: 'customerNumber',
|
|
206
|
-
type: 'string',
|
|
207
|
-
required: true,
|
|
208
|
-
default: '',
|
|
209
|
-
description: 'Unique identifier for customer',
|
|
210
|
-
displayOptions: {
|
|
211
|
-
show: {
|
|
212
|
-
resource: ['customer'],
|
|
213
|
-
operation: ['update'],
|
|
214
|
-
},
|
|
215
|
-
},
|
|
216
|
-
},
|
|
217
|
-
{
|
|
218
|
-
displayName: 'Fields',
|
|
219
|
-
name: 'fields',
|
|
220
|
-
type: 'collection',
|
|
221
|
-
placeholder: 'Add Field',
|
|
222
|
-
default: {},
|
|
223
|
-
displayOptions: {
|
|
224
|
-
show: {
|
|
225
|
-
resource: ['customer'],
|
|
226
|
-
operation: ['update'],
|
|
227
|
-
},
|
|
228
|
-
},
|
|
229
|
-
options: [...updateProperties],
|
|
230
|
-
},
|
|
231
|
-
];
|
|
232
|
-
async function execute(i) {
|
|
233
|
-
const customerNumber = this.getNodeParameter('customerNumber', i);
|
|
234
|
-
const fields = this.getNodeParameter('fields', i, {});
|
|
235
|
-
if (Object.keys(fields).length === 0) {
|
|
236
|
-
throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'At least one field must be provided for update');
|
|
237
|
-
}
|
|
238
|
-
if (fields.name && fields.name === '') {
|
|
239
|
-
throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'Customer name cannot be empty');
|
|
240
|
-
}
|
|
241
|
-
if (fields.Currency) {
|
|
242
|
-
fields.Currency = String(fields.Currency).toUpperCase();
|
|
243
|
-
if ((0, currency_codes_1.code)(fields.Currency) === undefined) {
|
|
244
|
-
throw new n8n_workflow_1.NodeOperationError(this.getNode(), `Invalid currency code: ${fields.Currency}. Use ISO 4217 currency code.`);
|
|
245
|
-
}
|
|
246
|
-
}
|
|
247
|
-
const body = {
|
|
248
|
-
Customer: {
|
|
249
|
-
...fields,
|
|
250
|
-
},
|
|
251
|
-
};
|
|
252
|
-
const endpoint = `/customers/${encodeURIComponent(customerNumber)}`;
|
|
253
|
-
return await (0, transport_1.apiRequest)(this, {
|
|
254
|
-
method: 'PUT',
|
|
255
|
-
endpoint: endpoint,
|
|
256
|
-
body: body,
|
|
257
|
-
}, {
|
|
258
|
-
id: customerNumber,
|
|
259
|
-
});
|
|
260
|
-
}
|
|
261
|
-
//# sourceMappingURL=update.operation.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update.operation.js","sourceRoot":"","sources":["../../../../../../nodes/fortnox/resources/customers/operations/update.operation.ts"],"names":[],"mappings":";;;AA6OA,0BAkDC;AA/RD,+CAKsB;AACtB,kDAAgD;AAEhD,mDAAsD;AAEzC,QAAA,WAAW,GAAG;IACvB,IAAI,EAAE,iBAAiB;IACvB,KAAK,EAAE,QAAQ;IACf,WAAW,EAAE,6BAA6B;IAC1C,MAAM,EAAE,mBAAmB;CAC9B,CAAC;AAEF,MAAM,gBAAgB,GAAsB;IACxC;QACI,WAAW,EAAE,MAAM;QACnB,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,eAAe;KAC/B;IACD;QACI,WAAW,EAAE,QAAQ;QACrB,IAAI,EAAE,QAAQ;QACd,IAAI,EAAE,SAAS;QACf,OAAO,EAAE,IAAI;QACb,WAAW,EAAE,gCAAgC;KAChD;IACD;QACI,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,4BAA4B;KAC5C;IACD;QACI,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,8BAA8B;KAC9C;IACD;QACI,WAAW,EAAE,MAAM;QACnB,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,iBAAiB;KACjC;IACD;QACI,WAAW,EAAE,UAAU;QACvB,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,6BAA6B;KAC7C;IACD;QACI,WAAW,E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IAAI,CAAC,OAAO,EAAE,EACd,+BAA+B,CAClC,CAAC;IACN,CAAC;IAED,IAAI,MAAM,CAAC,QAAQ,EAAE,CAAC;QAClB,MAAM,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC;QACxD,IAAI,IAAA,qBAAY,EAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,SAAS,EAAE,CAAC;YAC9C,MAAM,IAAI,iCAAkB,CACxB,IAAI,CAAC,OAAO,EAAE,EACd,0BAA0B,MAAM,CAAC,QAAQ,+BAA+B,CAC3E,CAAC;QACN,CAAC;IACL,CAAC;IAED,MAAM,IAAI,GAAG;QACT,QAAQ,EAAE;YACN,GAAG,MAAM;SACZ;KACJ,CAAC;IAEF,MAAM,QAAQ,GAAG,cAAc,kBAAkB,CAAC,cAAc,CAAC,EAAE,CAAC;IAEpE,OAAO,MAAM,IAAA,sBAAU,EACnB,IAAI,EACJ;QACI,MAAM,EAAE,KAAK;QACb,QAAQ,EAAE,QAAQ;QAClB,IAAI,EAAE,IAAI;KACb,EACD;QACI,EAAE,EAAE,cAAc;KACrB,CACJ,CAAC;AACN,CAAC"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.sortParameters = void 0;
|
|
4
|
-
const sortByDefinitions = [
|
|
5
|
-
['Customer Number', 'customernumber'],
|
|
6
|
-
['Name', 'name'],
|
|
7
|
-
];
|
|
8
|
-
function createSortProperties(parameters) {
|
|
9
|
-
const options = parameters.map(([displayName, fieldName]) => {
|
|
10
|
-
return {
|
|
11
|
-
name: displayName,
|
|
12
|
-
value: fieldName,
|
|
13
|
-
description: `Sort by ${displayName.toLowerCase()}`,
|
|
14
|
-
};
|
|
15
|
-
});
|
|
16
|
-
return [
|
|
17
|
-
{
|
|
18
|
-
displayName: 'Sort by',
|
|
19
|
-
name: 'sortby',
|
|
20
|
-
type: 'options',
|
|
21
|
-
noDataExpression: true,
|
|
22
|
-
options: options,
|
|
23
|
-
default: options[0].value,
|
|
24
|
-
placeholder: 'Select a field to sort by',
|
|
25
|
-
description: 'Select a field to sort by',
|
|
26
|
-
},
|
|
27
|
-
];
|
|
28
|
-
}
|
|
29
|
-
exports.sortParameters = createSortProperties(sortByDefinitions);
|
|
30
|
-
//# sourceMappingURL=sortParameters.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sortParameters.js","sourceRoot":"","sources":["../../../../../nodes/fortnox/resources/customers/sortParameters.ts"],"names":[],"mappings":";;;AAEA,MAAM,iBAAiB,GAAG;IACtB,CAAC,iBAAiB,EAAE,gBAAgB,CAAC;IACrC,CAAC,MAAM,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,SAAS,oBAAoB,CAAC,UAAsB;IAChD,MAAM,OAAO,GAAG,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,WAAW,EAAE,SAAS,CAAC,EAAE,EAAE;QACxD,OAAO;YACH,IAAI,EAAE,WAAW;YACjB,KAAK,EAAE,SAAS;YAChB,WAAW,EAAE,WAAW,WAAW,CAAC,WAAW,EAAE,EAAE;SACtD,CAAC;IACN,CAAC,CAAC,CAAC;IAEH,OAAO;QACH;YACI,WAAW,EAAE,SAAS;YACtB,IAAI,EAAE,QAAQ;YACd,IAAI,EAAE,SAA8B;YACpC,gBAAgB,EAAE,IAAI;YACtB,OAAO,EAAE,OAAO;YAChB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,KAAK;YACzB,WAAW,EAAE,2BAA2B;YACxC,WAAW,EAAE,2BAA2B;SAC3C;KACJ,CAAC;AACN,CAAC;AAEY,QAAA,cAAc,GACvB,oBAAoB,CAAC,iBAAiB,CAAC,CAAC"}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.filterParameters = void 0;
|
|
4
|
-
const commons_1 = require("../../commons");
|
|
5
|
-
const optionParametersDefinitions = [
|
|
6
|
-
{
|
|
7
|
-
displayName: 'Invoice Status',
|
|
8
|
-
name: 'filter',
|
|
9
|
-
parameters: [
|
|
10
|
-
['Cancelled', 'cancelled'],
|
|
11
|
-
['Fully Paid', 'fullypaid'],
|
|
12
|
-
['Unbooked', 'unbooked'],
|
|
13
|
-
['Unpaid', 'unpaid'],
|
|
14
|
-
['Unpaid And Overdue', 'unpaidoverdue'],
|
|
15
|
-
],
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
displayName: 'Invoice Type',
|
|
19
|
-
name: 'InvoiceType',
|
|
20
|
-
parameters: [
|
|
21
|
-
['Invoice', 'invoice'],
|
|
22
|
-
['Agreement Invoice', 'agreementinvoice'],
|
|
23
|
-
['Intrest Invoice', 'intrestinvoice'],
|
|
24
|
-
['Summery Invoice', 'summaryinvoice'],
|
|
25
|
-
['Cash Invoice', 'cashinvoice'],
|
|
26
|
-
],
|
|
27
|
-
},
|
|
28
|
-
];
|
|
29
|
-
const parametersDefinitions = [
|
|
30
|
-
['Account Number From', 'accountnumberfrom', 'string', '', {}],
|
|
31
|
-
['Account Number To', 'accountnumberto', 'string', '', {}],
|
|
32
|
-
['Article Description', 'articledescription', 'string', '', {}],
|
|
33
|
-
['Article Number', 'articlenumber', 'string', '', {}],
|
|
34
|
-
['Cost Center', 'costcenter', 'string', '', {}],
|
|
35
|
-
['Credit', 'credit', 'string', '', {}],
|
|
36
|
-
['Currency', 'currency', 'string', '', {}],
|
|
37
|
-
['Customer Name', 'customername', 'string', '', {}],
|
|
38
|
-
['Customer Number', 'customernumber', 'string', '', {}],
|
|
39
|
-
['Document Number', 'documentnumber', 'string', '', {}],
|
|
40
|
-
[
|
|
41
|
-
'External Invoice Reference 1',
|
|
42
|
-
'externalinvoicereference1',
|
|
43
|
-
'string',
|
|
44
|
-
'',
|
|
45
|
-
{},
|
|
46
|
-
],
|
|
47
|
-
[
|
|
48
|
-
'External Invoice Reference 2',
|
|
49
|
-
'externalinvoicereference2',
|
|
50
|
-
'string',
|
|
51
|
-
'',
|
|
52
|
-
{},
|
|
53
|
-
],
|
|
54
|
-
['From Date', 'fromdate', 'string', '', {}],
|
|
55
|
-
['From Final Pay Date', 'fromfinalpaydate', 'string', '', {}],
|
|
56
|
-
['Label', 'label', 'string', '', {}],
|
|
57
|
-
['Last Modified', 'lastmodified', 'string', '', {}],
|
|
58
|
-
['Not Completed', 'notcomplete', 'string', '', {}],
|
|
59
|
-
['OCR', 'ocr', 'string', '', {}],
|
|
60
|
-
['Our Reference', 'ourreference', 'string', '', {}],
|
|
61
|
-
['Project', 'project', 'string', '', {}],
|
|
62
|
-
['Sent', 'sent', 'boolean', false, {}],
|
|
63
|
-
['To Date', 'todate', 'string', '', {}],
|
|
64
|
-
['To Final Pay Date', 'tofinalpaydate', 'string', '', {}],
|
|
65
|
-
['Your Order Number', 'yourordernumber', 'string', '', {}],
|
|
66
|
-
['Your Reference', 'yourreference', 'string', '', {}],
|
|
67
|
-
];
|
|
68
|
-
exports.filterParameters = [
|
|
69
|
-
...optionParametersDefinitions.map((option) => (0, commons_1.createOptionParameter)(option)),
|
|
70
|
-
...parametersDefinitions.map(([displayName, name, filterType, defaultValue, typeOptions]) => (0, commons_1.createParameter)(displayName, name, filterType, defaultValue, typeOptions)),
|
|
71
|
-
];
|
|
72
|
-
//# sourceMappingURL=filterParameters.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"filterParameters.js","sourceRoot":"","sources":["../../../../../nodes/fortnox/resources/invoice/filterParameters.ts"],"names":[],"mappings":";;;AACA,2CAKuB;AAEvB,MAAM,2BAA2B,GAAgC;IAC7D;QACI,WAAW,EAAE,gBAAgB;QAC7B,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,CAAC,WAAW,EAAE,WAAW,CAAC;YAC1B,CAAC,YAAY,EAAE,WAAW,CAAC;YAC3B,CAAC,UA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CAChC;IACD,GAAG,qBAAqB,CAAC,GAAG,CACxB,CAAC,CAAC,WAAW,EAAE,IAAI,EAAE,UAAU,EAAE,YAAY,EAAE,WAAW,CAAC,EAAE,EAAE,CAC3D,IAAA,yBAAe,EACX,WAAW,EACX,IAAI,EACJ,UAAU,EACV,YAAY,EACZ,WAAW,CACd,CACR;CACJ,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { IExecuteFunctions, INodeProperties } from 'n8n-workflow';
|
|
2
|
-
export declare const invoiceProperties: INodeProperties[];
|
|
3
|
-
export declare function invoiceOperations(this: IExecuteFunctions, { operation, i }: {
|
|
4
|
-
operation: string;
|
|
5
|
-
i: number;
|
|
6
|
-
}): Promise<import("./model").CreateInvoiceResponse | import("./model").GetInvoiceResponse | import("./model").GetAllInvoicesResponse | null>;
|
|
7
|
-
export * from './operations';
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
36
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
|
-
};
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.invoiceProperties = void 0;
|
|
40
|
-
exports.invoiceOperations = invoiceOperations;
|
|
41
|
-
const operations = __importStar(require("./operations"));
|
|
42
|
-
const modules_1 = require("../../../modules");
|
|
43
|
-
const moduleHandler = new modules_1.N8NOperationModuleHandler([
|
|
44
|
-
operations.createSingleInvoice,
|
|
45
|
-
operations.getManyInvoices,
|
|
46
|
-
operations.getSingleInvoice,
|
|
47
|
-
operations.updateSingleInvoice,
|
|
48
|
-
]);
|
|
49
|
-
exports.invoiceProperties = [
|
|
50
|
-
{
|
|
51
|
-
displayName: 'Operation',
|
|
52
|
-
name: 'operation',
|
|
53
|
-
type: 'options',
|
|
54
|
-
noDataExpression: true,
|
|
55
|
-
displayOptions: {
|
|
56
|
-
show: {
|
|
57
|
-
resource: ['invoice'],
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
options: moduleHandler.getDescriptions(),
|
|
61
|
-
default: 'getAll',
|
|
62
|
-
},
|
|
63
|
-
...moduleHandler.getProperties(),
|
|
64
|
-
];
|
|
65
|
-
async function invoiceOperations({ operation, i }) {
|
|
66
|
-
if (operation === 'create') {
|
|
67
|
-
return await operations.createSingleInvoice.execute.call(this, i);
|
|
68
|
-
}
|
|
69
|
-
else if (operation === 'get') {
|
|
70
|
-
return await operations.getSingleInvoice.execute.call(this, i);
|
|
71
|
-
}
|
|
72
|
-
else if (operation === 'getAll') {
|
|
73
|
-
return await operations.getManyInvoices.execute.call(this, i);
|
|
74
|
-
}
|
|
75
|
-
else if (operation === 'update') {
|
|
76
|
-
return await operations.updateSingleInvoice.execute.call(this, i);
|
|
77
|
-
}
|
|
78
|
-
return null;
|
|
79
|
-
}
|
|
80
|
-
__exportStar(require("./operations"), exports);
|
|
81
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../nodes/fortnox/resources/invoice/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiCA,8CAcC;AAzCD,yDAA2C;AAC3C,8CAA6D;AAE7D,MAAM,aAAa,GAAG,IAAI,mCAAyB,CAAC;IAChD,UAAU,CAAC,mBAAmB;IAC9B,UAAU,CAAC,eAAe;IAC1B,UAAU,CAAC,gBAAgB;IAC3B,UAAU,CAAC,mBAAmB;CACjC,CAAC,CAAC;AAEU,QAAA,iBAAiB,GAAsB;IAChD;QACI,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAA8B;QACpC,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACZ,IAAI,EAAE;gBACF,QAAQ,EAAE,CAAC,SAAS,CAAC;aACxB;SACJ;QACD,OAAO,EAAE,aAAa,CAAC,eAAe,EAAE;QACxC,OAAO,EAAE,QAAQ;KACpB;IACD,GAAG,aAAa,CAAC,aAAa,EAAE;CACnC,CAAC;AAEK,KAAK,UAAU,iBAAiB,CAEnC,EAAE,SAAS,EAAE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