Bug 881616

Summary: [ALL_LANG][SAM Web GUI] Usage Limit value to be set as '-1' when uncheck the 'Unlimited' and Save the Activation Key.
Product: [Retired] Subscription Asset Manager Reporter: Lijun Li <lijli>
Component: katelloAssignee: Jordan OMara <jomara>
Status: CLOSED ERRATA QA Contact: SAM QE List <sam-qe-list>
Severity: urgent Docs Contact:
Priority: high    
Version: 1.2CC: athomas, bkearney, hpeters, jomara, omaciel, qe-i18n-bugs, tkolhar, tomckay
Target Milestone: rcKeywords: i18n, Reopened
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Unlimited is now properly displayed where previously negative one (-1) was showing. Negative one is the internal value used to signal unlimited.
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-21 19:20:41 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:
Bug Depends On:    
Bug Blocks: 816564    
Attachments:
Description Flags
Usage Limit to be set as '-1' when uncheck the 'Unlimited' and Save the Activation Key none

Description Lijun Li 2012-11-29 08:23:59 UTC
Description of problem:
Usage Limit value to be set as '-1' when uncheck the 'Unlimited' and Save the Activation Key.

Version-Release number of selected component (if applicable):
Subscription Asset Manager Version: 1.2.5-1h.el6_3

How reproducible:
100%

Steps to Reproduce:
1. Move cursor over Content → Subscriptions and click Activation Keys.
2. Select an exisiting activation key from the list of the left.
3. Click the Details subtab and uncheck the Unlimited checkbox in Usage Limit field, click Save button.
4. Click the Save button to save your changes.
  
Actual results:
Usage Limit value to be set as '-1' when uncheck the 'Unlimited' and Save the Activation Key.

Expected results:
1. Should be have a warning message if no input any value to the usage limit box and save.
2. The value should not be as '-1'.

Additional info:

Comment 1 Lijun Li 2012-11-29 08:27:59 UTC
Created attachment 654051 [details]
Usage Limit to be set as '-1' when uncheck the 'Unlimited' and Save the Activation Key

Comment 2 Jordan OMara 2012-12-11 20:46:12 UTC
When I uncheck the UNLIMITED box, it does not set the box to -1. The box is blank until you enter a number

This is as of katello-headpin-1.2.6-6h.el6_3.noarch

Comment 3 Jordan OMara 2012-12-11 20:58:09 UTC
Turns out that to reproduce this, you have to first try to enter -1 as a number, THEN it will start showing -1 instead of "Unlimited"

Comment 4 Lijun Li 2012-12-12 02:21:01 UTC
(In reply to comment #3)
> Turns out that to reproduce this, you have to first try to enter -1 as a
> number, THEN it will start showing -1 instead of "Unlimited"
1. Select an exisiting activation key from the list of the left.
2. Uncheck the Unlimited checkbox in Usage Limit field, click Save button next to the Unlimited.
3. Usage Limit value display as -1.

Thanks,
Robert

Comment 5 Hedda Peters 2012-12-13 04:18:36 UTC
Confirmed, happening here for de-DE as well when following Robert's steps.

Comment 6 Jordan OMara 2012-12-13 20:38:46 UTC
https://github.com/Katello/katello/pull/1255

Comment 9 Tazim Kolhar 2012-12-24 06:10:53 UTC
VERIFIED :

# rpm -qa | grep katello
katello-glue-candlepin-1.2.1-10h.el6_3.noarch
katello-cli-common-1.2.1-11h.el6_3.noarch
katello-headpin-1.2.1-10h.el6_3.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-certs-tools-1.2.1-1h.el6_3.noarch
katello-cli-1.2.1-11h.el6_3.noarch
katello-configure-1.2.3-1h.el6_3.noarch
katello-common-1.2.1-10h.el6_3.noarch
katello-headpin-all-1.2.1-10h.el6_3.noarch
katello-selinux-1.2.1-1h.el6_3.noarch


The value '-1' is nt allowed to set .

Comment 11 errata-xmlrpc 2013-02-21 19:20:41 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.

http://rhn.redhat.com/errata/RHSA-2013-0544.html