From 4f6db827e7faa275e29c68a5bbfa7b356f72a5be Mon Sep 17 00:00:00 2001 From: Allan Carr Date: Mon, 6 Oct 2025 17:50:19 -0700 Subject: [PATCH] IO-3395 Postback Payment Date Signed-off-by: Allan Carr --- server/graphql-client/queries.js | 3 +++ server/intellipay/lib/handleCommentBasedPayment.js | 2 +- server/intellipay/lib/handleInvoiceBasedPayment.js | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/server/graphql-client/queries.js b/server/graphql-client/queries.js index 9a3bb1d6e..e5a79fd25 100644 --- a/server/graphql-client/queries.js +++ b/server/graphql-client/queries.js @@ -2859,6 +2859,7 @@ exports.GET_BODYSHOP_BY_ID = ` intellipay_config state notification_followers + timezone } } `; @@ -2950,6 +2951,7 @@ query GET_JOBID_BY_MERCHANTID_RONUMBER($merchantID: String!, $roNumber: String!) id intellipay_config email + timezone } } }`; @@ -2959,6 +2961,7 @@ query GET_BODYSHOP_BY_MERCHANTID($merchantID: String!) { bodyshops(where: {intellipay_merchant_id: {_eq: $merchantID}}) { id email + timezone } }`; diff --git a/server/intellipay/lib/handleCommentBasedPayment.js b/server/intellipay/lib/handleCommentBasedPayment.js index 535e92ab8..af862c7a1 100644 --- a/server/intellipay/lib/handleCommentBasedPayment.js +++ b/server/intellipay/lib/handleCommentBasedPayment.js @@ -48,7 +48,7 @@ const handleCommentBasedPayment = async (values, decodedComment, logger, logMeta payer: "Customer", type: getPaymentType(ipMapping, values.cardtype), jobid: p.jobid, - date: moment(Date.now()), + date: moment(Date.now()).tz(bodyshop.bodyshops_by_pk.timezone || "UTC"), payment_responses: { data: { amount: values.total, diff --git a/server/intellipay/lib/handleInvoiceBasedPayment.js b/server/intellipay/lib/handleInvoiceBasedPayment.js index d5fc97b9c..aca480d5f 100644 --- a/server/intellipay/lib/handleInvoiceBasedPayment.js +++ b/server/intellipay/lib/handleInvoiceBasedPayment.js @@ -97,7 +97,7 @@ const handleInvoiceBasedPayment = async (values, logger, logMeta, res) => { payer: "Customer", type: getPaymentType(ipMapping, values.cardtype), jobid: job.id, - date: moment(Date.now()) + date: moment(Date.now()).tz(bodyshop.timezone || "UTC") } });