Hi

please review the attached patch.

Fixes this ticket: https://fedorahosted.org/freeipa/ticket/5652

--
Pavel^3 Vomacka
From e9dcb0e1c1f7e557f336c0d7346047442824a962 Mon Sep 17 00:00:00 2001
From: Pavel Vomacka <pvoma...@redhat.com>
Date: Tue, 26 Apr 2016 14:55:54 +0200
Subject: [PATCH] Add ability to review cert request dialog

The request dialog is not closed directly after clicking 'Issue' button, but only
after successful issuing or after clicking 'Close' button. So, the user can check
inputed data.

https://fedorahosted.org/freeipa/ticket/5652
---
 install/ui/src/freeipa/certificate.js | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/install/ui/src/freeipa/certificate.js b/install/ui/src/freeipa/certificate.js
index ae05ebb3d45974cd1df50c16e19d0ab9fd27a19b..9f0c187b0ef343a7f177d6d218a5cf7e9af58144 100755
--- a/install/ui/src/freeipa/certificate.js
+++ b/install/ui/src/freeipa/certificate.js
@@ -482,7 +482,6 @@ IPA.cert.request_dialog = function(spec) {
             if (that.request) {
                 that.request(values);
             }
-            that.close();
         }
     });
 
@@ -740,10 +739,14 @@ IPA.cert.request_action = function(spec) {
                     options: options,
                     on_success: function(data, text_status, xhr) {
                         facet.refresh();
+                        dialog.close();
                         IPA.notify_success('@i18n:objects.cert.requested');
                         if (facet.certificate_updated) {
                             facet.certificate_updated.notify([], that.facet);
                         }
+                    },
+                    on_error: function() {
+                        widget_mod.focus_invalid(dialog);
                     }
                 }).execute();
             }
-- 
2.5.5

-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to