New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Minor tweaks and events in Goals UI #10844
Conversation
&& action != 'ecommerceReport' | ||
&& action != 'products' | ||
&& action != 'sales' | ||
&& (''+ ajaxUrl).indexOf('&idGoal=') === -1) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When idGoal is specifically requested, we still need to keep it
@@ -29,7 +29,8 @@ function hideForms() { | |||
|
|||
function showCancel() { | |||
$(".entityCancel").show(); | |||
$('.entityCancelLink').click(function () { | |||
$('.entityCancelLink').off('click').click(function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We always attached a new event listener when opening a goal but instead need to remove previously added once first
@@ -153,7 +157,7 @@ function ajaxDeleteGoal(idGoal) { | |||
ajaxRequest.addParams(parameters, 'get'); | |||
ajaxRequest.setLoadingElement('#goalAjaxLoading'); | |||
ajaxRequest.setCallback(function () { location.reload(); }); | |||
ajaxRequest.send(true); | |||
ajaxRequest.send(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was sent synchronously which should be avoided at all costs
ping @mattab