Bug 1262075

Summary: Cannot go back during the registration process
Product: Red Hat Enterprise Linux 7 Reporter: Chris "Ceiu" Rog <crog>
Component: subscription-managerAssignee: candlepin-bugs
Status: CLOSED ERRATA QA Contact: Sean Toner <stoner>
Severity: high Docs Contact:
Priority: high    
Version: 7.3CC: csnyder, jsefler, stoner
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-11-19 11:51:01 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
shows registration succeeding despite clicking Cancel none

Description Chris "Ceiu" Rog 2015-09-10 18:45:37 UTC
Description of problem:
Clicking the "Cancel" button during registration closes the registration window, but does not cancel or reset the process. Starting registration again resumes from the last step the user was on when the cancel button was clicked.

The only way to redo part of the registration (picking a new server, for instance), is to close the subman-gui entirely and start over.

Version-Release number of selected component (if applicable):


How reproducible:
100%


Steps to Reproduce:
1. Attempt to register via subman-gui
2. Completing any page/step and click the "Register" button
3. Click the "Cancel" button on any page/step other than the first
4. Open the registration dialog again

Actual results:
The registration dialog will begin on the last page/step that the user was on when the "Cancel" button was clicked.

Expected results:
The registration process should start over

Additional info:
An alternate solution to this would be to change the cancel button to a "back" button on all but the first page. Doing so would, in theory, also address a related bug requesting such behavior/clarity for initial setup.

Comment 2 John Sefler 2015-09-25 17:00:51 UTC
Please re-test

Comment 3 Sean Toner 2015-09-25 21:19:29 UTC
Created attachment 1077256 [details]
shows registration succeeding despite clicking Cancel

I clicked on the Cancel button on the second dialog after clicking Register.  However, even after clicking Cancel, the system actually is Registered.

The user would need to unregister the system despite having clicked Cancel

Comment 4 Adrian Likins 2015-09-29 18:00:04 UTC
pr at  https://github.com/candlepin/subscription-manager/pull/1306

Comment 5 Chris Snyder 2015-09-29 20:58:17 UTC
The cancel button has been renamed and repurposed to a back button.
This new back button is made insensitive on screens that complete actions such as registration. This should satisfy the original bug report.

The behavior discussed in comment 3 should be addressed in a separate bz.


In master as of commit hash: 5c35e366e1de4ec4b77ddb7b18b264c9b9c52f2c

Comment 6 Chris Snyder 2015-09-30 01:27:49 UTC
(In reply to Chris Snyder from comment #5)
> The cancel button has been renamed and repurposed to a back button.
> This new back button is made insensitive on screens that complete actions
> such as registration. This should satisfy the original bug report.
> 
> The behavior discussed in comment 3 should be addressed in a separate bz.
> 
> 
> In master as of commit hash: 5c35e366e1de4ec4b77ddb7b18b264c9b9c52f2c

This commit is a necessary modification to completely solve this bug: ac684ca49569e603ef48e47cc749e16fb3fbb2d3

This adds the ability to move back more than one screen.

Comment 7 Chris "Ceiu" Rog 2015-09-30 14:02:54 UTC
commit 5c35e366e1de4ec4b77ddb7b18b264c9b9c52f2c
Author: Adrian Likins <alikins>
Date:   Mon Sep 28 18:08:40 2015 -0400

    1262075,1267179: Fix back/cancel nav
    
    Replace 'cancel' with stock 'back' button.
    
    register_dialog.ui was using the stock 'cancel', but
    rhsm_gui.ui was not. But change both to stock 'back'
    
    Add a RegisterWidget.applied_screen_history that
    tracks screens shown to the user, so that back
    and error handling can do the right thing. This
    uses UniqueList to keep only the last time a
    screen was visited.
    
    Make back button blocked/insens when in async
    screen pre(). This avoid changing screens while
    waiting for a thread to finish. It also blocks
    the buttons until the screens are ready().
    
    'back' now attempts to go back to the last gui
    screen that was shown to the user.



commit ac684ca49569e603ef48e47cc749e16fb3fbb2d3
Author: Adrian Likins <alikins>
Date:   Tue Sep 29 17:11:35 2015 -0400

    Allow 'back' to go back multiple times.
    
    Replace 'back' usage of _last_screen() with
    _pop_last_screen() that keeps better track of the
    stack of visited screens.
    
    _last_screen() only understands the last uniq screen
    visited, so would prevent 'back' from allowing
    user to go back more than one screen.

Comment 9 Sean Toner 2015-10-01 15:13:31 UTC
The Back button will now go back to the prior screens.  Also the Back button is greyed out and inactive during the actual registration process.  This is good as the previous behavior allowed one to click the Cancel button, but the registration would occur anyway.  So the new Back button behavior fixes that (ie, once you click Register button, there's no going back).



[root@dhcp129-70 ~]# rpm -qa | grep subscription
subscription-manager-1.15.9-13.el7.x86_64
subscription-manager-gui-1.15.9-13.el7.x86_64
subscription-manager-initial-setup-addon-1.15.9-13.el7.x86_64

Comment 10 errata-xmlrpc 2015-11-19 11:51:01 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-2122.html