From 001ee55403e897598645f326c05f8cea1542bc55 Mon Sep 17 00:00:00 2001 From: Martijn Date: Tue, 17 Oct 2023 13:47:56 +0200 Subject: [PATCH 1/2] fix(picqer): added email and telephone to order for guest orders --- packages/vendure-plugin-picqer/package.json | 2 +- packages/vendure-plugin-picqer/src/api/picqer.service.ts | 2 ++ packages/vendure-plugin-picqer/src/api/types.ts | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/vendure-plugin-picqer/package.json b/packages/vendure-plugin-picqer/package.json index c7338cde..d6d1485e 100644 --- a/packages/vendure-plugin-picqer/package.json +++ b/packages/vendure-plugin-picqer/package.json @@ -1,6 +1,6 @@ { "name": "@pinelab/vendure-plugin-picqer", - "version": "1.0.7", + "version": "1.0.8", "description": "Vendure plugin syncing to orders and stock with Picqer", "author": "Martijn van de Brug ", "homepage": "https://pinelab-plugins.com/", diff --git a/packages/vendure-plugin-picqer/src/api/picqer.service.ts b/packages/vendure-plugin-picqer/src/api/picqer.service.ts index 22a0d6ca..ca7ca5f5 100644 --- a/packages/vendure-plugin-picqer/src/api/picqer.service.ts +++ b/packages/vendure-plugin-picqer/src/api/picqer.service.ts @@ -1104,6 +1104,8 @@ export class PicqerService implements OnApplicationBootstrap { return { idcustomer: customerId, // If none given, this creates a guest order reference: order.code, + emailaddress: order.customer?.emailAddress ?? '', + telephone: order.customer?.phoneNumber ?? '', deliveryname: shippingAddress.company || shippingAddress.fullName, deliverycontactname: shippingAddress.fullName === customerFullname diff --git a/packages/vendure-plugin-picqer/src/api/types.ts b/packages/vendure-plugin-picqer/src/api/types.ts index bc48ea67..a6a9f96b 100644 --- a/packages/vendure-plugin-picqer/src/api/types.ts +++ b/packages/vendure-plugin-picqer/src/api/types.ts @@ -206,6 +206,8 @@ export interface Product { export interface OrderInput { idcustomer?: number; reference: string; + emailaddress: string; + telephone: string; deliveryname?: string; deliverycontactname?: string; deliveryaddress?: string; From 617ce369fbd45429cacfb52aa46f8daaa39a72de Mon Sep 17 00:00:00 2001 From: Martijn Date: Tue, 17 Oct 2023 13:48:45 +0200 Subject: [PATCH 2/2] fix(picqer): added email and telephone to order for guest orders --- packages/vendure-plugin-picqer/CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/vendure-plugin-picqer/CHANGELOG.md b/packages/vendure-plugin-picqer/CHANGELOG.md index 61cf1e1a..ba159553 100644 --- a/packages/vendure-plugin-picqer/CHANGELOG.md +++ b/packages/vendure-plugin-picqer/CHANGELOG.md @@ -1,3 +1,7 @@ +# 1.0.8 + +- Send telephone and email address to Picqer for guest orders + # 1.0.7 - Don't set contact name in Picqer if it's the same as customer name ([#267](https://github.com/Pinelab-studio/pinelab-vendure-plugins/pull/267))