[REV] website_sale: set Cart recovery back in form view
Partially reverts d781d6f6ea504dcc89f412b94774df6bd08c78aa Indeed modified tour has to go through various list view actions and is likely to crash because of some complicated triggers to write. Let us have the recovery action back to form view. Anyway it makes no harm to have it available in action menu. LINKS Task 1978729 PR #35061
This commit is contained in:
@@ -31,6 +31,8 @@ tour.register('shop_cart_recovery', {
|
||||
'method': 'sale_get_order',
|
||||
'args': [[$('html').data('website-id')]],
|
||||
}).then(function (data) {
|
||||
var orderId = parseInt(data.match(/sale\.order\((\d+),\)/)[1]);
|
||||
localStorage.setItem(orderIdKey, orderId);
|
||||
window.location.href = "/web/session/logout?redirect=/web/login";
|
||||
});
|
||||
},
|
||||
@@ -39,7 +41,8 @@ tour.register('shop_cart_recovery', {
|
||||
content: "login as admin and go to the SO (backend)",
|
||||
trigger: '.oe_login_form',
|
||||
run: function () {
|
||||
var url = "/web#action=website_sale.action_orders_ecommerce&view_type=list";
|
||||
var orderId = localStorage.getItem(orderIdKey);
|
||||
var url = "/web#action=sale.action_orders&view_type=form&id=" + orderId;
|
||||
var $loginForm = $('.oe_login_form');
|
||||
$loginForm.find('input[name="login"]').val("admin");
|
||||
$loginForm.find('input[name="password"]').val("admin");
|
||||
@@ -47,14 +50,6 @@ tour.register('shop_cart_recovery', {
|
||||
$loginForm.submit();
|
||||
},
|
||||
},
|
||||
{
|
||||
content: "remove filter Confirmed Orders",
|
||||
trigger: '.o_searchview_input_container .o_searchview_facet:first .o_facet_remove'
|
||||
},
|
||||
{
|
||||
content: "select the order",
|
||||
trigger: 'tbody tr:first .o_list_record_selector input[type="checkbox"]',
|
||||
},
|
||||
{
|
||||
content: "click action",
|
||||
trigger: '.btn:containsExact("Action")',
|
||||
@@ -67,10 +62,6 @@ tour.register('shop_cart_recovery', {
|
||||
content: "click Send email",
|
||||
trigger: '.btn[name="action_send_mail"]',
|
||||
},
|
||||
{
|
||||
content: "click on the order",
|
||||
trigger: '.o_data_row:first',
|
||||
},
|
||||
{
|
||||
content: "check the mail is sent, grab the recovery link, and logout",
|
||||
trigger: '.o_thread_message_content a:containsExact("Resume order")',
|
||||
|
||||
@@ -141,7 +141,7 @@
|
||||
action = records.action_recovery_email_send()
|
||||
</field>
|
||||
<field name="binding_model_id" ref="sale.model_sale_order"/>
|
||||
<field name="binding_view_types">list</field>
|
||||
<field name="binding_view_types">list,form</field>
|
||||
</record>
|
||||
|
||||
<record id="action_view_unpaid_quotation_tree" model="ir.actions.act_window">
|
||||
|
||||
Reference in New Issue
Block a user