org.kuali.kfs.module.purap.document.validation.impl
Class PurchaseOrderDocumentPreRules
java.lang.Object
org.kuali.rice.kns.rules.PromptBeforeValidationBase
org.kuali.kfs.module.purap.document.validation.impl.PurapDocumentPreRulesBase
org.kuali.kfs.module.purap.document.validation.impl.PurchasingDocumentPreRulesBase
org.kuali.kfs.module.purap.document.validation.impl.PurchaseOrderDocumentPreRules
- All Implemented Interfaces:
- org.kuali.rice.kns.rule.PromptBeforeValidation
public class PurchaseOrderDocumentPreRules
- extends PurchasingDocumentPreRulesBase
Business Prerules applicable to purchase order document.
Nested classes/interfaces inherited from class org.kuali.rice.kns.rules.PromptBeforeValidationBase |
org.kuali.rice.kns.rules.PromptBeforeValidationBase.ContextSession |
Fields inherited from class org.kuali.rice.kns.rules.PromptBeforeValidationBase |
buttonClicked, event, form, LOG, question |
Methods inherited from class org.kuali.rice.kns.rules.PromptBeforeValidationBase |
abortRulesCheck, askOrAnalyzeYesNoQuestion, processPrompts |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PurchaseOrderDocumentPreRules
public PurchaseOrderDocumentPreRules()
doPrompts
public boolean doPrompts(org.kuali.rice.kns.document.Document document)
- Overrides the method in PromptBeforeValidationBase to also invoke the confirmNotToExceedOverride if the PromptBeforeValidationEvent is
blank and the question matches with the OverrideNotToExceed
- Overrides:
doPrompts
in class PurchasingDocumentPreRulesBase
- Parameters:
document
- The purchase order document upon which we're performing the prerules logic.
- Returns:
- boolean true if it passes the pre rules conditions.
- See Also:
org.kuali.rice.kns.rules.PromptBeforeValidationBase#doRules(org.kuali.rice.kns.document.Document)
isDocumentInStateToReceiveNextFyWarning
protected boolean isDocumentInStateToReceiveNextFyWarning(PurchaseOrderDocument poDocument)
- Give next FY warning if the PO status is "In Process" or "Awaiting Purchasing Review"
- Parameters:
poDocument
-
- Returns:
- boolean
confirmNotToExceedOverride
protected boolean confirmNotToExceedOverride(PurchaseOrderDocument purchaseOrderDocument)
- Checks whether the 'Not-to-exceed' amount has been exceeded by the purchase order total dollar limit. If so, it
prompts the user for confirmation.
- Parameters:
purchaseOrderDocument
- The current PurchaseOrderDocument
- Returns:
- True if the 'Not-to-exceed' amount is to be overridden or if the total dollar amount is less than the purchase order
total dollar limit.
validateTotalDollarAmountIsLessThanPurchaseOrderTotalLimit
public boolean validateTotalDollarAmountIsLessThanPurchaseOrderTotalLimit(PurchasingDocument purDocument)
- Validate that if the PurchaseOrderTotalLimit is not null then the TotalDollarAmount cannot be greater than the
PurchaseOrderTotalLimit.
- Parameters:
purDocument
- The purchase order document to be validated.
- Returns:
- True if the TotalDollarAmount is less than the PurchaseOrderTotalLimit. False otherwise.
confirmNextFYPriorToApoAllowedDate
protected boolean confirmNextFYPriorToApoAllowedDate(PurchaseOrderDocument poDocument)
- If the PO is set to encumber in the next fiscal year and the PO is created before the APO allowed date, then give the user a
warning that this might be a mistake. Prompt the user for confirmation that the year is set correctly both at submit and upon
approval at the Purchasing Internal Review route level.
- Parameters:
purchaseOrderDocument
- The current PurchaseOrderDocument
- Returns:
- True if the user wants to continue with PO routing; False to send the user back to the PO for editing.
checkCAMSWarningStatus
protected boolean checkCAMSWarningStatus(PurchasingAccountsPayableDocument purapDocument)
- Specified by:
checkCAMSWarningStatus
in class PurapDocumentPreRulesBase
Copyright © 2005-2012 The Kuali Foundation. All Rights Reserved.