Hello community,

here is the log from the commit of package yast2-iscsi-lio-server for 
openSUSE:Leap:15.2 checked in at 2020-03-13 10:59:30
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Leap:15.2/yast2-iscsi-lio-server (Old)
 and      /work/SRC/openSUSE:Leap:15.2/.yast2-iscsi-lio-server.new.3160 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yast2-iscsi-lio-server"

Fri Mar 13 10:59:30 2020 rev:51 rq:784370 version:4.2.3

Changes:
--------
--- 
/work/SRC/openSUSE:Leap:15.2/yast2-iscsi-lio-server/yast2-iscsi-lio-server.changes
  2020-02-04 17:59:49.184944892 +0100
+++ 
/work/SRC/openSUSE:Leap:15.2/.yast2-iscsi-lio-server.new.3160/yast2-iscsi-lio-server.changes
        2020-03-13 11:01:37.484616475 +0100
@@ -1,0 +2,14 @@
+Wed Mar 11 15:45:38 UTC 2020 - Josef Reidinger <[email protected]>
+
+- Fix usability issues in global tab (bsc#1127505)
+- Fix crash when clicking Edit on empty table
+- 4.2.3
+
+-------------------------------------------------------------------
+Wed Mar 11 09:13:07 UTC 2020 - Knut Anderssen <[email protected]>
+
+- Propose to restart the targetcli service as the default action
+  when it is active (bsc#1165638)
+- 4.2.2
+
+-------------------------------------------------------------------

Old:
----
  yast2-iscsi-lio-server-4.2.1.tar.bz2

New:
----
  yast2-iscsi-lio-server-4.2.3.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ yast2-iscsi-lio-server.spec ++++++
--- /var/tmp/diff_new_pack.J0OpZe/_old  2020-03-13 11:01:37.784616689 +0100
+++ /var/tmp/diff_new_pack.J0OpZe/_new  2020-03-13 11:01:37.788616692 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-iscsi-lio-server
-Version:        4.2.1
+Version:        4.2.3
 Release:        0
 Summary:        Configuration of iSCSI LIO target
 License:        GPL-2.0-only

++++++ yast2-iscsi-lio-server-4.2.1.tar.bz2 -> 
yast2-iscsi-lio-server-4.2.3.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-iscsi-lio-server-4.2.1/package/yast2-iscsi-lio-server.changes 
new/yast2-iscsi-lio-server-4.2.3/package/yast2-iscsi-lio-server.changes
--- old/yast2-iscsi-lio-server-4.2.1/package/yast2-iscsi-lio-server.changes     
2020-01-31 17:31:07.000000000 +0100
+++ new/yast2-iscsi-lio-server-4.2.3/package/yast2-iscsi-lio-server.changes     
2020-03-12 14:08:58.000000000 +0100
@@ -1,4 +1,18 @@
 -------------------------------------------------------------------
+Wed Mar 11 15:45:38 UTC 2020 - Josef Reidinger <[email protected]>
+
+- Fix usability issues in global tab (bsc#1127505)
+- Fix crash when clicking Edit on empty table
+- 4.2.3
+
+-------------------------------------------------------------------
+Wed Mar 11 09:13:07 UTC 2020 - Knut Anderssen <[email protected]>
+
+- Propose to restart the targetcli service as the default action
+  when it is active (bsc#1165638)
+- 4.2.2
+
+-------------------------------------------------------------------
 Fri Jan 31 16:21:06 UTC 2020 - Ancor Gonzalez Sosa <[email protected]>
 
 - Improve internationalization support (bsc#1162378).
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-iscsi-lio-server-4.2.1/package/yast2-iscsi-lio-server.spec 
new/yast2-iscsi-lio-server-4.2.3/package/yast2-iscsi-lio-server.spec
--- old/yast2-iscsi-lio-server-4.2.1/package/yast2-iscsi-lio-server.spec        
2020-01-31 17:31:07.000000000 +0100
+++ new/yast2-iscsi-lio-server-4.2.3/package/yast2-iscsi-lio-server.spec        
2020-03-12 14:08:58.000000000 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-iscsi-lio-server
-Version:        4.2.1
+Version:        4.2.3
 Release:        0
 Summary:        Configuration of iSCSI LIO target
 License:        GPL-2.0-only
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-iscsi-lio-server-4.2.1/src/include/iscsi-lio-server/UI_dialogs.rb 
new/yast2-iscsi-lio-server-4.2.3/src/include/iscsi-lio-server/UI_dialogs.rb
--- old/yast2-iscsi-lio-server-4.2.1/src/include/iscsi-lio-server/UI_dialogs.rb 
2020-01-31 17:31:07.000000000 +0100
+++ new/yast2-iscsi-lio-server-4.2.3/src/include/iscsi-lio-server/UI_dialogs.rb 
2020-03-12 14:08:58.000000000 +0100
@@ -17,30 +17,30 @@
 Yast.import 'CWMFirewallInterfaces'
 Yast.import 'UI'
 
-class NoDiscoveryAuth_CheckBox < ::CWM::CheckBox
-  def initialize(container, value)
+class DiscoveryAuth_CheckBox < ::CWM::CheckBox
+  def initialize(container)
     textdomain "iscsi-lio-server"
-    @config = value
     @container_class = container
   end
 
   def label
-    _('No Discovery Authentication')
+    _('Discovery Authentication')
   end
 
   def init
-    self.value = @config
+    self.value = $discovery_auth.fetch_status
+    handle
   end
 
   def store
-    $discovery_auth.store_status(self.value)
+    $discovery_auth.store_status(value)
   end
 
   def handle
-    if self.value
-      @container_class.disable_discovery_auth_widgets
-    else
+    if value
       @container_class.enable_discovery_auth_widgets
+    else
+      @container_class.disable_discovery_auth_widgets
     end
     nil
   end
@@ -413,6 +413,7 @@
       self.initial = true
       @service = Yast2::SystemService.find("targetcli")
       @service_widget = ::CWM::ServiceWidget.new(@service)
+      @service_widget.default_action = :restart if @service.currently_active?
       @firewall_widget = ::CWM::WrapperWidget.new(
         CWMFirewallInterfaces.CreateOpenFirewallWidget("services" => 
["iscsi-target"]),
       )
@@ -477,36 +478,22 @@
     textdomain "iscsi-lio-server"
     username = $discovery_auth.fetch_userid.gsub(/\s+/,'')
     password = $discovery_auth.fetch_password.gsub(/\s+/,'')
-    @auth_by_target = Auth_by_Targets_CheckBox.new(self, value)
     @user_name_input = UserName.new(username)
     @password_input = Password.new(password)
     self.handle_all_events = true
   end
 
   def contents
-    HBox(
-      HSpacing(25),
-        VBox(
-          Left(@auth_by_target,),
-            HBox(
-              @user_name_input,
-                @password_input,
-            ),
-        ),
-        HSpacing(25),
+    Frame(
+      _('Authentication by Targets'),
+      HBox(
+        @user_name_input,
+        HSpacing(2),
+        @password_input,
+      )
     )
   end
 
-  def disable_checkbox
-    @auth_by_target.set_value(false)
-    @auth_by_target.disable
-  end
-
-  def enable_checkbox
-    @auth_by_target.enable
-    @auth_by_target.value = true
-  end
-
   def disable_input_fields
     @user_name_input.disable
     @password_input.disable
@@ -517,26 +504,26 @@
     @password_input.enable
   end
 
-  def get_status
-    @auth_by_target.value
-  end
-
   def opt
     [:notify]
   end
 
   def validate
-    status = @auth_by_target.get_value
-    if status
-      if (@user_name_input.get_value == " \n") || (@password_input.get_value 
== " \n")
-        err_msg = _("Please use username and password in pair.")
-        Yast::Popup.Error(err_msg)
-        return false
-      end
+    if (@user_name_input.get_value == " \n") || (@password_input.get_value == 
" \n")
+      err_msg = _("Please use username and password in pair.")
+      Yast::Popup.Error(err_msg)
+      return false
     end
     true
   end
 
+  def init
+    username = $discovery_auth.fetch_userid().gsub(/\s+/,'')
+    password = $discovery_auth.fetch_password().gsub(/\s+/,'')
+    @user_name_input.value = username
+    @password_input.value = password
+  end
+
   def store
     username = @user_name_input.get_value.gsub(/\s+/,'')
     password = @password_input.get_value.gsub(/\s+/,'')
@@ -559,7 +546,6 @@
   include Yast::Logger
   def initialize(value)
     textdomain "iscsi-lio-server"
-    @auth_by_initiator = Auth_by_Initiators_CheckBox.new(self, value)
     mutual_username = $discovery_auth.fetch_mutual_userid().gsub(/\s+/,'')
     mutual_password = $discovery_auth.fetch_mutual_password().gsub(/\s+/,'')
     @mutual_user_name_input = MutualUserName.new(mutual_username)
@@ -568,29 +554,16 @@
   end
 
   def contents
-    HBox(
-      HSpacing(25),
-        VBox(
-          Left(@auth_by_initiator,),
-            HBox(
-              @mutual_user_name_input,
-                @mutual_password_input,
-            ),
-        ),
-        HSpacing(25),
+    Frame(
+      _("Authentication by Initiators"),
+      HBox(
+        @mutual_user_name_input,
+        HSpacing(2),
+        @mutual_password_input,
+      )
     )
   end
 
-  def disable_checkbox
-    @auth_by_initiator.set_value(false)
-    @auth_by_initiator.disable
-  end
-
-  def enable_checkbox
-    @auth_by_initiator.enable
-    @auth_by_initiator.value = true
-  end
-
   def disable_input_fields
     @mutual_user_name_input.disable
     @mutual_password_input.disable
@@ -601,8 +574,11 @@
     @mutual_password_input.enable
   end
 
-  def get_status
-    @auth_by_initiator.value
+  def init
+    mutual_username = $discovery_auth.fetch_mutual_userid().gsub(/\s+/,'')
+    mutual_password = $discovery_auth.fetch_mutual_password().gsub(/\s+/,'')
+    @mutual_user_name_input.value = mutual_username
+    @mutual_password_input.value = mutual_password
   end
 
   def opt
@@ -610,13 +586,10 @@
   end
 
   def validate
-    status = @auth_by_initiator.get_value
-    if status
-      if (@mutual_user_name_input.get_value == " \n") || 
(@mutual_password_input.get_value == " \n")
-        err_msg = _("Please use mutual_username and mutual_password in pair.")
-        Yast::Popup.Error(err_msg)
-        return false
-      end
+    if (@mutual_user_name_input.get_value == " \n") || 
(@mutual_password_input.get_value == " \n")
+      err_msg = _("Please use mutual_username and mutual_password in pair.")
+      Yast::Popup.Error(err_msg)
+      return false
     end
     true
   end
@@ -646,29 +619,18 @@
     textdomain "iscsi-lio-server"
     $discovery_auth.analyze
     @status = $discovery_auth.fetch_status
-    @no_discovery_auth_checkbox = NoDiscoveryAuth_CheckBox.new(self, !@status)
+    @discovery_auth_checkbox = DiscoveryAuth_CheckBox.new(self)
     @target_discovery_auth = TargetAuthDiscovery.new(@status)
     @initiator_discovery_auth = InitiatorAuthDiscovery.new(@status)
-    self.handle_all_events = true
-  end
-
-  def init
-    if @status == false
-      disable_discovery_auth_widgets
-    end
   end
 
   def disable_discovery_auth_widgets
-    @target_discovery_auth.disable_checkbox
     @target_discovery_auth.disable_input_fields
-    @initiator_discovery_auth.disable_checkbox
     @initiator_discovery_auth.disable_input_fields
   end
 
   def enable_discovery_auth_widgets
-    @target_discovery_auth.enable_checkbox
     @target_discovery_auth.enable_input_fields
-    @initiator_discovery_auth.enable_checkbox
     @initiator_discovery_auth.enable_input_fields
   end
 
@@ -677,41 +639,20 @@
       VSpacing(5),
         VBox(
           VSpacing(2),
-            Left(
-              HBox(
-                HSpacing(25),
-                  @no_discovery_auth_checkbox,
-                  HSpacing(25),
-              )
-            ),
-            VSpacing(1),
-            @target_discovery_auth,
-            @initiator_discovery_auth,
-            VSpacing(2),
+          Left(
+            HBox(
+              # TODO: It should use checkbox frame
+              @discovery_auth_checkbox,
+            )
+          ),
+          VSpacing(1),
+          @target_discovery_auth,
+          @initiator_discovery_auth,
+          VSpacing(2),
         ),
         VSpacing(5),
     )
   end
-
-  def opt
-    [:notify]
-  end
-
-  def validate
-    if !@no_discovery_auth_checkbox.value
-      if (!@target_discovery_auth.get_status) || 
(!@initiator_discovery_auth.get_status)
-        err_msg = _("When Discovery Authentication is enabled.") + "\n"
-        err_msg += _("Please use Authentication by initiator and 
Authentication by targets together.")
-        Yast::Popup.Error(err_msg)
-        return false
-      end
-    end
-    true
-  end
-
-  def handle(event)
-    nil
-  end
 end
 
 class GlobalTab < ::CWM::Tab
@@ -723,9 +664,12 @@
 
   def contents
     VBox(
-      HStretch(),
-        VStretch(),
+      HBox(
+        HSpacing(1),
         @discovery_auth,
+        HSpacing(1)
+      ),
+      VStretch(),
     )
   end
 
@@ -736,8 +680,8 @@
   def help
     help_msg = _("<h1>iSCSI Target</h1>")
     help_msg += _("This tab intends to configure authentication for discovery 
session. ")
-    help_msg += _("Use <b>No Discovery Authentication</b> to disable discovery 
authentication.")
-    help_msg += _(" Or you need to fill both <b>Authentication by Targets</b> 
and <b>Authentication by Initiators</b>.")
+    help_msg += _("Use <b>Discovery Authentication</b> to enable discovery 
authentication.")
+    help_msg += _(" It is needed to fill both <b>Authentication by Targets</b> 
and <b>Authentication by Initiators</b>.")
     help_msg += _("<p>Note: <b>Username / Password can not be the same for 
initiators and targets! \
                   Or there may be a CHAP error</b></p>")
     help_msg
@@ -754,8 +698,8 @@
   def contents
     VBox(
       HStretch(),
-        VStretch(),
-        @target_table_widget
+      VStretch(),
+      @target_table_widget
     )
   end
 
@@ -1242,11 +1186,11 @@
   def contents
     VBox(
       @initiator_name_input,
-        @import_luns,
-        HBox(
-          PushButton(Id(:cancel), _('Cancel')),
-            PushButton(Id(:ok), _('OK')),
-        ),
+      @import_luns,
+      HBox(
+        PushButton(Id(:cancel), _('Cancel')),
+        PushButton(Id(:ok), _('OK'))
+      )
     )
   end
 
@@ -1604,10 +1548,10 @@
   def contents
     VBox(
       @auth_by_initiator,
-        HBox(
-          @mutual_user_name_input,
-            @mutual_password_input,
-        ),
+      HBox(
+        @mutual_user_name_input,
+        @mutual_password_input
+      )
     )
   end
 
@@ -1714,10 +1658,10 @@
   def contents
     VBox(
       @auth_by_target,
-        HBox(
-          @user_name_input,
-            @password_input,
-        ),
+      HBox(
+        @user_name_input,
+        @password_input
+      )
     )
   end
 
@@ -1831,11 +1775,11 @@
   def contents
     VBox(
       @acl_initiator_auth,
-        @acl_target_auth,
-        HBox(
-          PushButton(Id(:ok), _('OK')),
-            PushButton(Id(:abort), _('Abort')),
-        ),
+      @acl_target_auth,
+      HBox(
+        PushButton(Id(:ok), _('OK')),
+        PushButton(Id(:abort), _('Abort'))
+      )
     )
   end
 
@@ -1968,9 +1912,11 @@
       end
     when :edit_lun
       item = @acls_table.get_selected
-      initiator_name = item[1]
-      edit_lun_mapping_dialog = EditLUNMappingDialog.new(initiator_name, 
@target_name)
-      ret = edit_lun_mapping_dialog.run
+      if item
+        initiator_name = item[1]
+        edit_lun_mapping_dialog = EditLUNMappingDialog.new(initiator_name, 
@target_name)
+        ret = edit_lun_mapping_dialog.run
+      end
     when :edit_auth
       item = @acls_table.get_selected
       if item != nil
@@ -2389,13 +2335,13 @@
       create_ACLs_dialog(info)
     when :edit
       target = @target_table.get_selected
-      if target != nil
-        @edit_target_page = AddTargetWidget.new(target[1])
-        contents = VBox(@edit_target_page, HStretch(), VStretch())
-        Yast::Wizard.CreateDialog
-        CWM.show(contents, caption: _('Edit iSCSI Target'))
-        Yast::Wizard.CloseDialog
-      end
+      return unless target
+
+      @edit_target_page = AddTargetWidget.new(target[1])
+      contents = VBox(@edit_target_page, HStretch(), VStretch())
+      Yast::Wizard.CreateDialog
+      CWM.show(contents, caption: _('Edit iSCSI Target'))
+      Yast::Wizard.CloseDialog
       @target_table.update_table
       info = @edit_target_page.get_target_info
       create_ACLs_dialog(info)


Reply via email to