summaryrefslogtreecommitdiffstats
path: root/install/ui/details.js
diff options
context:
space:
mode:
authorAdam Young <ayoung@redhat.com>2011-05-31 17:48:20 -0400
committerEndi Sukma Dewata <edewata@people02.fedoraproject.org>2011-05-31 22:28:31 +0000
commit554bda2a853c9d48edbde6746c428c58368c7a93 (patch)
tree34149ee35a41fd167d27407fd394f55b8840f485 /install/ui/details.js
parent007f6dd4c237a64ea5b38792396d0db0d1704809 (diff)
downloadfreeipa-554bda2a853c9d48edbde6746c428c58368c7a93.tar.gz
freeipa-554bda2a853c9d48edbde6746c428c58368c7a93.tar.xz
freeipa-554bda2a853c9d48edbde6746c428c58368c7a93.zip
redirect on show error.
Diffstat (limited to 'install/ui/details.js')
-rw-r--r--install/ui/details.js17
1 files changed, 14 insertions, 3 deletions
diff --git a/install/ui/details.js b/install/ui/details.js
index fbf2ff52d..d9c948e97 100644
--- a/install/ui/details.js
+++ b/install/ui/details.js
@@ -641,9 +641,20 @@ IPA.details_facet = function(spec) {
};
command.on_error = function(xhr, text_status, error_thrown) {
- var details = $('.details', that.container).empty();
- details.append('<p>Error: '+error_thrown.name+'</p>');
- details.append('<p>'+error_thrown.message+'</p>');
+ if (that.entity.redirect_facet) {
+ var current_entity = that.entity;
+ while (current_entity.containing_entity){
+ current_entity = current_entity.containing_entity;
+ }
+ IPA.nav.show_page(
+ current_entity.name,
+ that.entity.redirect_facet);
+ return;
+ }else{
+ var details = $('.details', that.container).empty();
+ details.append('<p>Error: '+error_thrown.name+'</p>');
+ details.append('<p>'+error_thrown.message+'</p>');
+ }
};
command.execute();