org.opencrx.kernel.backend
Class Contracts
java.lang.Object
org.opencrx.kernel.backend.Contracts
public class Contracts
- extends Object
|
Method Summary |
boolean |
allowPositionCreation(Path contractIdentity,
DataproviderObject_1_0 product,
Path parentPositionIdentity,
List positions)
|
boolean |
allowPositionRemoval(Path contractIdentity,
DataproviderObject_1_0 productRole,
Path parentPositionIdentity)
|
void |
calculateContractPosition(DataproviderObject_1_0 position,
Set fetchSet)
|
void |
calculateForwardReferences(DataproviderObject_1_0 contract,
Set fetchSet)
calculate forward references, i.e. |
void |
completeContract(DataproviderObject_1_0 contract,
Set fetchSet)
|
ContractPosition |
createContractPosition(Path contractIdentity,
String name,
BigDecimal quantity,
Date pricingDate,
Path productIdentity,
Path uomIdentity,
Path priceUomIdentity,
Path pricingRuleIdentity)
|
Set |
createDepotReferences(Path depotHolderIdentity,
Path positionIdentity,
Set excludeDepotUsage)
Copy depot references from product role to contract position. |
Invoice |
createInvoice(Path salesOrderIdentity)
|
Opportunity |
createOpportunity(Path leadIdentity)
|
Quote |
createQuote(Path opportunityIdentity)
|
SalesOrder |
createSalesOrder(Path quoteIdentity)
|
long |
getAdjustedLineItemNumber(long itemNumber,
long lineItemNumber)
Add itemNumber to lineItemNumber. |
GetContractAmountsResult |
getContractAmounts(CalculationRule calculationRule,
AbstractContract contract,
List lineItemNumbers,
List positionBaseAmounts,
List positionDiscountAmounts,
List positionTaxAmounts,
List positionAmounts,
List salesCommissions,
List salesCommissionIsPercentages)
|
void |
getContractAmounts(DataproviderObject_1_0 calcRule,
DataproviderObject_1_0 params,
DataproviderObject getContractAmountsResult)
|
long |
getMaxLineItemNumber(DataproviderObject_1_0 contract,
Path parentPositionIdentity)
|
int |
getNumberPositionsBasedOnProduct(Path contractIdentity,
DataproviderObject_1_0 product,
Path parentPositionIdentity,
List positions)
|
GetPositionAmountsResult |
getPositionAmounts(CalculationRule calculationRule,
ContractPosition position)
|
void |
getPositionAmounts(DataproviderObject_1_0 calcRule,
DataproviderObject_1_0 params,
DataproviderObject getPositionAmountsResult)
|
void |
markAsClosed(Path contractIdentity,
short newContractState)
|
void |
markContractAsDirty(Path contractIdentity)
|
void |
removeContractPosition(ServiceHeader header,
DataproviderObject_1_0 position,
boolean checkForMinPositions)
|
CompoundBooking |
removePendingInventoryBookings(Path contractIdentity)
Remove all pending inventory bookings of contract. |
void |
replaceContractPosition(DataproviderRequest request)
|
void |
repriceContract(Path contractIdentity)
|
short |
repriceContractPosition(Path contractPositionIdentity)
|
void |
updateContract(ServiceHeader header,
DataproviderObject object,
DataproviderObject_1_0 oldValues)
|
void |
updateContractPosition(DataproviderObject_1_0 contract,
DataproviderObject position,
DataproviderObject_1_0 oldValues,
DataproviderObject_1_0 product,
boolean reprice)
|
void |
updateContractPosition(DataproviderObject object,
DataproviderObject_1_0 oldValues)
|
void |
updateContractPositionConfigurationProperty(DataproviderObject_1_0 contract,
DataproviderObject property,
DataproviderObject_1_0 oldValues)
|
void |
updateContractPositionPrice(DataproviderObject_1_0 contract,
DataproviderObject position,
DataproviderObject_1_0 oldValues,
DataproviderObject_1_0 product,
boolean priceEnabledOverridesPosition)
|
CompoundBooking |
updateInventory(Path contractIdentity)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
cloning
protected final Cloneable cloning
cachedObjects
protected final Map cachedObjects
cachedDescriptions
protected final Map cachedDescriptions
Contracts
public Contracts(Backend backend)
markAsClosed
public void markAsClosed(Path contractIdentity,
short newContractState)
throws ServiceException
- Throws:
ServiceException
getPositionAmounts
public void getPositionAmounts(DataproviderObject_1_0 calcRule,
DataproviderObject_1_0 params,
DataproviderObject getPositionAmountsResult)
throws ServiceException
- Throws:
ServiceException
getPositionAmounts
public GetPositionAmountsResult getPositionAmounts(CalculationRule calculationRule,
ContractPosition position)
throws ServiceException
- Throws:
ServiceException
getContractAmounts
public void getContractAmounts(DataproviderObject_1_0 calcRule,
DataproviderObject_1_0 params,
DataproviderObject getContractAmountsResult)
throws ServiceException
- Throws:
ServiceException
getContractAmounts
public GetContractAmountsResult getContractAmounts(CalculationRule calculationRule,
AbstractContract contract,
List lineItemNumbers,
List positionBaseAmounts,
List positionDiscountAmounts,
List positionTaxAmounts,
List positionAmounts,
List salesCommissions,
List salesCommissionIsPercentages)
throws ServiceException
- Throws:
ServiceException
calculateContractPosition
public void calculateContractPosition(DataproviderObject_1_0 position,
Set fetchSet)
throws ServiceException
- Throws:
ServiceException
markContractAsDirty
public void markContractAsDirty(Path contractIdentity)
throws ServiceException
- Throws:
ServiceException
completeContract
public void completeContract(DataproviderObject_1_0 contract,
Set fetchSet)
throws ServiceException
- Throws:
ServiceException
calculateForwardReferences
public void calculateForwardReferences(DataproviderObject_1_0 contract,
Set fetchSet)
throws ServiceException
- calculate forward references, i.e.
Lead --> Opportunity
Opportunity --> Quote
Quote --> SalesOrder
SalesOrder --> Invoice
- Throws:
ServiceException
createInvoice
public Invoice createInvoice(Path salesOrderIdentity)
throws ServiceException
- Throws:
ServiceException
createSalesOrder
public SalesOrder createSalesOrder(Path quoteIdentity)
throws ServiceException
- Throws:
ServiceException
createQuote
public Quote createQuote(Path opportunityIdentity)
throws ServiceException
- Throws:
ServiceException
createOpportunity
public Opportunity createOpportunity(Path leadIdentity)
throws ServiceException
- Throws:
ServiceException
updateContractPositionPrice
public void updateContractPositionPrice(DataproviderObject_1_0 contract,
DataproviderObject position,
DataproviderObject_1_0 oldValues,
DataproviderObject_1_0 product,
boolean priceEnabledOverridesPosition)
throws ServiceException
- Throws:
ServiceException
getMaxLineItemNumber
public long getMaxLineItemNumber(DataproviderObject_1_0 contract,
Path parentPositionIdentity)
throws ServiceException
- Throws:
ServiceException
updateContractPosition
public void updateContractPosition(DataproviderObject_1_0 contract,
DataproviderObject position,
DataproviderObject_1_0 oldValues,
DataproviderObject_1_0 product,
boolean reprice)
updateContractPositionConfigurationProperty
public void updateContractPositionConfigurationProperty(DataproviderObject_1_0 contract,
DataproviderObject property,
DataproviderObject_1_0 oldValues)
createContractPosition
public ContractPosition createContractPosition(Path contractIdentity,
String name,
BigDecimal quantity,
Date pricingDate,
Path productIdentity,
Path uomIdentity,
Path priceUomIdentity,
Path pricingRuleIdentity)
allowPositionRemoval
public boolean allowPositionRemoval(Path contractIdentity,
DataproviderObject_1_0 productRole,
Path parentPositionIdentity)
throws ServiceException
- Throws:
ServiceException
getNumberPositionsBasedOnProduct
public int getNumberPositionsBasedOnProduct(Path contractIdentity,
DataproviderObject_1_0 product,
Path parentPositionIdentity,
List positions)
throws ServiceException
- Throws:
ServiceException
allowPositionCreation
public boolean allowPositionCreation(Path contractIdentity,
DataproviderObject_1_0 product,
Path parentPositionIdentity,
List positions)
throws ServiceException
- Throws:
ServiceException
removeContractPosition
public void removeContractPosition(ServiceHeader header,
DataproviderObject_1_0 position,
boolean checkForMinPositions)
throws ServiceException
- Throws:
ServiceException
createDepotReferences
public Set createDepotReferences(Path depotHolderIdentity,
Path positionIdentity,
Set excludeDepotUsage)
throws ServiceException
- Copy depot references from product role to contract position.
- Throws:
ServiceException
getAdjustedLineItemNumber
public long getAdjustedLineItemNumber(long itemNumber,
long lineItemNumber)
- Add itemNumber to lineItemNumber. Assert that itemNumber is adjusted
to lineItemNumber.
removePendingInventoryBookings
public CompoundBooking removePendingInventoryBookings(Path contractIdentity)
throws ServiceException
- Remove all pending inventory bookings of contract. Return last
final booking or null if no inventory booking is set on the contract
- Throws:
ServiceException
updateInventory
public CompoundBooking updateInventory(Path contractIdentity)
throws ServiceException
- Throws:
ServiceException
updateContractPosition
public void updateContractPosition(DataproviderObject object,
DataproviderObject_1_0 oldValues)
throws ServiceException
- Throws:
ServiceException
updateContract
public void updateContract(ServiceHeader header,
DataproviderObject object,
DataproviderObject_1_0 oldValues)
throws ServiceException
- Throws:
ServiceException
repriceContractPosition
public short repriceContractPosition(Path contractPositionIdentity)
throws ServiceException
- Returns:
- new pricingState of contract position
- Throws:
ServiceException
repriceContract
public void repriceContract(Path contractIdentity)
throws ServiceException
- Throws:
ServiceException
replaceContractPosition
public void replaceContractPosition(DataproviderRequest request)
throws ServiceException
- Throws:
ServiceException
This software is published under the BSD license. Copyright © 2003-2008, CRIXP AG, Switzerland, All rights reserved. Use is subject to license terms.