kfwebmaster
Forum Replies Created
-
I added a temporary fix that I hope will place orders on-hold when this issue is detected, so they don’t get charged the wrong amount:
add_action('woocommerce_order_status_pending_to_processing', 'place_order_with_wrong_total_on_hold', 999, 2);
function place_order_with_wrong_total_on_hold($order_id, $order)
{
$vipps_amount = $order->get_meta('_vipps_amount');
$order_total = $order->get_total()*100;
if ( $vipps_amount - $order_total > 5000 )
{
$order->update_status('on-hold', 'Order total 50 kr less than reserved amount in vipps. ', false);
}
}updating has solved the issue of incorrect values.
I forced the amounts to differ to cause the other issue, and the reserved amount was not released.
so both issues seem to be solved by updating to the latest version.
Great! I’ll let you know when I’ve been able to update and test the new version 🙂
I see. Then it makes sense that it appeared locally, since the local tests had not been to vipps checkout.
We do have some custom code to send data to our CRM on order complete, but it should not change the status or anything. I’ll ask the developers of that integration to take a look.
We found that we can change the order status to “Awaiting payment” and then send the email with order details, and it will then contain a link to a payment page at /kassen/order-pay/12345/?pay_for_order=true&key=wc_order_q1W2e3R4t5Y6
So we can atleast encourage them to pay for their orders, in a very simple way.
Vipps appears as a payment option when I test this locally, but not when I test it on the stage or prod servers :/
All the settings seem to be the same, do you know how to make Vipps appear on the payment page?I’ve sent it.
But I now realize we’re on an older version of the plugin, maybe that is the issue?
Here is a way to reproduce
- number of decimal places set to 0
- VAT of 25%
- product with price 299,- VAT included
- flat rate shipping at price 47,50 and taxable
- result: 358,- is reserved, but order total is 359,-
product price is probably irrelevant, as it seems to be the flat rate shipping causing the rounding error.
No, the orders are not old. The issue can happen even if I complete an order within seconds of placing the order.
Below is a copy of what was added to the log of an order when it was set to “Completed” at 7:44. It seems that the reservation was released within the same action. I think the log order is wrong, since the final status is “On hold”.
Ordrestatus endret fra Behandler til Fullført.
29. September 2025 at 07:44
Ordre 350144: 459.00 NOK er kansellert for å frigjøre reserveringen i kundens bankkonto
29. September 2025 at 07:44
Kunne ikke belaste Vipps-betalingen for denne ordren!
29. September 2025 at 07:44
Kunne ikke belaste Vipps-betalingen – status satt til on-hold Ordrestatus endret fra Fullført til På vent.
29. September 2025 at 07:44
Kunne ikke belaste Vipps-betalingen for denne ordren!
29. September 2025 at 07:44It does release the funds, if we try to capture again we get error 6070 from Vipps; which is that the reserved amount has been released and can no longer be captured.
We only set the status to completed, never to cancelled or refunded.
Forum: Plugins
In reply to: [Pay with Vipps and MobilePay for WooCommerce] vipps checkout stopped workingThank you!
Great! Thank you 🙂
The plugin is out on our webshop and working fine 🙂
Thank you so much for solving this so quickly! 😀
Looks good!
Sounds like a solid solution 🙂
I see. Thanks for the reply 🙂
Great to hear that you are working on it!
I’ve tried using the Vipps Checkout alternative.
This also shows the option for address fields, even though I have checked this option:

The prouduct is set to virtual, if that matters, and I also tried setting it to downloadable, but I still get this option:


We are using this option, which should be correct when address fields are not needed.
According to the vipps docs, this new flow is the only flow:
The docs also suggest that using the Userinfo API will allow for a flow without shipping options. Is this something that can be added to this plugin?
Could be a useful feature for webshops that accept donations, like ours, or sell licenses, digital material, or anything else that doesn’t require shipping.
- This reply was modified 3 years, 2 months ago by kfwebmaster. Reason: more information
no worries, thanks for the quick responses 🙂