@wals-pro/n8n-nodes-weclapp 0.3.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.
Files changed (98) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +206 -0
  3. package/dist/credentials/WeclappApi.credentials.d.ts +10 -0
  4. package/dist/credentials/WeclappApi.credentials.js +56 -0
  5. package/dist/credentials/WeclappApi.credentials.js.map +1 -0
  6. package/dist/credentials/weclapp.dark.svg +19 -0
  7. package/dist/credentials/weclapp.light.svg +19 -0
  8. package/dist/nodes/Weclapp/GenericFunctions.d.ts +19 -0
  9. package/dist/nodes/Weclapp/GenericFunctions.js +287 -0
  10. package/dist/nodes/Weclapp/GenericFunctions.js.map +1 -0
  11. package/dist/nodes/Weclapp/SharedFields.d.ts +24 -0
  12. package/dist/nodes/Weclapp/SharedFields.js +348 -0
  13. package/dist/nodes/Weclapp/SharedFields.js.map +1 -0
  14. package/dist/nodes/Weclapp/Weclapp.node.d.ts +27 -0
  15. package/dist/nodes/Weclapp/Weclapp.node.js +231 -0
  16. package/dist/nodes/Weclapp/Weclapp.node.js.map +1 -0
  17. package/dist/nodes/Weclapp/actions/applyPayment.d.ts +9 -0
  18. package/dist/nodes/Weclapp/actions/applyPayment.js +64 -0
  19. package/dist/nodes/Weclapp/actions/applyPayment.js.map +1 -0
  20. package/dist/nodes/Weclapp/actions/articlePriceSync.d.ts +41 -0
  21. package/dist/nodes/Weclapp/actions/articlePriceSync.js +238 -0
  22. package/dist/nodes/Weclapp/actions/articlePriceSync.js.map +1 -0
  23. package/dist/nodes/Weclapp/actions/documentUpload.d.ts +3 -0
  24. package/dist/nodes/Weclapp/actions/documentUpload.js +90 -0
  25. package/dist/nodes/Weclapp/actions/documentUpload.js.map +1 -0
  26. package/dist/nodes/Weclapp/descriptions/ArticleDescription.d.ts +3 -0
  27. package/dist/nodes/Weclapp/descriptions/ArticleDescription.js +724 -0
  28. package/dist/nodes/Weclapp/descriptions/ArticleDescription.js.map +1 -0
  29. package/dist/nodes/Weclapp/descriptions/BankDescription.d.ts +6 -0
  30. package/dist/nodes/Weclapp/descriptions/BankDescription.js +471 -0
  31. package/dist/nodes/Weclapp/descriptions/BankDescription.js.map +1 -0
  32. package/dist/nodes/Weclapp/descriptions/CustomApiDescription.d.ts +4 -0
  33. package/dist/nodes/Weclapp/descriptions/CustomApiDescription.js +238 -0
  34. package/dist/nodes/Weclapp/descriptions/CustomApiDescription.js.map +1 -0
  35. package/dist/nodes/Weclapp/descriptions/DocumentDescription.d.ts +3 -0
  36. package/dist/nodes/Weclapp/descriptions/DocumentDescription.js +976 -0
  37. package/dist/nodes/Weclapp/descriptions/DocumentDescription.js.map +1 -0
  38. package/dist/nodes/Weclapp/descriptions/PartyDescription.d.ts +4 -0
  39. package/dist/nodes/Weclapp/descriptions/PartyDescription.js +408 -0
  40. package/dist/nodes/Weclapp/descriptions/PartyDescription.js.map +1 -0
  41. package/dist/nodes/Weclapp/descriptions/ProductionOrderDescription.d.ts +4 -0
  42. package/dist/nodes/Weclapp/descriptions/ProductionOrderDescription.js +628 -0
  43. package/dist/nodes/Weclapp/descriptions/ProductionOrderDescription.js.map +1 -0
  44. package/dist/nodes/Weclapp/descriptions/PurchaseInvoiceDescription.d.ts +3 -0
  45. package/dist/nodes/Weclapp/descriptions/PurchaseInvoiceDescription.js +559 -0
  46. package/dist/nodes/Weclapp/descriptions/PurchaseInvoiceDescription.js.map +1 -0
  47. package/dist/nodes/Weclapp/descriptions/PurchaseOrderDescription.d.ts +3 -0
  48. package/dist/nodes/Weclapp/descriptions/PurchaseOrderDescription.js +681 -0
  49. package/dist/nodes/Weclapp/descriptions/PurchaseOrderDescription.js.map +1 -0
  50. package/dist/nodes/Weclapp/descriptions/QuotationDescription.d.ts +3 -0
  51. package/dist/nodes/Weclapp/descriptions/QuotationDescription.js +1069 -0
  52. package/dist/nodes/Weclapp/descriptions/QuotationDescription.js.map +1 -0
  53. package/dist/nodes/Weclapp/descriptions/SalesInvoiceDescription.d.ts +3 -0
  54. package/dist/nodes/Weclapp/descriptions/SalesInvoiceDescription.js +994 -0
  55. package/dist/nodes/Weclapp/descriptions/SalesInvoiceDescription.js.map +1 -0
  56. package/dist/nodes/Weclapp/descriptions/SalesOrderDescription.d.ts +4 -0
  57. package/dist/nodes/Weclapp/descriptions/SalesOrderDescription.js +1122 -0
  58. package/dist/nodes/Weclapp/descriptions/SalesOrderDescription.js.map +1 -0
  59. package/dist/nodes/Weclapp/descriptions/ShipmentDescription.d.ts +3 -0
  60. package/dist/nodes/Weclapp/descriptions/ShipmentDescription.js +502 -0
  61. package/dist/nodes/Weclapp/descriptions/ShipmentDescription.js.map +1 -0
  62. package/dist/nodes/Weclapp/descriptions/TagUnitUserDescription.d.ts +9 -0
  63. package/dist/nodes/Weclapp/descriptions/TagUnitUserDescription.js +664 -0
  64. package/dist/nodes/Weclapp/descriptions/TagUnitUserDescription.js.map +1 -0
  65. package/dist/nodes/Weclapp/descriptions/TicketDescription.d.ts +9 -0
  66. package/dist/nodes/Weclapp/descriptions/TicketDescription.js +745 -0
  67. package/dist/nodes/Weclapp/descriptions/TicketDescription.js.map +1 -0
  68. package/dist/nodes/Weclapp/descriptions/WarehouseDescription.d.ts +35 -0
  69. package/dist/nodes/Weclapp/descriptions/WarehouseDescription.js +935 -0
  70. package/dist/nodes/Weclapp/descriptions/WarehouseDescription.js.map +1 -0
  71. package/dist/nodes/Weclapp/descriptions/WebhookDescription.d.ts +4 -0
  72. package/dist/nodes/Weclapp/descriptions/WebhookDescription.js +411 -0
  73. package/dist/nodes/Weclapp/descriptions/WebhookDescription.js.map +1 -0
  74. package/dist/nodes/Weclapp/descriptions/index.d.ts +3 -0
  75. package/dist/nodes/Weclapp/descriptions/index.js +56 -0
  76. package/dist/nodes/Weclapp/descriptions/index.js.map +1 -0
  77. package/dist/nodes/Weclapp/generated/entityMetadata.d.ts +3 -0
  78. package/dist/nodes/Weclapp/generated/entityMetadata.js +368 -0
  79. package/dist/nodes/Weclapp/generated/entityMetadata.js.map +1 -0
  80. package/dist/nodes/Weclapp/generated/openapiMetadata.d.ts +3 -0
  81. package/dist/nodes/Weclapp/generated/openapiMetadata.js +212 -0
  82. package/dist/nodes/Weclapp/generated/openapiMetadata.js.map +1 -0
  83. package/dist/nodes/Weclapp/methods/customAttributes.d.ts +32 -0
  84. package/dist/nodes/Weclapp/methods/customAttributes.js +156 -0
  85. package/dist/nodes/Weclapp/methods/customAttributes.js.map +1 -0
  86. package/dist/nodes/Weclapp/methods/loadOptions.d.ts +3 -0
  87. package/dist/nodes/Weclapp/methods/loadOptions.js +107 -0
  88. package/dist/nodes/Weclapp/methods/loadOptions.js.map +1 -0
  89. package/dist/nodes/Weclapp/weclapp.dark.svg +19 -0
  90. package/dist/nodes/Weclapp/weclapp.light.svg +19 -0
  91. package/dist/nodes/WeclappTrigger/WeclappTrigger.node.d.ts +12 -0
  92. package/dist/nodes/WeclappTrigger/WeclappTrigger.node.js +198 -0
  93. package/dist/nodes/WeclappTrigger/WeclappTrigger.node.js.map +1 -0
  94. package/dist/nodes/WeclappTrigger/weclapp.dark.svg +19 -0
  95. package/dist/nodes/WeclappTrigger/weclapp.light.svg +19 -0
  96. package/dist/package.json +78 -0
  97. package/dist/tsconfig.tsbuildinfo +1 -0
  98. package/package.json +78 -0
@@ -0,0 +1,664 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.customAttributeDefinitionFields = exports.customAttributeDefinitionOperations = exports.userFields = exports.userOperations = exports.unitFields = exports.unitOperations = exports.tagFields = exports.tagOperations = void 0;
4
+ const SharedFields_1 = require("../SharedFields");
5
+ const GenericFunctions_1 = require("../GenericFunctions");
6
+ const rootProperty = [{ type: 'rootProperty', properties: { property: 'result' } }];
7
+ const setDeleted = [{ type: 'set', properties: { value: '{"deleted":true}' } }];
8
+ exports.tagOperations = [
9
+ {
10
+ displayName: 'Operation',
11
+ name: 'operation',
12
+ type: 'options',
13
+ noDataExpression: true,
14
+ displayOptions: { show: { resource: ['tag'] } },
15
+ options: [
16
+ {
17
+ name: 'Create',
18
+ value: 'create',
19
+ description: 'Create a new tag',
20
+ action: 'Create a tag',
21
+ routing: { request: { method: 'POST', url: '/tag' } },
22
+ },
23
+ {
24
+ name: 'Delete',
25
+ value: 'delete',
26
+ description: 'Delete a tag by ID',
27
+ action: 'Delete a tag',
28
+ routing: {
29
+ request: { method: 'DELETE', url: '=/tag/id/{{$parameter.tagId}}' },
30
+ output: { postReceive: setDeleted },
31
+ },
32
+ },
33
+ {
34
+ name: 'Get',
35
+ value: 'get',
36
+ description: 'Get a tag by ID',
37
+ action: 'Get a tag',
38
+ routing: {
39
+ request: { method: 'GET', url: '=/tag/id/{{$parameter.tagId}}' },
40
+ output: { postReceive: [GenericFunctions_1.simplifyPostReceive] },
41
+ },
42
+ },
43
+ {
44
+ name: 'Get Many',
45
+ value: 'list',
46
+ description: 'List tags with optional filters',
47
+ action: 'Get many tags',
48
+ routing: {
49
+ request: { method: 'GET', url: '/tag' },
50
+ ...SharedFields_1.listPaginationRouting,
51
+ output: { postReceive: [...rootProperty, GenericFunctions_1.mergeAdditionalProperties, GenericFunctions_1.simplifyPostReceive] },
52
+ },
53
+ },
54
+ {
55
+ name: 'Update',
56
+ value: 'update',
57
+ description: 'Update a tag by ID',
58
+ action: 'Update a tag',
59
+ routing: { request: { method: 'PUT', url: '=/tag/id/{{$parameter.tagId}}', qs: { ignoreMissingProperties: true } } },
60
+ },
61
+ ],
62
+ default: 'list',
63
+ },
64
+ ];
65
+ exports.tagFields = [
66
+ {
67
+ ...SharedFields_1.limitField,
68
+ displayOptions: { show: { resource: ['tag'], operation: ['list'] } },
69
+ },
70
+ {
71
+ ...SharedFields_1.filtersCollection,
72
+ displayOptions: { show: { resource: ['tag'], operation: ['list'] } },
73
+ },
74
+ {
75
+ ...SharedFields_1.simplifyField,
76
+ displayOptions: { show: { resource: ['tag'], operation: ['list', 'get'] } },
77
+ },
78
+ {
79
+ ...SharedFields_1.additionalFields,
80
+ displayOptions: { show: { resource: ['tag'], operation: ['list', 'get'] } },
81
+ },
82
+ {
83
+ displayName: 'Tag ID',
84
+ name: 'tagId',
85
+ type: 'string',
86
+ required: true,
87
+ default: '',
88
+ description: 'The ID of the tag',
89
+ displayOptions: { show: { resource: ['tag'], operation: ['get', 'delete', 'update'] } },
90
+ },
91
+ {
92
+ displayName: 'Name',
93
+ name: 'tagName',
94
+ type: 'string',
95
+ required: true,
96
+ default: '',
97
+ description: 'Tag name',
98
+ displayOptions: { show: { resource: ['tag'], operation: ['create'] } },
99
+ routing: { send: { type: 'body', property: 'name' } },
100
+ },
101
+ {
102
+ displayName: 'Additional Fields',
103
+ name: 'tagBody',
104
+ type: 'collection',
105
+ placeholder: 'Add Field',
106
+ default: {},
107
+ displayOptions: { show: { resource: ['tag'], operation: ['create', 'update'] } },
108
+ options: [
109
+ {
110
+ displayName: 'Name',
111
+ name: 'tagName',
112
+ type: 'string',
113
+ default: '',
114
+ description: 'Tag name',
115
+ routing: { send: { type: 'body', property: 'name' } },
116
+ },
117
+ ],
118
+ },
119
+ ];
120
+ exports.unitOperations = [
121
+ {
122
+ displayName: 'Operation',
123
+ name: 'operation',
124
+ type: 'options',
125
+ noDataExpression: true,
126
+ displayOptions: { show: { resource: ['unit'] } },
127
+ options: [
128
+ {
129
+ name: 'Create',
130
+ value: 'create',
131
+ description: 'Create a new unit of measure',
132
+ action: 'Create a unit',
133
+ routing: { request: { method: 'POST', url: '/unit' } },
134
+ },
135
+ {
136
+ name: 'Delete',
137
+ value: 'delete',
138
+ description: 'Delete a unit by ID',
139
+ action: 'Delete a unit',
140
+ routing: {
141
+ request: { method: 'DELETE', url: '=/unit/id/{{$parameter.unitId}}' },
142
+ output: { postReceive: setDeleted },
143
+ },
144
+ },
145
+ {
146
+ name: 'Get',
147
+ value: 'get',
148
+ description: 'Get a unit by ID',
149
+ action: 'Get a unit',
150
+ routing: {
151
+ request: { method: 'GET', url: '=/unit/id/{{$parameter.unitId}}' },
152
+ output: { postReceive: [GenericFunctions_1.simplifyPostReceive] },
153
+ },
154
+ },
155
+ {
156
+ name: 'Get Many',
157
+ value: 'list',
158
+ description: 'List units of measure with optional filters',
159
+ action: 'Get many units',
160
+ routing: {
161
+ request: { method: 'GET', url: '/unit' },
162
+ ...SharedFields_1.listPaginationRouting,
163
+ output: { postReceive: [...rootProperty, GenericFunctions_1.mergeAdditionalProperties, GenericFunctions_1.simplifyPostReceive] },
164
+ },
165
+ },
166
+ {
167
+ name: 'Update',
168
+ value: 'update',
169
+ description: 'Update a unit by ID',
170
+ action: 'Update a unit',
171
+ routing: { request: { method: 'PUT', url: '=/unit/id/{{$parameter.unitId}}', qs: { ignoreMissingProperties: true } } },
172
+ },
173
+ ],
174
+ default: 'list',
175
+ },
176
+ ];
177
+ exports.unitFields = [
178
+ {
179
+ ...SharedFields_1.limitField,
180
+ displayOptions: { show: { resource: ['unit'], operation: ['list'] } },
181
+ },
182
+ {
183
+ ...SharedFields_1.filtersCollection,
184
+ displayOptions: { show: { resource: ['unit'], operation: ['list'] } },
185
+ },
186
+ {
187
+ ...SharedFields_1.simplifyField,
188
+ displayOptions: { show: { resource: ['unit'], operation: ['list', 'get'] } },
189
+ },
190
+ {
191
+ ...SharedFields_1.additionalFields,
192
+ displayOptions: { show: { resource: ['unit'], operation: ['list', 'get'] } },
193
+ },
194
+ {
195
+ displayName: 'Unit ID',
196
+ name: 'unitId',
197
+ type: 'string',
198
+ required: true,
199
+ default: '',
200
+ description: 'The ID of the unit',
201
+ displayOptions: { show: { resource: ['unit'], operation: ['get', 'delete', 'update'] } },
202
+ },
203
+ {
204
+ displayName: 'Name',
205
+ name: 'unitName',
206
+ type: 'string',
207
+ required: true,
208
+ default: '',
209
+ description: 'Unit name (e.g. Kilogram)',
210
+ displayOptions: { show: { resource: ['unit'], operation: ['create'] } },
211
+ routing: { send: { type: 'body', property: 'name' } },
212
+ },
213
+ {
214
+ displayName: 'Additional Fields',
215
+ name: 'unitBody',
216
+ type: 'collection',
217
+ placeholder: 'Add Field',
218
+ default: {},
219
+ displayOptions: { show: { resource: ['unit'], operation: ['create', 'update'] } },
220
+ options: [
221
+ {
222
+ displayName: 'Abbreviation',
223
+ name: 'abbreviation',
224
+ type: 'string',
225
+ default: '',
226
+ description: 'Short abbreviation for the unit (e.g. kg)',
227
+ routing: { send: { type: 'body', property: 'abbreviation' } },
228
+ },
229
+ {
230
+ displayName: 'Name',
231
+ name: 'unitName',
232
+ type: 'string',
233
+ default: '',
234
+ description: 'Unit name',
235
+ routing: { send: { type: 'body', property: 'name' } },
236
+ },
237
+ ],
238
+ },
239
+ ];
240
+ exports.userOperations = [
241
+ {
242
+ displayName: 'Operation',
243
+ name: 'operation',
244
+ type: 'options',
245
+ noDataExpression: true,
246
+ displayOptions: { show: { resource: ['user'] } },
247
+ options: [
248
+ {
249
+ name: 'Create',
250
+ value: 'create',
251
+ description: 'Create a new user',
252
+ action: 'Create a user',
253
+ routing: { request: { method: 'POST', url: '/user' } },
254
+ },
255
+ {
256
+ name: 'Get',
257
+ value: 'get',
258
+ description: 'Get a user by ID',
259
+ action: 'Get a user',
260
+ routing: {
261
+ request: { method: 'GET', url: '=/user/id/{{$parameter.userId}}' },
262
+ output: { postReceive: [GenericFunctions_1.simplifyPostReceive] },
263
+ },
264
+ },
265
+ {
266
+ name: 'Get Current',
267
+ value: 'getCurrent',
268
+ description: 'Get the currently authenticated user',
269
+ action: 'Get current user',
270
+ routing: {
271
+ request: { method: 'GET', url: '/user/currentUser' },
272
+ output: { postReceive: [...rootProperty, GenericFunctions_1.simplifyPostReceive] },
273
+ },
274
+ },
275
+ {
276
+ name: 'Get Many',
277
+ value: 'list',
278
+ description: 'List users with optional filters',
279
+ action: 'Get many users',
280
+ routing: {
281
+ request: { method: 'GET', url: '/user' },
282
+ ...SharedFields_1.listPaginationRouting,
283
+ output: { postReceive: [...rootProperty, GenericFunctions_1.mergeAdditionalProperties, GenericFunctions_1.simplifyPostReceive] },
284
+ },
285
+ },
286
+ {
287
+ name: 'Update',
288
+ value: 'update',
289
+ description: 'Update a user by ID',
290
+ action: 'Update a user',
291
+ routing: { request: { method: 'PUT', url: '=/user/id/{{$parameter.userId}}', qs: { ignoreMissingProperties: true } } },
292
+ },
293
+ ],
294
+ default: 'list',
295
+ },
296
+ ];
297
+ exports.userFields = [
298
+ {
299
+ ...SharedFields_1.limitField,
300
+ displayOptions: { show: { resource: ['user'], operation: ['list'] } },
301
+ },
302
+ {
303
+ ...SharedFields_1.filtersCollection,
304
+ displayOptions: { show: { resource: ['user'], operation: ['list'] } },
305
+ },
306
+ {
307
+ ...SharedFields_1.simplifyField,
308
+ displayOptions: { show: { resource: ['user'], operation: ['list', 'get', 'getCurrent'] } },
309
+ },
310
+ {
311
+ ...SharedFields_1.additionalFields,
312
+ displayOptions: {
313
+ show: { resource: ['user'], operation: ['list', 'get', 'getCurrent'] },
314
+ },
315
+ },
316
+ {
317
+ displayName: 'User ID',
318
+ name: 'userId',
319
+ type: 'string',
320
+ required: true,
321
+ default: '',
322
+ description: 'The ID of the user',
323
+ displayOptions: { show: { resource: ['user'], operation: ['get', 'update'] } },
324
+ },
325
+ {
326
+ displayName: 'Username',
327
+ name: 'username',
328
+ type: 'string',
329
+ required: true,
330
+ default: '',
331
+ description: 'Login username for the new user',
332
+ displayOptions: { show: { resource: ['user'], operation: ['create'] } },
333
+ routing: { send: { type: 'body', property: 'username' } },
334
+ },
335
+ {
336
+ displayName: 'Email',
337
+ name: 'email',
338
+ type: 'string',
339
+ required: true,
340
+ default: '',
341
+ placeholder: 'name@example.com',
342
+ description: 'Email address of the new user',
343
+ displayOptions: { show: { resource: ['user'], operation: ['create'] } },
344
+ routing: { send: { type: 'body', property: 'email' } },
345
+ },
346
+ {
347
+ displayName: 'Additional Fields',
348
+ name: 'userBody',
349
+ type: 'collection',
350
+ placeholder: 'Add Field',
351
+ default: {},
352
+ displayOptions: { show: { resource: ['user'], operation: ['create', 'update'] } },
353
+ options: [
354
+ {
355
+ displayName: 'Active',
356
+ name: 'active',
357
+ type: 'boolean',
358
+ default: true,
359
+ description: 'Whether the user account is active',
360
+ routing: { send: { type: 'body', property: 'active' } },
361
+ },
362
+ {
363
+ displayName: 'Email',
364
+ name: 'email',
365
+ type: 'string',
366
+ default: '',
367
+ placeholder: 'name@example.com',
368
+ description: 'Email address',
369
+ routing: { send: { type: 'body', property: 'email' } },
370
+ },
371
+ {
372
+ displayName: 'First Name',
373
+ name: 'firstName',
374
+ type: 'string',
375
+ default: '',
376
+ description: 'First name of the user',
377
+ routing: { send: { type: 'body', property: 'firstName' } },
378
+ },
379
+ {
380
+ displayName: 'Last Name',
381
+ name: 'lastName',
382
+ type: 'string',
383
+ default: '',
384
+ description: 'Last name of the user',
385
+ routing: { send: { type: 'body', property: 'lastName' } },
386
+ },
387
+ {
388
+ displayName: 'Username',
389
+ name: 'username',
390
+ type: 'string',
391
+ default: '',
392
+ description: 'Login username',
393
+ routing: { send: { type: 'body', property: 'username' } },
394
+ },
395
+ ],
396
+ },
397
+ ];
398
+ exports.customAttributeDefinitionOperations = [
399
+ {
400
+ displayName: 'Operation',
401
+ name: 'operation',
402
+ type: 'options',
403
+ noDataExpression: true,
404
+ displayOptions: { show: { resource: ['customAttributeDefinition'] } },
405
+ options: [
406
+ {
407
+ name: 'Create',
408
+ value: 'create',
409
+ description: 'Create a new custom attribute definition',
410
+ action: 'Create a custom attribute definition',
411
+ routing: { request: { method: 'POST', url: '/customAttributeDefinition' } },
412
+ },
413
+ {
414
+ name: 'Delete',
415
+ value: 'delete',
416
+ description: 'Delete a custom attribute definition by ID',
417
+ action: 'Delete a custom attribute definition',
418
+ routing: {
419
+ request: {
420
+ method: 'DELETE',
421
+ url: '=/customAttributeDefinition/id/{{$parameter.customAttributeDefinitionId}}',
422
+ },
423
+ output: { postReceive: setDeleted },
424
+ },
425
+ },
426
+ {
427
+ name: 'Get',
428
+ value: 'get',
429
+ description: 'Get a custom attribute definition by ID',
430
+ action: 'Get a custom attribute definition',
431
+ routing: {
432
+ request: {
433
+ method: 'GET',
434
+ url: '=/customAttributeDefinition/id/{{$parameter.customAttributeDefinitionId}}',
435
+ },
436
+ output: { postReceive: [GenericFunctions_1.simplifyPostReceive] },
437
+ },
438
+ },
439
+ {
440
+ name: 'Get Many',
441
+ value: 'list',
442
+ description: 'List custom attribute definitions with optional filters',
443
+ action: 'Get many custom attribute definitions',
444
+ routing: {
445
+ request: { method: 'GET', url: '/customAttributeDefinition' },
446
+ ...SharedFields_1.listPaginationRouting,
447
+ output: { postReceive: [...rootProperty, GenericFunctions_1.mergeAdditionalProperties, GenericFunctions_1.simplifyPostReceive] },
448
+ },
449
+ },
450
+ {
451
+ name: 'Update',
452
+ value: 'update',
453
+ description: 'Update a custom attribute definition by ID',
454
+ action: 'Update a custom attribute definition',
455
+ routing: {
456
+ request: {
457
+ method: 'PUT',
458
+ url: '=/customAttributeDefinition/id/{{$parameter.customAttributeDefinitionId}}',
459
+ },
460
+ },
461
+ },
462
+ ],
463
+ default: 'list',
464
+ },
465
+ ];
466
+ exports.customAttributeDefinitionFields = [
467
+ {
468
+ ...SharedFields_1.limitField,
469
+ displayOptions: {
470
+ show: { resource: ['customAttributeDefinition'], operation: ['list'] },
471
+ },
472
+ },
473
+ {
474
+ ...SharedFields_1.filtersCollection,
475
+ displayOptions: {
476
+ show: { resource: ['customAttributeDefinition'], operation: ['list'] },
477
+ },
478
+ },
479
+ {
480
+ ...SharedFields_1.simplifyField,
481
+ displayOptions: {
482
+ show: { resource: ['customAttributeDefinition'], operation: ['list', 'get'] },
483
+ },
484
+ },
485
+ {
486
+ ...SharedFields_1.additionalFields,
487
+ displayOptions: {
488
+ show: { resource: ['customAttributeDefinition'], operation: ['list', 'get'] },
489
+ },
490
+ },
491
+ {
492
+ displayName: 'Custom Attribute Definition ID',
493
+ name: 'customAttributeDefinitionId',
494
+ type: 'string',
495
+ required: true,
496
+ default: '',
497
+ description: 'The ID of the custom attribute definition',
498
+ displayOptions: {
499
+ show: {
500
+ resource: ['customAttributeDefinition'],
501
+ operation: ['get', 'delete', 'update'],
502
+ },
503
+ },
504
+ },
505
+ {
506
+ displayName: 'Attribute Key',
507
+ name: 'attributeKey',
508
+ type: 'string',
509
+ required: true,
510
+ default: '',
511
+ description: 'Unique key identifier for this attribute (e.g. my_custom_field)',
512
+ placeholder: 'e.g. custom_field_1',
513
+ displayOptions: {
514
+ show: { resource: ['customAttributeDefinition'], operation: ['create'] },
515
+ },
516
+ routing: { send: { type: 'body', property: 'attributeKey' } },
517
+ },
518
+ {
519
+ displayName: 'Attribute Type',
520
+ name: 'attributeType',
521
+ type: 'options',
522
+ required: true,
523
+ default: 'STRING',
524
+ description: 'Data type of the custom attribute',
525
+ displayOptions: {
526
+ show: { resource: ['customAttributeDefinition'], operation: ['create'] },
527
+ },
528
+ options: [
529
+ { name: 'Boolean', value: 'BOOLEAN' },
530
+ { name: 'Date', value: 'DATE' },
531
+ { name: 'Decimal', value: 'DECIMAL' },
532
+ { name: 'Entity', value: 'ENTITY' },
533
+ { name: 'Integer', value: 'INTEGER' },
534
+ { name: 'Large Text', value: 'LARGE_TEXT' },
535
+ { name: 'List', value: 'LIST' },
536
+ { name: 'Multiselect List', value: 'MULTISELECT_LIST' },
537
+ { name: 'Reference', value: 'REFERENCE' },
538
+ { name: 'String', value: 'STRING' },
539
+ { name: 'URL', value: 'URL' },
540
+ ],
541
+ routing: { send: { type: 'body', property: 'attributeType' } },
542
+ },
543
+ {
544
+ displayName: 'Entities',
545
+ name: 'entities',
546
+ type: 'multiOptions',
547
+ required: true,
548
+ default: [],
549
+ description: 'The weclapp entity types this attribute applies to',
550
+ displayOptions: {
551
+ show: { resource: ['customAttributeDefinition'], operation: ['create'] },
552
+ },
553
+ options: [
554
+ { name: 'Article', value: 'article' },
555
+ { name: 'Article Supply Source', value: 'articleSupplySource' },
556
+ { name: 'Batch Number', value: 'batchNumber' },
557
+ { name: 'Blanket Purchase Order', value: 'blanketPurchaseOrder' },
558
+ { name: 'Blanket Sales Order', value: 'blanketSalesOrder' },
559
+ { name: 'Campaign', value: 'campaign' },
560
+ { name: 'Competitor', value: 'competitor' },
561
+ { name: 'Contract', value: 'contract' },
562
+ { name: 'Contract Item', value: 'contractItem' },
563
+ { name: 'CRM Event', value: 'crmEvent' },
564
+ { name: 'Customer', value: 'customer' },
565
+ { name: 'Incoming Goods', value: 'incomingGoods' },
566
+ { name: 'Incoming Goods Item', value: 'incomingGoodsItem' },
567
+ { name: 'Opportunity', value: 'opportunity' },
568
+ { name: 'Parcel', value: 'parcel' },
569
+ { name: 'Party', value: 'party' },
570
+ { name: 'Performance Record', value: 'performanceRecord' },
571
+ { name: 'Performance Record Item', value: 'performanceRecordItem' },
572
+ { name: 'Production Order', value: 'productionOrder' },
573
+ { name: 'Production Order Item', value: 'productionOrderItem' },
574
+ { name: 'Project', value: 'project' },
575
+ { name: 'Purchase Invoice', value: 'purchaseInvoice' },
576
+ { name: 'Purchase Invoice Item', value: 'purchaseInvoiceItem' },
577
+ { name: 'Purchase Order', value: 'purchaseOrder' },
578
+ { name: 'Purchase Order Item', value: 'purchaseOrderItem' },
579
+ { name: 'Purchase Order Request', value: 'purchaseOrderRequest' },
580
+ { name: 'Purchase Order Request Item', value: 'purchaseOrderRequestItem' },
581
+ { name: 'Purchase Requisition', value: 'purchaseRequisition' },
582
+ { name: 'Quotation', value: 'quotation' },
583
+ { name: 'Quotation Item', value: 'quotationItem' },
584
+ { name: 'Recurring Invoice', value: 'recurringInvoice' },
585
+ { name: 'Recurring Invoice Item', value: 'recurringInvoiceItem' },
586
+ { name: 'Sales Invoice', value: 'salesInvoice' },
587
+ { name: 'Sales Invoice Item', value: 'salesInvoiceItem' },
588
+ { name: 'Sales Order', value: 'salesOrder' },
589
+ { name: 'Sales Order Item', value: 'salesOrderItem' },
590
+ { name: 'Serial Number', value: 'serialNumber' },
591
+ { name: 'Service Quota', value: 'serviceQuota' },
592
+ { name: 'Shipment', value: 'shipment' },
593
+ { name: 'Shipment Item', value: 'shipmentItem' },
594
+ { name: 'Storage Location', value: 'storageLocation' },
595
+ { name: 'Storage Place', value: 'storagePlace' },
596
+ { name: 'Supplier', value: 'supplier' },
597
+ { name: 'Task', value: 'task' },
598
+ { name: 'Ticket', value: 'ticket' },
599
+ { name: 'Time Record', value: 'timeRecord' },
600
+ { name: 'Transportation Order', value: 'transportationOrder' },
601
+ { name: 'User', value: 'user' },
602
+ { name: 'Warehouse', value: 'warehouse' },
603
+ { name: 'Warehouse Stock Movement', value: 'warehouseStockMovement' },
604
+ ],
605
+ routing: { send: { type: 'body', property: 'entities' } },
606
+ },
607
+ {
608
+ displayName: 'Label',
609
+ name: 'label',
610
+ type: 'string',
611
+ required: true,
612
+ default: '',
613
+ description: 'Human-readable label shown in the weclapp UI',
614
+ displayOptions: {
615
+ show: { resource: ['customAttributeDefinition'], operation: ['create'] },
616
+ },
617
+ routing: { send: { type: 'body', property: 'label' } },
618
+ },
619
+ {
620
+ displayName: 'Additional Fields',
621
+ name: 'customAttributeDefinitionBody',
622
+ type: 'collection',
623
+ placeholder: 'Add Field',
624
+ default: {},
625
+ displayOptions: {
626
+ show: { resource: ['customAttributeDefinition'], operation: ['create', 'update'] },
627
+ },
628
+ options: [
629
+ {
630
+ displayName: 'Attribute Key',
631
+ name: 'attributeKey',
632
+ type: 'string',
633
+ default: '',
634
+ description: 'Unique key identifier for this attribute',
635
+ routing: { send: { type: 'body', property: 'attributeKey' } },
636
+ },
637
+ {
638
+ displayName: 'Attribute Type',
639
+ name: 'attributeType',
640
+ type: 'string',
641
+ default: '',
642
+ description: 'Data type of the custom attribute (e.g. STRING, BOOLEAN)',
643
+ routing: { send: { type: 'body', property: 'attributeType' } },
644
+ },
645
+ {
646
+ displayName: 'Label',
647
+ name: 'label',
648
+ type: 'string',
649
+ default: '',
650
+ description: 'Human-readable label shown in the weclapp UI',
651
+ routing: { send: { type: 'body', property: 'label' } },
652
+ },
653
+ {
654
+ displayName: 'Mandatory',
655
+ name: 'mandatory',
656
+ type: 'boolean',
657
+ default: false,
658
+ description: 'Whether a value for this attribute is required',
659
+ routing: { send: { type: 'body', property: 'mandatory' } },
660
+ },
661
+ ],
662
+ },
663
+ ];
664
+ //# sourceMappingURL=TagUnitUserDescription.js.map