| org.kuali.core.maintenance.rules.MaintenanceDocumentRuleBase org.kuali.module.chart.rules.AccountRule
Field Summary | |
protected static org.apache.log4j.Logger | LOG |
Method Summary | |
protected boolean | accountNumberStartsWithAllowedPrefix(String accountNumber, List<String> illegalValues) This method tests whether the accountNumber passed in is prefixed with an allowed prefix, or an illegal one. | protected boolean | areGuidelinesRequired(Account account) This method determines whether the guidelines are required, based on business rules. | protected boolean | areTwoUsersTheSame(UniversalUser user1, UniversalUser user2) | protected boolean | checkAccountExpirationDateValidTodayOrEarlier(Account newAccount) | protected boolean | checkAccountGuidelinesValidation(AccountGuideline accountGuideline) | protected boolean | checkCGFieldNotFilledIn(Account account, String propertyName) | protected boolean | checkCgIncomeStreamRequired(Account newAccount) | protected boolean | checkCgRequiredFields(Account newAccount) | protected boolean | checkCloseAccount(MaintenanceDocument maintenanceDocument) | protected boolean | checkContractControlAccountNumberRequired(Account newAccount) | protected boolean | checkContractsAndGrants(MaintenanceDocument maintenanceDocument) | protected boolean | checkEmptyValues(MaintenanceDocument maintenanceDocument) | protected boolean | checkExpirationDate(MaintenanceDocument maintenanceDocument) | protected boolean | checkFiscalOfficerIsValidKualiUser(String fiscalOfficerUserId) | protected boolean | checkFringeBenefitAccountRule(Account newAccount) the fringe benefit account (otherwise known as the reportsToAccount) is required if the fringe benefit code is set to N. | protected boolean | checkFundGroup(MaintenanceDocument maintenanceDocument) | protected boolean | checkGeneralRules(MaintenanceDocument maintenanceDocument) | protected boolean | checkSubFundGroup(MaintenanceDocument maintenanceDocument) | protected boolean | checkUserStatusAndType(String propertyName, UniversalUser user) This method checks to see if the user passed in is of the type requested. | protected boolean | hasDefaultRestrictedStatusCode(Account account) Checks whether the account restricted status code is the default from the sub fund group. | protected boolean | hasTemporaryRestrictedStatusCodeButNoRestrictedStatusDate(Account account) This method tests whether a given account has the T - Temporary value for Restricted Status Code, but does not have a
Restricted Status Date, which is required when the code is T. | protected boolean | isContinuationAccountExpired(Account newAccount) This method tests whether the continuation account entered (if any) has expired or not. | protected boolean | isNonSystemSupervisorEditingAClosedAccount(MaintenanceDocument document, UniversalUser user) This method tests whether an account is being ReOpened by anyone except a system supervisor. | protected boolean | isSupervisorSameAsFiscalOfficer(Account account) | protected boolean | isSupervisorSameAsManager(Account account) | protected boolean | isUpdatedExpirationDateInvalid(MaintenanceDocument maintDoc) | protected boolean | processCustomRouteDocumentBusinessRules(MaintenanceDocument document) | protected boolean | processCustomSaveDocumentBusinessRules(MaintenanceDocument document) | final public void | setAccountService(AccountService accountService) Sets the accountService attribute value. | public void | setBalanceService(BalanceService balanceService) | public void | setGeneralLedgerPendingEntryService(GeneralLedgerPendingEntryService generalLedgerPendingEntryService) | public void | setLaborLedgerPendingEntryService(LaborLedgerPendingEntryService laborLedgerPendingEntryService) | public void | setupConvenienceObjects() This method sets the convenience objects like newAccount and oldAccount, so you have short and easy handles to the new and
old objects contained in the maintenance document. |
LOG | protected static org.apache.log4j.Logger LOG(Code) | | |
AccountRule | public AccountRule()(Code) | | |
accountNumberStartsWithAllowedPrefix | protected boolean accountNumberStartsWithAllowedPrefix(String accountNumber, List<String> illegalValues)(Code) | | This method tests whether the accountNumber passed in is prefixed with an allowed prefix, or an illegal one. The illegal
prefixes are passed in as an array of strings.
Parameters: accountNumber - - The Account Number to be tested. Parameters: illegalValues - - An Array of Strings of the unallowable prefixes. false if the accountNumber starts with any of the illegalPrefixes, true otherwise |
areGuidelinesRequired | protected boolean areGuidelinesRequired(Account account)(Code) | | This method determines whether the guidelines are required, based on business rules.
Parameters: account - - the populated Account bo to be evaluated true if guidelines are required, false otherwise |
areTwoUsersTheSame | protected boolean areTwoUsersTheSame(UniversalUser user1, UniversalUser user2)(Code) | | This method checks to see if two users are the same BusinessObject using their identifiers
Parameters: user1 - Parameters: user2 - true if these two users are the same |
checkAccountExpirationDateValidTodayOrEarlier | protected boolean checkAccountExpirationDateValidTodayOrEarlier(Account newAccount)(Code) | | This method checsk to see if the account expiration date is today's date or earlier
Parameters: newAccount - fails if the expiration date is null or after today's date |
checkAccountGuidelinesValidation | protected boolean checkAccountGuidelinesValidation(AccountGuideline accountGuideline)(Code) | | This method validates that the account guidelines object is valid
Parameters: accountGuideline - true if account guideline is valid |
checkCGFieldNotFilledIn | protected boolean checkCGFieldNotFilledIn(Account account, String propertyName)(Code) | | This method checks to see if the contracts and grants fields are filled in or not
Parameters: account - Parameters: propertyName - - property to attach error to false if the contracts and grants fields are blank |
checkCgIncomeStreamRequired | protected boolean checkCgIncomeStreamRequired(Account newAccount)(Code) | | This method checks to see if the income stream account is required
Parameters: newAccount - fails if it is required and not entered, or not valid |
checkCgRequiredFields | protected boolean checkCgRequiredFields(Account newAccount)(Code) | | This method checks to make sure that if the contracts and grants fields are required they are entered correctly
Parameters: newAccount - |
checkCloseAccount | protected boolean checkCloseAccount(MaintenanceDocument maintenanceDocument)(Code) | | This method checks to see if the user is trying to close the account and if so if any rules are being violated Calls the
additional rule checkAccountExpirationDateValidTodayOrEarlier
Parameters: maintenanceDocument - false on rules violation |
checkContractControlAccountNumberRequired | protected boolean checkContractControlAccountNumberRequired(Account newAccount)(Code) | | This method checks to make sure that if the contract control account exists it is the same as the Account that we are working
on
Parameters: newAccount - false if the contract control account is entered and is not the same as the account we are maintaining |
checkContractsAndGrants | protected boolean checkContractsAndGrants(MaintenanceDocument maintenanceDocument)(Code) | | This method checks to see if any Contracts and Grants business rules were violated Calls the following sub-rules:
checkCgRequiredFields checkCgIncomeStreamRequired
Parameters: maintenanceDocument - false on rules violation |
checkEmptyValues | protected boolean checkEmptyValues(MaintenanceDocument maintenanceDocument)(Code) | | This method checks the basic rules for empty values in an account and associated objects with this account If guidelines are
required for this Business Object it checks to make sure that it is filled out It also checks for partially filled out
reference keys on the following: continuationAccount incomeStreamAccount endowmentIncomeAccount reportsToAccount
contractControlAccount indirectCostRecoveryAcct
Parameters: maintenanceDocument - false if any of these are empty |
checkExpirationDate | protected boolean checkExpirationDate(MaintenanceDocument maintenanceDocument)(Code) | | This method checks to see if any expiration date field rules were violated
Parameters: maintenanceDocument - false on rules violation |
checkFiscalOfficerIsValidKualiUser | protected boolean checkFiscalOfficerIsValidKualiUser(String fiscalOfficerUserId)(Code) | | This method insures the fiscal officer is a valid Kuali User
Parameters: fiscalOfficerUserId - true if they are a valid Kuali user |
checkFringeBenefitAccountRule | protected boolean checkFringeBenefitAccountRule(Account newAccount)(Code) | | the fringe benefit account (otherwise known as the reportsToAccount) is required if the fringe benefit code is set to N. The
fringe benefit code of the account designated to accept the fringes must be Y.
Parameters: newAccount - |
checkFundGroup | protected boolean checkFundGroup(MaintenanceDocument maintenanceDocument)(Code) | | This method checks to see if any Fund Group rules were violated Specifically: if we are dealing with a "GF" (General Fund) we
cannot have an account with a budget recording level of "M" (Mixed)
Parameters: maintenanceDocument - false on rules violation |
checkGeneralRules | protected boolean checkGeneralRules(MaintenanceDocument maintenanceDocument)(Code) | | This method checks some of the general business rules associated with this document Calls the following rules:
accountNumberStartsWithAllowedPrefix isNonSystemSupervisorEditingAClosedAccount
hasTemporaryRestrictedStatusCodeButNoRestrictedStatusDate checkFringeBenefitAccountRule checkUserStatusAndType (on fiscal
officer, supervisor and manager) ensures that the fiscal officer, supervisor and manager are not the same
isContinuationAccountExpired
Parameters: maintenanceDocument - false on rules violation |
checkSubFundGroup | protected boolean checkSubFundGroup(MaintenanceDocument maintenanceDocument)(Code) | | This method checks to see if any SubFund Group rules were violated Specifically: if SubFundGroup is empty or not "PFCMR" we
cannot have a campus code or building code if SubFundGroup is "PFCMR" then campus code and building code "must" be entered
and be valid codes
Parameters: maintenanceDocument - false on rules violation |
checkUserStatusAndType | protected boolean checkUserStatusAndType(String propertyName, UniversalUser user)(Code) | | This method checks to see if the user passed in is of the type requested. If so, it returns true. If not, it returns false,
and adds an error to the GlobalErrors.
Parameters: propertyName - - property to attach error to Parameters: user - - UniversalUser to be tested true if user is of the requested employee type, false if not, true if the user object is null |
hasDefaultRestrictedStatusCode | protected boolean hasDefaultRestrictedStatusCode(Account account)(Code) | | Checks whether the account restricted status code is the default from the sub fund group.
Parameters: account - true if the restricted status code is the same as the sub fund group's |
hasTemporaryRestrictedStatusCodeButNoRestrictedStatusDate | protected boolean hasTemporaryRestrictedStatusCodeButNoRestrictedStatusDate(Account account)(Code) | | This method tests whether a given account has the T - Temporary value for Restricted Status Code, but does not have a
Restricted Status Date, which is required when the code is T.
Parameters: account - true if the account is temporarily restricted but the status date is empty |
isContinuationAccountExpired | protected boolean isContinuationAccountExpired(Account newAccount)(Code) | | This method tests whether the continuation account entered (if any) has expired or not.
Parameters: newAccount - true if continuation account has expired |
isNonSystemSupervisorEditingAClosedAccount | protected boolean isNonSystemSupervisorEditingAClosedAccount(MaintenanceDocument document, UniversalUser user)(Code) | | This method tests whether an account is being ReOpened by anyone except a system supervisor. Only system supervisors may
reopen closed accounts.
Parameters: document - - populated document containing the old and new accounts Parameters: user - - the user who is trying to possibly reopen the account true if: document is an edit document, old was closed and new is open, and the user is not one of the SystemSupervisors |
isUpdatedExpirationDateInvalid | protected boolean isUpdatedExpirationDateInvalid(MaintenanceDocument maintDoc)(Code) | | This method checks to see if the new expiration date is different from the old expiration and if it has if it is invalid
Parameters: maintDoc - true if expiration date has changed and is invalid |
setAccountService | final public void setAccountService(AccountService accountService)(Code) | | Sets the accountService attribute value.
Parameters: accountService - The accountService to set. |
setBalanceService | public void setBalanceService(BalanceService balanceService)(Code) | | This method sets the balanceService
Parameters: balanceService - |
setGeneralLedgerPendingEntryService | public void setGeneralLedgerPendingEntryService(GeneralLedgerPendingEntryService generalLedgerPendingEntryService)(Code) | | This method sets the generalLedgerPendingEntryService
Parameters: generalLedgerPendingEntryService - |
setLaborLedgerPendingEntryService | public void setLaborLedgerPendingEntryService(LaborLedgerPendingEntryService laborLedgerPendingEntryService)(Code) | | This method sets the laborLedgerPendingEntryService
Parameters: laborLedgerPendingEntryService - |
setupConvenienceObjects | public void setupConvenienceObjects()(Code) | | This method sets the convenience objects like newAccount and oldAccount, so you have short and easy handles to the new and
old objects contained in the maintenance document. It also calls the BusinessObjectBase.refresh(), which will attempt to load
all sub-objects from the DB by their primary keys, if available.
|
Methods inherited from org.kuali.core.maintenance.rules.MaintenanceDocumentRuleBase | protected boolean apcRuleFails(String parameterNamespace, String parameterDetailTypeCode, String parameterName, String valueToTest)(Code)(Java Doc) protected boolean applyApcRule(String parameterNamespace, String parameterDetailTypeCode, String parameterName, String valueToTest)(Code)(Java Doc) protected boolean checkAuthorizationRestrictions(MaintenanceDocument document)(Code)(Java Doc) protected boolean checkEmptyBOField(String propertyName, Object valueToTest, String parameter)(Code)(Java Doc) protected boolean checkEmptyDocumentField(String propertyName, Object valueToTest, String parameter)(Code)(Java Doc) protected boolean checkEmptyValue(Object valueToTest)(Code)(Java Doc) protected boolean checkForPartiallyFilledOutReferenceForeignKeys(String referenceName)(Code)(Java Doc) protected void clearErrorPath()(Code)(Java Doc) protected boolean dataDictionaryValidate(MaintenanceDocument document)(Code)(Java Doc) final protected BusinessObjectDictionaryService getBoDictionaryService()(Code)(Java Doc) final protected BusinessObjectService getBoService()(Code)(Java Doc) final protected KualiConfigurationService getConfigService()(Code)(Java Doc) public DateTimeService getDateTimeService()(Code)(Java Doc) final protected DataDictionaryService getDdService()(Code)(Java Doc) final protected DictionaryValidationService getDictionaryValidationService()(Code)(Java Doc) final protected DocumentAuthorizationService getDocumentAuthorizationService()(Code)(Java Doc) protected String getFieldLabel(String fieldName)(Code)(Java Doc) protected String getFieldLabel(Class boClass, String fieldName)(Code)(Java Doc) final protected MaintenanceDocumentDictionaryService getMaintDocDictionaryService()(Code)(Java Doc) final protected PersistableBusinessObject getNewBo()(Code)(Java Doc) final protected PersistableBusinessObject getOldBo()(Code)(Java Doc) final protected PersistenceService getPersistenceService()(Code)(Java Doc) final protected PersistenceStructureService getPersistenceStructureService()(Code)(Java Doc) public UniversalUserService getUniversalUserService()(Code)(Java Doc) public WorkflowDocumentService getWorkflowDocumentService()(Code)(Java Doc) protected boolean isCorrectMaintenanceClass(MaintenanceDocument document, Class clazz)(Code)(Java Doc) protected boolean isDocumentValidForSave(MaintenanceDocument maintenanceDocument)(Code)(Java Doc) public boolean processAddCollectionLineBusinessRules(MaintenanceDocument document, String collectionName, PersistableBusinessObject bo)(Code)(Java Doc) public boolean processApproveDocument(ApproveDocumentEvent approveEvent)(Code)(Java Doc) public boolean processCustomAddCollectionLineBusinessRules(MaintenanceDocument document, String collectionName, PersistableBusinessObject line)(Code)(Java Doc) protected boolean processCustomApproveDocumentBusinessRules(MaintenanceDocument document)(Code)(Java Doc) protected boolean processCustomRouteDocumentBusinessRules(MaintenanceDocument document)(Code)(Java Doc) protected boolean processCustomSaveDocumentBusinessRules(MaintenanceDocument document)(Code)(Java Doc) protected boolean processGlobalApproveDocumentBusinessRules(MaintenanceDocument document)(Code)(Java Doc) protected boolean processGlobalRouteDocumentBusinessRules(MaintenanceDocument document)(Code)(Java Doc) protected boolean processGlobalSaveDocumentBusinessRules(MaintenanceDocument document)(Code)(Java Doc) public boolean processRouteDocument(Document document)(Code)(Java Doc) public boolean processSaveDocument(Document document)(Code)(Java Doc) protected void putDocumentError(String propertyName, String errorConstant, String parameter)(Code)(Java Doc) protected void putDocumentError(String propertyName, String errorConstant, String[] parameters)(Code)(Java Doc) protected void putFieldError(String propertyName, String errorConstant)(Code)(Java Doc) protected void putFieldError(String propertyName, String errorConstant, String parameter)(Code)(Java Doc) protected void putFieldError(String propertyName, String errorConstant, String[] parameters)(Code)(Java Doc) protected void putFieldErrorWithShortLabel(String propertyName, String errorConstant)(Code)(Java Doc) protected void putGlobalError(String errorConstant)(Code)(Java Doc) protected void putGlobalError(String errorConstant, String parameter)(Code)(Java Doc) protected void putGlobalError(String errorConstant, String[] parameters)(Code)(Java Doc) protected void putGlobalsError(String propertyName, String errorConstant)(Code)(Java Doc) protected void putGlobalsError(String propertyName, String errorConstant, String parameter)(Code)(Java Doc) protected void resumeErrorPath()(Code)(Java Doc) final public void setBoDictionaryService(BusinessObjectDictionaryService boDictionaryService)(Code)(Java Doc) final public void setBoService(BusinessObjectService boService)(Code)(Java Doc) final public void setConfigService(KualiConfigurationService configService)(Code)(Java Doc) final public void setDdService(DataDictionaryService ddService)(Code)(Java Doc) final public void setDictionaryValidationService(DictionaryValidationService dictionaryValidationService)(Code)(Java Doc) final public void setDocumentAuthorizationService(DocumentAuthorizationService documentAuthorizationService)(Code)(Java Doc) final public void setMaintDocDictionaryService(MaintenanceDocumentDictionaryService maintDocDictionaryService)(Code)(Java Doc) protected void setNewBo(PersistableBusinessObject newBo)(Code)(Java Doc) final public void setPersistenceService(PersistenceService persistenceService)(Code)(Java Doc) final public void setPersistenceStructureService(PersistenceStructureService persistenceStructureService)(Code)(Java Doc) public void setUniversalUserService(UniversalUserService universalUserService)(Code)(Java Doc) public void setWorkflowDocumentService(WorkflowDocumentService workflowDocumentService)(Code)(Java Doc) public void setupBaseConvenienceObjects(MaintenanceDocument document)(Code)(Java Doc) public void setupConvenienceObjects()(Code)(Java Doc) protected boolean validateDocumentStructure(Document document)(Code)(Java Doc) protected boolean validateGlobalBusinessObjectPersistable(MaintenanceDocument document)(Code)(Java Doc) protected boolean validateMaintenanceDocument(MaintenanceDocument maintenanceDocument)(Code)(Java Doc)
|
|
|