mirror of https://github.com/OCA/social.git
[FIX] mass_mailing_custom_unsubscribe: Added the changes to avoid the linter warnings
parent
28db3c57d0
commit
80eb0afecd
|
@ -8,7 +8,7 @@ odoo.define("mass_mailing_custom_unsubscribe.contact_tour",
|
|||
|
||||
// Allow to know if an element is required
|
||||
$.extend($.expr[':'], {
|
||||
propRequired: function(element, index, matches) {
|
||||
propRequired: function (element) {
|
||||
return $(element).prop("required");
|
||||
},
|
||||
});
|
||||
|
@ -27,7 +27,8 @@ odoo.define("mass_mailing_custom_unsubscribe.contact_tour",
|
|||
},
|
||||
{
|
||||
content: "Switch to not interested reason",
|
||||
trigger: ".radio:contains(\"I'm not interested\") :radio:not(:checked)",
|
||||
trigger:
|
||||
".radio:contains(\"I'm not interested\") :radio:not(:checked)",
|
||||
extra_trigger: "[name='details']:propRequired",
|
||||
},
|
||||
{
|
||||
|
@ -74,20 +75,28 @@ odoo.define("mass_mailing_custom_unsubscribe.contact_tour",
|
|||
},
|
||||
{
|
||||
content: "Successfully unsubscribed",
|
||||
trigger: "#subscription_info:contains('Your changes have been saved.')",
|
||||
trigger:
|
||||
"#subscription_info:contains('Your changes have been saved.')",
|
||||
},
|
||||
{
|
||||
content: "Subscribe again to list 0",
|
||||
trigger: "body:not(:has(#unsubscribe_form #custom_div_feedback:visible)):has(.alert-success) li:contains('test list 0') input:not(:checked)",
|
||||
// eslint-disable-next-line no-multi-str
|
||||
trigger:"body:not(:has(#unsubscribe_form #custom_div_feedback\
|
||||
:visible)):has(.alert-success) li:contains('test list 0') \
|
||||
input:not(:checked)",
|
||||
},
|
||||
{
|
||||
content: "Update subscriptions 3nd time",
|
||||
trigger: "#unsubscribe_form:not(:has(.js_unsubscription_reason:visible)) :submit",
|
||||
// eslint-disable-next-line no-multi-str
|
||||
trigger:"#unsubscribe_form:not(\
|
||||
:has(.js_unsubscription_reason:visible)) :submit",
|
||||
},
|
||||
{
|
||||
content: "Successfully subscribed",
|
||||
trigger: "#subscription_info:contains('Your changes have been saved.')",
|
||||
trigger:
|
||||
"#subscription_info:contains('Your changes have been saved.')",
|
||||
},
|
||||
]
|
||||
);
|
||||
});
|
||||
}
|
||||
);
|
||||
|
|
|
@ -8,7 +8,7 @@ odoo.define("mass_mailing_custom_unsubscribe.partner_tour",
|
|||
|
||||
// Allow to know if an element is required
|
||||
$.extend($.expr[':'], {
|
||||
propRequired: function(element, index, matches) {
|
||||
propRequired: function (element) {
|
||||
return $(element).prop("required");
|
||||
},
|
||||
});
|
||||
|
@ -27,7 +27,9 @@ odoo.define("mass_mailing_custom_unsubscribe.partner_tour",
|
|||
},
|
||||
{
|
||||
content: "Switch to not interested reason",
|
||||
trigger: ".radio:contains(\"I'm not interested\") :radio:not(:checked)",
|
||||
// eslint-disable-next-line no-multi-str
|
||||
trigger: ".radio:contains(\"I'm not interested\") \
|
||||
:radio:not(:checked)",
|
||||
extra_trigger: "[name='details']:propRequired",
|
||||
},
|
||||
{
|
||||
|
@ -42,4 +44,5 @@ odoo.define("mass_mailing_custom_unsubscribe.partner_tour",
|
|||
},
|
||||
]
|
||||
);
|
||||
});
|
||||
}
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue