From 379a9cc41f04d36538aee11839c1222d408b4f99 Mon Sep 17 00:00:00 2001 From: "Endi S. Dewata" Date: Thu, 18 Nov 2010 20:17:14 -0600 Subject: SUDO Rule Search and Details Pages The search and details pages for SUDO Rule have been added. Codes that are shared with HBAC have been moved to rule.js. The following methods were renamed for consistency: - ipa_details_load() -> ipa_details_refresh() - ipa_details_display() -> ipa_details_load() The ipa_details_cache has been removed because the cache is now stored in each widget. The index.xhtml has been removed. All references to it has been changed to index.html. The Unselect All checkbox has been fixed. Unnecessary parameter 'container' has been removed. The unit test has been updated and new test data has been added. --- install/static/associate.js | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) (limited to 'install/static/associate.js') diff --git a/install/static/associate.js b/install/static/associate.js index 7dd81cae..f0239a44 100644 --- a/install/static/associate.js +++ b/install/static/associate.js @@ -257,7 +257,10 @@ function ipa_association_widget(spec) { that.superior_create(container); - var ul = $('.action-panel ul'); + var entity_container = $('#' + that.entity_name); + var action_panel = $('.action-panel', entity_container); + + var ul = $('ul', action_panel); var li = $('
  • ').appendTo(ul); // creating generic buttons for layout @@ -324,11 +327,11 @@ function ipa_association_widget(spec) { 'associator': that.associator, 'method': that.add_method, 'on_success': function() { - that.refresh(that.container); + that.refresh(); dialog.close(); }, 'on_error': function() { - that.refresh(that.container); + that.refresh(); dialog.close(); } }); @@ -360,11 +363,11 @@ function ipa_association_widget(spec) { 'associator': that.associator, 'method': that.delete_method, 'on_success': function() { - that.refresh(that.container); + that.refresh(); dialog.close(); }, 'on_error': function() { - that.refresh(that.container); + that.refresh(); dialog.close(); } }); @@ -374,7 +377,7 @@ function ipa_association_widget(spec) { dialog.open(that.container); }; - that.refresh = function(container) { + that.refresh = function() { function on_success(data, text_status, xhr) { @@ -390,7 +393,7 @@ function ipa_association_widget(spec) { for (var i = 0; i