Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Steur <thomas.steur@googlemail.com>2014-08-11 11:57:28 +0400
committerThomas Steur <thomas.steur@googlemail.com>2014-08-11 11:57:28 +0400
commita8830625aafabb479486cbdf5f6dfe5215bfed9d (patch)
treeb6584a52d182f13f2b1973b7ac105047b67313dc /plugins
parentf5eab966ab2ff98417dc75c9e359146afd15963d (diff)
fixes #5961 radio fields were not selected when editing a goal
Diffstat (limited to 'plugins')
-rw-r--r--plugins/Goals/javascripts/goalsForm.js4
-rw-r--r--plugins/Morpheus/javascripts/morpheus.js1
2 files changed, 5 insertions, 0 deletions
diff --git a/plugins/Goals/javascripts/goalsForm.js b/plugins/Goals/javascripts/goalsForm.js
index 7b2d78581b..643a9ce3af 100644
--- a/plugins/Goals/javascripts/goalsForm.js
+++ b/plugins/Goals/javascripts/goalsForm.js
@@ -59,6 +59,10 @@ function initGoalForm(goalMethodAPI, submitText, goalName, matchAttribute, patte
if (goalId != undefined) {
$('input[name=goalIdUpdate]').val(goalId);
}
+
+ // force re-run of iCheck. They were already initialized with all radio fields not selected. see #5961
+ $('.entityAddContainer div.form-radio').removeClass('form-radio');
+ $(document).trigger('Goals.edit', {});
}
function bindGoalForm() {
diff --git a/plugins/Morpheus/javascripts/morpheus.js b/plugins/Morpheus/javascripts/morpheus.js
index 4b7a295c49..e3fd78eadc 100644
--- a/plugins/Morpheus/javascripts/morpheus.js
+++ b/plugins/Morpheus/javascripts/morpheus.js
@@ -18,6 +18,7 @@ $(document).ready(function () {
initICheck();
$(document).bind('ScheduledReport.edit', initICheck);
+ $(document).bind('Goals.edit', initICheck);
$(broadcast).bind('locationChangeSuccess', initICheck);
$('body').on('ifClicked', 'input', function () {