Bug 719714

Summary: JS rules ignore multiplier when calculating virt qty for pool
Product: [Community] Candlepin Reporter: Amanda Carter <acarter>
Component: candlepinAssignee: Bryan Kearney <bkearney>
Status: CLOSED CURRENTRELEASE QA Contact: John Sefler <jsefler>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 0.5CC: aedwards
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-14 16:06:21 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Amanda Carter 2011-07-07 18:15:33 UTC
Description of problem:

java script rules in Candlepin for creating a pool calculate physical qty correctly, but virt qty incorrectly if a multiplier is on a sku.


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

CP0.3, 0.4


How reproducible:

View pools for user account mkhusid_test / redhat in Candlepin FTE or any account with a subscription to SER0198US

candlepin-fte.gss.devlab.phx1.redhat.com
https://rails-fte.gss.devlab.phx1.redhat.com/management

In this case, ordered qty is 10, multiplier is 3 and virt limit is 4.

Actual results:

Rules calculate physical qty as: product qty * multiplier
but virt qty as: product qty * virt limit (not considering multiplier)

Physical qty - 30
Virt qty - 40

Expected results:


Physical qty: product qty * multiplier
Virt qty: product qty * virt limit * multiplier

Physical qty - 30
Virt qty - 120