n8n-nodes-prestashop8 2.0.3 → 2.0.5

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.
@@ -338,6 +338,18 @@ class PrestaShop8 {
338
338
  const items = this.getInputData();
339
339
  const returnData = [];
340
340
  const credentials = await this.getCredentials('prestaShop8Api');
341
+ // Normalize base URL: ensure it ends with /api and has no trailing slash
342
+ let baseUrl = credentials.baseUrl.trim();
343
+ // Remove trailing slash if present
344
+ if (baseUrl.endsWith('/')) {
345
+ baseUrl = baseUrl.slice(0, -1);
346
+ }
347
+ // Add /api if not present
348
+ if (!baseUrl.endsWith('/api')) {
349
+ baseUrl = baseUrl + '/api';
350
+ }
351
+ // Update credentials with normalized URL
352
+ credentials.baseUrl = baseUrl;
341
353
  // Récupérer directement la ressource et l'opération
342
354
  const resource = this.getNodeParameter('resource', 0);
343
355
  const operation = this.getNodeParameter('operation', 0);
@@ -1549,6 +1549,14 @@ exports.RESOURCE_SCHEMAS = {
1549
1549
  },
1550
1550
  },
1551
1551
  'orders': {
1552
+ 'reference': {
1553
+ type: 'string',
1554
+ format: 'isReference',
1555
+ required: false,
1556
+ readOnly: false,
1557
+ multilang: false,
1558
+ maxSize: 9,
1559
+ },
1552
1560
  'id_address_delivery': {
1553
1561
  type: 'number',
1554
1562
  format: 'isUnsignedId',
@@ -204,6 +204,17 @@ exports.PRESTASHOP_RESOURCES = {
204
204
  supportsGetById: true,
205
205
  supportsSearch: true,
206
206
  },
207
+ order_carriers: {
208
+ name: 'order_carriers',
209
+ displayName: 'Order Carriers',
210
+ description: 'Transporteurs associés aux commandes',
211
+ supportsCreate: true,
212
+ supportsUpdate: true,
213
+ supportsDelete: true,
214
+ supportsList: true,
215
+ supportsGetById: true,
216
+ supportsSearch: true,
217
+ },
207
218
  carts: {
208
219
  name: 'carts',
209
220
  displayName: 'Carts',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-prestashop8",
3
- "version": "2.0.3",
3
+ "version": "2.0.5",
4
4
  "description": "Nœud n8n personnalisé pour PrestaShop 8 avec support CRUD complet et conversion XML/JSON automatique",
5
5
  "keywords": [
6
6
  "n8n-community-node-package",