#smilelari_unexpected

1 messages ยท Page 1 of 1 (latest)

urban oceanBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฑ๏ธ We automatically close idle threads, which makes them read-only. Make sure you stick around to chat in realtime!

๐Ÿ”— This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1212430861811585215

๐Ÿ“ Have more to share? You can add more detail below, including code, screenshots, videos, etc.

โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question. Thank you for your patience!

warped dustBOT
spare garnet
#

Hello, do you have the ID of the invoice that this happened on?

sage isle
#

in_1OodkcEwYEdSC6hPymlNwC5V

spare garnet
#

Ah, so the customer already had proration invoice items on them and you didn't want those included on this one-off invoice?

sage isle
#

All of our invoices are one-off invoices and we want the proration to show, we just want the invoice to never be negative

spare garnet
#

What are you prorating if your invoices are always one-off?

#

Are you manually creating these proration items?

sage isle
#

We do all of the calculations on our side. Yes, we manually create all of our invoice items

spare garnet
#

Gotcha, I am unsure if it is possible to 0 out those proration items without deleting them. I will consult my coleagues and get back to you

sage isle
#

Thanks!

nova valve
#

๐Ÿ‘‹ stepping in and taking a look.

#

Yeah you can't really change this behavior here -- it overall does make sense that you wouldn't lose out on your credits as a Customer (the proration) because you had a coupon applied. That coupon really is just going to apply to the positive items involved.

That all said, I'm a bit confused here... you are creating these proration items yourself as this is all your own logic. So if you don't want the Invoice to be for a negative amount, then you would remove these proration items and just have the coupon apply to make it $0.

sage isle
#

We still want the customer to see overall what happened when they switched plans

nova valve
#

Really by "remove", I mean not create them in the first place.

sage isle
#

And on our end we have no idea who is in the 100% off bucket and who isn't

nova valve
#

Yeah that's not really true -- you can always check if the Customer has this 100% off coupon applied before creating the Invoice/Invoice Items.

#

If you want to still have the line items then you should create $0 Invoice Items in this case.

sage isle
#

Ok. The prorations as they are will always result in a negative invoice if a 100% off coupon is also applied, so to get the $0 invoice, either add these lines with a price of $0 or don't add them at all

nova valve
#

Yep that's really the only way forward if you don't want an applied Credit Balance from the Invoice.

#

You could also always reset the Credit Balance immediately afterwards.

#

If you don't want to change what the Invoice looks like. That is just confusing for the Customer though since it indicates they got an Applied Balance when they won't actually receive that.