https://fedorahosted.org/freeipa/ticket/1767
Opening IPA Server/Entitlements causes: "Uncaught TypeError: Cannot call method 'addClass' of undefined" error - Details.js:489
-- Petr Vobornik
From 17a3dbed887a75fa1ff0198edb5ae9873b1b35a3 Mon Sep 17 00:00:00 2001 From: Petr Vobornik <pvobo...@redhat.com> Date: Wed, 7 Sep 2011 18:19:01 +0200 Subject: [PATCH] Fixed: JavaScript type error in entitlement page https://fedorahosted.org/freeipa/ticket/1767 Opening IPA Server/Entitlements causes: "Uncaught TypeError: Cannot call method 'addClass' of undefined" error - Details.js:489 Introduced by patch for #1697 Cause: Details facet of entitlements doesn't contain Reset and Update buttons --- install/ui/details.js | 20 ++++++++++++++------ 1 files changed, 14 insertions(+), 6 deletions(-) diff --git a/install/ui/details.js b/install/ui/details.js index 4f7e4a29a432f225dc2b652a0e94f98529b84d35..dbdca5a1dae32d3110bec99ee0bc3c2f80db2c0a 100644 --- a/install/ui/details.js +++ b/install/ui/details.js @@ -482,12 +482,20 @@ IPA.details_facet = function(spec) { }; that.enable_update = function(value) { - if(value) { - that.reset_button.removeClass('action-button-disabled'); - that.update_button.removeClass('action-button-disabled'); - } else { - that.reset_button.addClass('action-button-disabled'); - that.update_button.addClass('action-button-disabled'); + if(that.reset_button) { + if(value) { + that.reset_button.removeClass('action-button-disabled'); + } else { + that.reset_button.addClass('action-button-disabled'); + } + } + + if(that.update_button) { + if(value) { + that.update_button.removeClass('action-button-disabled'); + } else { + that.update_button.addClass('action-button-disabled'); + } } }; -- 1.7.6
_______________________________________________ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel