Search in sources :

Example 1 with AccountReversionImportService

use of edu.cornell.kfs.coa.service.AccountReversionImportService in project cu-kfs by CU-CommunityApps.

the class AccountReversionImportServiceImplTest method setUp.

@Override
protected void setUp() throws Exception {
    super.setUp();
    accountReversionImportService = SpringContext.getBean(AccountReversionImportService.class);
    businessObjectService = SpringContext.getBean(BusinessObjectService.class);
    accountReversion = AccountReversionFixture.ACCOUNT_REVERSION_UPLOAD.createAccountReversion();
    dataFileSrc = new File(DATA_FILE_PATH);
}
Also used : AccountReversionImportService(edu.cornell.kfs.coa.service.AccountReversionImportService) File(java.io.File) BusinessObjectService(org.kuali.kfs.krad.service.BusinessObjectService)

Example 2 with AccountReversionImportService

use of edu.cornell.kfs.coa.service.AccountReversionImportService in project cu-kfs by CU-CommunityApps.

the class AccountReversionImportStep method execute.

/**
 * @see org.kuali.kfs.sys.batch.AbstractWrappedBatchStep#getCustomBatchExecutor()
 */
public boolean execute(String str, Date date) {
    StopWatch stopWatch = new StopWatch();
    stopWatch.start("AccountReversionImportStep");
    File f = new File(this.batchFileDirectoryName + System.getProperty("file.separator") + "AccountReversion.csv");
    AccountReversionImportService aris = SpringContext.getBean(AccountReversionImportService.class);
    aris.importAccountReversions(f);
    addTimeStampToFileName(f, "AccountReversion.csv", this.batchFileDirectoryName);
    stopWatch.stop();
    LOG.info("AccountReversionImportStep took " + (stopWatch.getTotalTimeSeconds() / 60.0) + " minutes to complete");
    return true;
}
Also used : AccountReversionImportService(edu.cornell.kfs.coa.service.AccountReversionImportService) File(java.io.File) StopWatch(org.springframework.util.StopWatch)

Aggregations

AccountReversionImportService (edu.cornell.kfs.coa.service.AccountReversionImportService)2 File (java.io.File)2 BusinessObjectService (org.kuali.kfs.krad.service.BusinessObjectService)1 StopWatch (org.springframework.util.StopWatch)1