#стиль-invoice
1 messages · Page 1 of 1 (latest)
Hi! It's not possible to edit a finalized invoice.
We want to allow users ability to add theirs custom memos,
So you need to do that before finalizing the invoice.
Hello. Yes, I understand that it is impossible to edit a finilazed invoice, but how can I solve this problem? I hope I've explained it well enough.)
This is UX we want to achieve
In fact, we can do without using a subscription and since it is an enterprise plan and we can issue licenses manually using CRM. In this case, only one idea comes to my mind, to calculate the price for the user not through the stripe price, but simply on the server. It turns out that we can use the usual payment_intent for payment by card, and for payment by invoice generate a new invoice every time if the Purchase order number changes. What do you think about this?
I'm still trying to understand the issue. Are you saying that once you create the subscription, the invoice is already finalized so it's not possible to edit it?
For stripe's Payment element we need to have client_secret, right? This client_secret we can grab from invoice, but invoice cannot be paid before it is finalized, right? So for stripe's Payment element we need to finalize that invoice, but problem is only in memo. Because invoice is finalized even before user is getting on this page, we can't modify invoice's description, so we can't user's provided memo
We can edit invoice after subscription is created, but for Payment by card we need to finalize it or Payment by card won't work at all, because we wouldn't have client_secret for it
Got it, now I understand! So you have a few options:
- Ask for the memo before showing the PaymentElement
- Or delay the finalization of the invoice. There are two ways to do this:
- create a very short trial (like a few seconds), this way the first invoice will have a draft status and can be edited.
- use a subscription schedule to create the subscription, in this case the first invoice will also be created as draft https://stripe.com/docs/billing/subscriptions/subscription-schedules
Ok, got it, thanks! So your solution is to move Purchase order number field to green box(on second screenshot) before user even get's on third step "Payment Details", yes?
So your solution is to move Purchase order number field to green box(on second screenshot) before user even get's on third step "Payment Details", yes?
That's the simplest option yes! The other option is to make the first invoice editable like I mentioned (with a trial or with subscription schedule).