diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2012-09-18 17:12:59 +0200 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2012-09-17 21:24:38 -0400 |
commit | e39a109060ce8b92919c00aebd83a682a039d9b5 (patch) | |
tree | 22e9b1de47f2bba27a60fc51c7a4667967005e6a /install/ui/trust.js | |
parent | 7269687822b019c209ed759ba42641586abcb2b0 (diff) | |
download | freeipa-e39a109060ce8b92919c00aebd83a682a039d9b5.tar.gz freeipa-e39a109060ce8b92919c00aebd83a682a039d9b5.tar.xz freeipa-e39a109060ce8b92919c00aebd83a682a039d9b5.zip |
Show trust status in add success notification
Web UI notification of 'Add verification step after trust creation'
https://fedorahosted.org/freeipa/ticket/2763
Diffstat (limited to 'install/ui/trust.js')
-rw-r--r-- | install/ui/trust.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/install/ui/trust.js b/install/ui/trust.js index 77e7cb381..939bb59a3 100644 --- a/install/ui/trust.js +++ b/install/ui/trust.js @@ -71,6 +71,7 @@ IPA.trust.entity = function(spec) { ] }). adder_dialog({ + factory: IPA.trust.adder_dialog, fields: [ { name: 'cn', @@ -162,4 +163,21 @@ IPA.trust.entity = function(spec) { return that; }; +IPA.trust.adder_dialog = function(spec) { + + spec = spec || {}; + + var that = IPA.entity_adder_dialog(spec); + + that.get_success_message = function(data) { + return that.entity_adder_dialog_get_success_message(data) + '. ' + data.result.result.truststatus[0]; + }; + + that.notify_success = function(data) { + IPA.notify_success(that.get_success_message(data), 5000); + }; + + return that; +}; + IPA.register('trust', IPA.trust.entity); |