Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
1391 Представления

I created a transaction route which calls 

request.website.sale_reset()
return request.redirect('/test/success')

 then I have a route

@http.route(['/test/success'], type='http', auth="public", website=True, sitemap=False, save_session=False)
def shop_payment_confirmation(self, **post):
sale_order_id = request.session.get('sale_last_order_id')
if sale_order_id:
order = request.env['sale.order'].sudo().browse(sale_order_id)
return request.render("test.confirmation", {
'order': order,
})
else:
return request.redirect('/shop')

Everything is fine, however, the cart still showed the quantity. Then I tried to click on the cart and it said it was empty. So I guess the cart was actually cleared, but this is not a great user experience. I wonder why this is happening.


Аватар
Отменить
Related Posts Ответы Просмотры Активность
2
окт. 25
2736
1
сент. 25
2748
3
июл. 25
4124
1
мая 25
2213
4
мая 25
3582