[PATCH rhel6-branch 4/7] iscsi: Display iface in login success dialog (#500273)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Resolves: rhbz#500273
---
 iw/advanced_storage.py  |    7 ++++---
 partIntfHelpers.py      |    6 ++++--
 textw/add_drive_text.py |    3 ++-
 3 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/iw/advanced_storage.py b/iw/advanced_storage.py
index 3918475..35e8a92 100644
--- a/iw/advanced_storage.py
+++ b/iw/advanced_storage.py
@@ -271,7 +271,8 @@ class iSCSIGuiWizard(pih.iSCSIWizard):
         dialog.destroy()
         return (rc, selected_nodes)
 
-    def display_success_dialog(self, success_nodes, fail_nodes, fail_reason):
+    def display_success_dialog(self, success_nodes, fail_nodes, fail_reason,
+                               ifaces):
         (xml, dialog) = gui.getGladeWidget("iscsi-dialogs.glade", "success_dialog")
         w_success = xml.get_widget("label_success")
         w_success_win = xml.get_widget("scroll_window_success")
@@ -285,14 +286,14 @@ class iSCSIGuiWizard(pih.iSCSIWizard):
         w_separator = xml.get_widget("separator")
 
         if success_nodes:
-            markup = "\n".join(map(lambda n: n.name, success_nodes))
+            markup = "\n".join(map(lambda n: "%s via %s" % (n.name, ifaces.get(n.iface, n.iface)), success_nodes))
             buf = gtk.TextBuffer()
             buf.set_text(markup)
             w_success.show()
             w_success_val.set_buffer(buf)
             w_success_win.show()
         if fail_nodes:
-            markup = "\n".join(map(lambda n: n.name, fail_nodes))
+            markup = "\n".join(map(lambda n: "%s via %s" % (n.name, ifaces.get(n.iface, n.iface)), fail_nodes))
             buf = gtk.TextBuffer()
             buf.set_text(markup)
             w_fail.show()
diff --git a/partIntfHelpers.py b/partIntfHelpers.py
index c17945b..9ce4afc 100644
--- a/partIntfHelpers.py
+++ b/partIntfHelpers.py
@@ -412,7 +412,8 @@ class iSCSIWizard():
         pass
 
     @abstractmethod
-    def display_success_dialog(self, success_nodes, fail_nodes, fail_reason):
+    def display_success_dialog(self, success_nodes, fail_nodes, fail_reason,
+                               ifaces):
         pass
 
     @abstractmethod
@@ -497,7 +498,8 @@ def drive_iscsi_addition(anaconda, wizard):
             elif step == STEP_SUMMARY:
                 rc = wizard.display_success_dialog(login_ok_nodes, 
                                                    login_fail_nodes,
-                                                   login_fail_msg)
+                                                   login_fail_msg,
+                                                   anaconda.id.storage.iscsi.ifaces)
                 if rc:
                     step = STEP_STABILIZE
                 else:
diff --git a/textw/add_drive_text.py b/textw/add_drive_text.py
index 8ba4da4..e196e2f 100644
--- a/textw/add_drive_text.py
+++ b/textw/add_drive_text.py
@@ -229,7 +229,8 @@ class iSCSITextWizard(pih.iSCSIWizard):
                           if i in listbox.getSelection()]
         return (rc, selected_nodes)
 
-    def display_success_dialog(self, success_nodes, fail_nodes, fail_reason):
+    def display_success_dialog(self, success_nodes, fail_nodes, fail_reason,
+                               ifaces):
         buttons = [TEXT_OK_BUTTON]
         msg = _("Successfully logged into all the selected nodes.")
         msg_reason = _("Reason:")
-- 
1.7.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux