diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2011-11-22 17:33:09 +0100 |
---|---|---|
committer | Endi S. Dewata <edewata@redhat.com> | 2011-12-05 16:00:50 +0000 |
commit | e0215421208d853e853f9c7b66add1e145982fbc (patch) | |
tree | f2d9d495dbe4f839f5b65a3348c0e11f8ac25d9a /install/ui/sudo.js | |
parent | 6cdf09812dd13531acb29f1413de87ce7cd5218f (diff) | |
download | freeipa-e0215421208d853e853f9c7b66add1e145982fbc.tar.gz freeipa-e0215421208d853e853f9c7b66add1e145982fbc.tar.xz freeipa-e0215421208d853e853f9c7b66add1e145982fbc.zip |
Removing sections as special type of object
Sections are changed into pure widget objects. Introduced IPA.composite_widget, basic widget for widget nesting (it's using IPA.widget_container). It's base class for section widgets.
TODO: change old custom sections into custom fields and widgets.
Note: usage of section in HBAC and SUDO is kept - whole logic will be removed in #1515 patch.
https://fedorahosted.org/freeipa/ticket/2040
Diffstat (limited to 'install/ui/sudo.js')
-rw-r--r-- | install/ui/sudo.js | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/install/ui/sudo.js b/install/ui/sudo.js index 862478c60..01bb3eed1 100644 --- a/install/ui/sudo.js +++ b/install/ui/sudo.js @@ -830,7 +830,7 @@ IPA.sudo.rule_details_command_section = function(spec) { that.container = container; - var field = that.get_field('cmdcategory'); + var field = that.fields.get_field('cmdcategory'); var metadata = IPA.get_entity_param(that.entity.name, 'cmdcategory'); var span = $('<span/>', { @@ -857,7 +857,7 @@ IPA.sudo.rule_details_command_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('memberallowcmd_sudocmd'); + field = that.fields.get_field('memberallowcmd_sudocmd'); field.create(table_span); metadata = IPA.get_entity_param( @@ -869,7 +869,7 @@ IPA.sudo.rule_details_command_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('memberallowcmd_sudocmdgroup'); + field = that.fields.get_field('memberallowcmd_sudocmdgroup'); field.create(table_span); $('<h3/>', { @@ -886,7 +886,7 @@ IPA.sudo.rule_details_command_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('memberdenycmd_sudocmd'); + field = that.fields.get_field('memberdenycmd_sudocmd'); field.create(table_span); metadata = IPA.get_entity_param( @@ -898,21 +898,21 @@ IPA.sudo.rule_details_command_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('memberdenycmd_sudocmdgroup'); + field = that.fields.get_field('memberdenycmd_sudocmdgroup'); field.create(table_span); function update_tables(value) { var enabled = ('' === value); - var field = that.get_field('memberallowcmd_sudocmd'); + var field = that.fields.get_field('memberallowcmd_sudocmd'); field.set_enabled(enabled); - field = that.get_field('memberallowcmd_sudocmdgroup'); + field = that.fields.get_field('memberallowcmd_sudocmdgroup'); field.set_enabled(enabled); } - var cmdcategory = that.get_field('cmdcategory'); + var cmdcategory = that.fields.get_field('cmdcategory'); cmdcategory.reset = function() { cmdcategory.widget_reset(); var values = cmdcategory.save(); @@ -1007,7 +1007,7 @@ IPA.sudo.rule_details_runas_section = function(spec) { that.create = function(container) { that.container = container; - var field = that.get_field('ipasudorunasusercategory'); + var field = that.fields.get_field('ipasudorunasusercategory'); var metadata = IPA.get_entity_param( that.entity.name, 'ipasudorunasusercategory'); @@ -1028,7 +1028,7 @@ IPA.sudo.rule_details_runas_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('ipasudorunas_user'); + field = that.fields.get_field('ipasudorunas_user'); field.create(table_span); metadata = IPA.get_entity_param(that.entity.name, 'ipasudorunas_group'); @@ -1039,10 +1039,10 @@ IPA.sudo.rule_details_runas_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('ipasudorunas_group'); + field = that.fields.get_field('ipasudorunas_group'); field.create(table_span); - field = that.get_field('ipasudorunasgroupcategory'); + field = that.fields.get_field('ipasudorunasgroupcategory'); metadata = IPA.get_entity_param( that.entity.name, 'ipasudorunasgroupcategory'); @@ -1065,21 +1065,21 @@ IPA.sudo.rule_details_runas_section = function(spec) { 'class': 'field' }).appendTo(span); - field = that.get_field('ipasudorunasgroup_group'); + field = that.fields.get_field('ipasudorunasgroup_group'); field.create(table_span); function user_update_tables(value) { var enabled = ('' === value); - var field = that.get_field('ipasudorunas_user'); + var field = that.fields.get_field('ipasudorunas_user'); field.set_enabled(enabled); - field = that.get_field('ipasudorunas_group'); + field = that.fields.get_field('ipasudorunas_group'); field.set_enabled(enabled); } - var user_category = that.get_field('ipasudorunasusercategory'); + var user_category = that.fields.get_field('ipasudorunasusercategory'); user_category.reset = function() { user_category.widget_reset(); var values = user_category.save(); @@ -1099,11 +1099,11 @@ IPA.sudo.rule_details_runas_section = function(spec) { var enabled = ('' === value); - var field = that.get_field('ipasudorunasgroup_group'); + var field = that.fields.get_field('ipasudorunasgroup_group'); field.set_enabled(enabled); } - var group_category = that.get_field('ipasudorunasgroupcategory'); + var group_category = that.fields.get_field('ipasudorunasgroupcategory'); group_category.reset = function() { group_category.widget_reset(); var values = group_category.save(); |