diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2012-08-29 17:35:07 +0200 |
---|---|---|
committer | Petr Vobornik <pvoborni@redhat.com> | 2012-09-06 09:44:15 +0200 |
commit | 6a8d6d3fde0ede2e0b976cd5af67a57c0691b1f8 (patch) | |
tree | 0e46119ffafca1f15b0da8868f72c3d9a16b8da8 /install/ui/details.js | |
parent | 6ae286a8f5ec7d1633ec733fbe116550bff7141a (diff) | |
download | freeipa.git-6a8d6d3fde0ede2e0b976cd5af67a57c0691b1f8.tar.gz freeipa.git-6a8d6d3fde0ede2e0b976cd5af67a57c0691b1f8.tar.xz freeipa.git-6a8d6d3fde0ede2e0b976cd5af67a57c0691b1f8.zip |
Notify success on add, delete and update
Notification of success was added to:
* details facet: update
* association facet and association widget: add, delete items
* attribute facet: delete items (notification of add should be handled in entity adder dialog)
* sudo rule: add, remove option
* dnsrecord: add, update, delete
https://fedorahosted.org/freeipa/ticket/2977
Diffstat (limited to 'install/ui/details.js')
-rw-r--r-- | install/ui/details.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/install/ui/details.js b/install/ui/details.js index 883bb06b..cdb6a82b 100644 --- a/install/ui/details.js +++ b/install/ui/details.js @@ -508,10 +508,20 @@ IPA.details_facet = function(spec, no_init) { return valid; }; + that.nofify_update_success = function() { + var msg = IPA.messages.details.updated; + var key = that.get_primary_key(); + key = key[key.length -1] || ''; + msg = msg.replace('${entity}', that.entity.metadata.label_singular); + msg = msg.replace('${primary_key}', key); + IPA.notify_success(msg); + }; + that.update_on_success = function(data, text_status, xhr) { that.load(data); that.on_update.notify(); + that.nofify_update_success(); }; that.update_on_error = function(xhr, text_status, error_thrown) { |