Bug 433792 - Updating the activation key add on entitlement is not getting saved if you uncheck any of the previosuly selected entitlements.
Updating the activation key add on entitlement is not getting saved if you un...
Status: CLOSED CURRENTRELEASE
Product: Red Hat Satellite 5
Classification: Red Hat
Component: WebUI (Show other bugs)
510
All Linux
low Severity low
: ---
: ---
Assigned To: Devan Goodwin
Preethi Thomas
https://fjs-0-13.rhndev.redhat.com/rh...
:
Depends On:
Blocks: 248627
  Show dependency treegraph
 
Reported: 2008-02-21 09:33 EST by Preethi Thomas
Modified: 2008-04-02 20:18 EDT (History)
0 users

See Also:
Fixed In Version: sat510
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-04-02 20:18:47 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Preethi Thomas 2008-02-21 09:33:57 EST
Description of problem:

Updating the activation key add on entitlement is not getting saved if you
uncheck any of the previosuly selected entitlements.  

Version-Release number of selected component (if applicable):
rhn-satellite-5.1.0-153-redhat-linux-as-i386-4-embedded-oracle.iso

How reproducible:
always

Steps to Reproduce:
1. Create an activation key. Select any add on entitlement.
2. Click on create activation key.
3. Select above created activation key.
4. Uncheck the add on entitlement which was previously checked.
5. Click Update activation key.
6. Select the activation key again.
Note that the add on entitlement which was selected in the first step still
remains selected. 
  
Actual results:
The key update is not getting saved when the add on entitlements are unselected.

Expected results:
The key update should be saved if you uncheck selection of add on entitlements.

Additional info:
Comment 3 Devan Goodwin 2008-02-21 13:21:02 EST
Code was adding entitlements but not removing. I can't find anything since the
vega merge so this has been broken for quite awhile at the least.

Added code to assume anything "unchecked" when the form is submitted should not
be on the activation key. This will be ok unless there's a scenario when options
are checked but disabled on the form. (which I don't think there can be)

Sending       
code/src/com/redhat/rhn/frontend/action/token/ActivationKeyDetailsAction.java
Transmitting file data .
Committed revision 137173.
Comment 4 Devan Goodwin 2008-02-21 14:19:04 EST
Almost forgot about porting to 5.1 branch:

Sending       
code/src/com/redhat/rhn/frontend/action/token/ActivationKeyDetailsAction.java
Transmitting file data .
Committed revision 137196.
Comment 5 Preethi Thomas 2008-02-29 09:37:32 EST
fails_qa

not able take away virtulzation add on entitlement without giving the
virtualization platform entitlement and the vice versa. 
steps.
1. create an activation key with virtualization add on entitlement.
2. Select the key. uncheck the vitualization entitlement and save.
3. See the message on top
 "A system can have either the Virtualization or Virtualization Platform
entitlement but not both."
Repeat steps with virtualization platform entitlement.
4. If you uncheck the virtualization and check the virtulization platform (or
the other way around) it gets saved.
Comment 6 Devan Goodwin 2008-02-29 10:24:10 EST
Good catch, using add entitlements logic in the remove call, adjusted to be
better now and tested every scenario I could come up with, seems to be ok.

Trunk:

Sending       
code/src/com/redhat/rhn/frontend/action/token/ActivationKeyDetailsAction.java
Sending       
code/src/com/redhat/rhn/frontend/xmlrpc/activationkey/ActivationKeyHandler.java
Sending        code/src/com/redhat/rhn/manager/token/ActivationKeyManager.java
Transmitting file data ...
Committed revision 137497.

RELEASE-5.1:

Sending       
code/src/com/redhat/rhn/frontend/action/token/ActivationKeyDetailsAction.java
Sending       
code/src/com/redhat/rhn/frontend/xmlrpc/activationkey/ActivationKeyHandler.java
Sending        code/src/com/redhat/rhn/manager/token/ActivationKeyManager.java
Transmitting file data ...
Committed revision 137499.
Comment 8 Preethi Thomas 2008-03-03 14:07:55 EST
verified
Comment 9 Shannon Hughes 2008-03-26 13:23:50 EDT
verified on stage
Comment 10 Brandon Perkins 2008-04-02 20:18:47 EDT
5.1 Sat GA so Closed for Current Release.

Note You need to log in before you can comment on or make changes to this bug.