From 82b03ddfc16164a13bf1ffc531255496e8b72e25 Mon Sep 17 00:00:00 2001 From: Adam Young Date: Tue, 21 Dec 2010 15:14:08 -0500 Subject: hidden filter The filter field on aci add is hidden, and prefilled with an object class that doesn't exist. Fixed the error where the other fields were removed --- install/static/aci.js | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) (limited to 'install/static/aci.js') diff --git a/install/static/aci.js b/install/static/aci.js index f31449f0..43fa8f0f 100644 --- a/install/static/aci.js +++ b/install/static/aci.js @@ -260,6 +260,28 @@ IPA.rights_widget = function(spec){ return that; } +IPA.hidden_widget = function(spec){ + spec.label = ''; + var that = ipa_widget(spec); + that.id = spec.id; + var value = spec.value || ''; + that.create = function(container){ + $('',{ + type:'hidden', + 'id':that.id, + value: value + }). + appendTo(container); + } + + that.save = function(){ + return [value]; + } + that.reset = function(){ + + } + return that; +} @@ -600,9 +622,8 @@ function ipa_permission_add_dialog(spec) { })); that.add_field(IPA.rights_widget({name:'permissions'})); - that.add_field(ipa_text_widget({name:'filter'})); + that.add_field(IPA.hidden_widget({name:'filter','value':'objectClass=changethisvalue'})); that.add_dialog_init(); - }; -- cgit