Search in sources :

Example 6 with ProjectCode

use of org.kuali.kfs.coa.businessobject.ProjectCode in project cu-kfs by CU-CommunityApps.

the class AmazonWebServicesBillingServiceImpl method updateTransactionDTOProjectCodeNumber.

private void updateTransactionDTOProjectCodeNumber(AmazonBillingDistributionOfIncomeTransactionDTO transactionDTO, AmazonBillingCostCenterDTO costCenterDTO) {
    if (StringUtils.isNotBlank(costCenterDTO.getProjectCode())) {
        ProjectCode projectCode = getProjectCodeService().getByPrimaryId(costCenterDTO.getProjectCode());
        if (ObjectUtils.isNotNull(projectCode)) {
            transactionDTO.setProjectCodeNumber(projectCode.getCode());
        } else {
            LOG.info("updateTransactionDTOProjectCodeNumber() Invalid Project Code.");
            transactionDTO.setTransactionInputError(true);
        }
    }
}
Also used : ProjectCode(org.kuali.kfs.coa.businessobject.ProjectCode)

Example 7 with ProjectCode

use of org.kuali.kfs.coa.businessobject.ProjectCode in project cu-kfs by CU-CommunityApps.

the class AwsAccountingXmlDocumentAccountingLineServiceImplTest method createMockProjectCode.

private static ProjectCode createMockProjectCode(ProjectCodeFixture projectCodeFixture) {
    ProjectCode projectCode = mock(ProjectCode.class);
    when(projectCode.isActive()).thenReturn(projectCodeFixture.active);
    return projectCode;
}
Also used : ProjectCode(org.kuali.kfs.coa.businessobject.ProjectCode)

Aggregations

ProjectCode (org.kuali.kfs.coa.businessobject.ProjectCode)7 ProjectCodeService (org.kuali.kfs.coa.service.ProjectCodeService)2 ValidationResult (edu.cornell.kfs.concur.businessobjects.ValidationResult)1