Date Manipulation, 20th following month

Status: Closed · Asked by leeogrady on · 0 views

leeogrady — Question ·

Hi,

I am generating invoice in to Xero from shopify.
I can pass the date from Shopify, or use the date add function to add X days, but I want to have 20th of the following month (account terms)

eg Shopify order created: '2022-11-07.....', I want to put '2022-12-20....' into Xero.

Cheers
Lee

Pabblymember11 — Reply ·

Hey @leeogrady

I am generating invoice in to Xero from shopify.
I can pass the date from Shopify, or use the date add function to add X days, but I want to have 20th of the following month (account terms)

For your concern, we would recommend you use the "Date/Time Formatter by Pabbly: Add/Subtract Time" to add or subtract the time.

youtube.com/watch?v=XpRkxwytOOg

leeogrady — Reply ·

Thanks @Supreme, This is what i am using but it does not meet the requirements.
eg, i use the above app and set '+30 days'
on the 7th November this will make it '7th December' - incorrect, I want '20th December'
on the 30th January (2023) this will make it '1st March' - incorrect, I want this to be '20th February'

Credit terms of '20th of the month following invoice' are quite common, i would expect this would be a useful feature for many businesses.

Cheers
Lee

Pabblymember11 — Reply ·
on the 7th November this will make it '7th December' - incorrect, I want '20th December'

If you want 20th December then add 43 days to it.

on the 30th January (2023) this will make it '1st March' - incorrect, I want this to be '20th February'

And if you want 20 the Feb then add 20 days to it.

youtube.com/watch?v=XpRkxwytOOg

leeogrady — Reply ·

LOLLLLL. Sorry.

How can I do this automatically when the source date changes - every day...
Customers order every day, should I modify the flow every day to be one less day until a new month and then set the number higher again?

I need to be able to say +1month, and force it to be the 20th.

Cheers
Lee

leeogrady — Reply ·

Thanks Supreme. Router looks like a powerful step /function. The example is not quite doing what I am after but I think theres potential there. Will investigate more based on this example and post what i find.
cheers
Lee

Pabblymember11 — Reply ·

You can also refer to the following video tutorial on how you can use the Router action step.

youtube.com/watch?v=6XDASZVv3tw

leeogrady — Reply ·

Solution;
First use;

then use

Hope this helps others!

Back to all forum threads · Log in to reply