Search in sources :

Example 1 with RolesActivityDto

use of org.mifos.dto.domain.RolesActivityDto in project head by mifos.

the class JournalVoucherAction method load.

public ActionForward load(ActionMapping mapping, ActionForm form, HttpServletRequest request, @SuppressWarnings("unused") HttpServletResponse response) throws Exception {
    JournalVoucherActionForm actionForm = (JournalVoucherActionForm) form;
    List<GLCodeDto> accountingDtos = null;
    List<RolesActivityDto> rolesactivitydto = null;
    accountingDtos = accountingServiceFacade.loadDebitAccounts();
    java.util.Date voucherDate = DateUtils.getCurrentDateWithoutTimeStamp();
    actionForm.setVoucherDate(voucherDate);
    rolesactivitydto = accountingServiceFacade.jvloadRolesActivity();
    UserContext context = getUserContext(request);
    actionForm.setOfficeLevelId(String.valueOf(context.getOfficeLevelId()));
    List listOfOfficeHierarchyObject = getOfficeLevels(actionForm);
    boolean journalVoucherSave = rolesactivitydto.isEmpty();
    storingSession(request, "listOfOffices", listOfOfficeHierarchyObject);
    storingSession(request, "jvsave", journalVoucherSave);
    storingSession(request, "DebitAccountGlCodes", accountingDtos);
    return mapping.findForward(ActionForwards.load_success.toString());
}
Also used : GLCodeDto(org.mifos.dto.domain.GLCodeDto) UserContext(org.mifos.security.util.UserContext) JournalVoucherActionForm(org.mifos.accounting.struts.actionform.JournalVoucherActionForm) ArrayList(java.util.ArrayList) OfficesList(org.mifos.dto.domain.OfficesList) List(java.util.List) RolesActivityDto(org.mifos.dto.domain.RolesActivityDto)

Example 2 with RolesActivityDto

use of org.mifos.dto.domain.RolesActivityDto in project head by mifos.

the class MultipleGeneralLedgerAction method load.

public ActionForward load(ActionMapping mapping, ActionForm form, HttpServletRequest request, @SuppressWarnings("unused") HttpServletResponse response) throws Exception {
    List<RolesActivityDto> rolesactivitydto = null;
    MultipleGeneralLedgerActionForm actionForm = (MultipleGeneralLedgerActionForm) form;
    actionForm.setMemberId("");
    java.util.Date trxnDate = DateUtils.getCurrentDateWithoutTimeStamp();
    actionForm.setTrxnDate(trxnDate);
    rolesactivitydto = accountingServiceFacade.glloadRolesActivity();
    boolean generalledgersave = rolesactivitydto.isEmpty();
    UserContext context = getUserContext(request);
    actionForm.setOfficeLevelId(String.valueOf(context.getOfficeLevelId()));
    List listOfOfficeHierarchyObject = getOfficeLevels(actionForm);
    storingSession(request, "listOfOffices", listOfOfficeHierarchyObject);
    storingSession(request, "officeLevelId", actionForm.getOfficeLevelId());
    storingSession(request, "glsave", generalledgersave);
    storingSession(request, "OfficesOnHierarchy", null);
    storingSession(request, "MainAccountGlCodes", null);
    storingSession(request, "AccountHeadGlCodes", null);
    storingSession(request, "DynamicOfficesOnHierarchy", null);
    storingSession(request, "SNoList", null);
    return mapping.findForward(ActionForwards.load_success.toString());
}
Also used : UserContext(org.mifos.security.util.UserContext) ArrayList(java.util.ArrayList) OfficesList(org.mifos.dto.domain.OfficesList) List(java.util.List) RolesActivityDto(org.mifos.dto.domain.RolesActivityDto) MultipleGeneralLedgerActionForm(org.mifos.accounting.struts.actionform.MultipleGeneralLedgerActionForm)

Example 3 with RolesActivityDto

use of org.mifos.dto.domain.RolesActivityDto in project head by mifos.

the class SingleGeneralLedgerAction method load.

public ActionForward load(ActionMapping mapping, ActionForm form, HttpServletRequest request, @SuppressWarnings("unused") HttpServletResponse response) throws Exception {
    List<RolesActivityDto> rolesactivitydto = null;
    SingleGeneralLedgerActionForm actionForm = (SingleGeneralLedgerActionForm) form;
    java.util.Date trxnDate = DateUtils.getCurrentDateWithoutTimeStamp();
    actionForm.setTrxnDate(trxnDate);
    rolesactivitydto = accountingServiceFacade.glloadRolesActivity();
    actionForm.setMemberId("");
    boolean generalledgersave = rolesactivitydto.isEmpty();
    UserContext context = getUserContext(request);
    actionForm.setOfficeLevelId(String.valueOf(context.getOfficeLevelId()));
    List listOfOfficeHierarchyObject = getOfficeLevels(actionForm);
    storingSession(request, "listOfOffices", listOfOfficeHierarchyObject);
    storingSession(request, "officeLevelId", actionForm.getOfficeLevelId());
    storingSession(request, "glsave", generalledgersave);
    storingSession(request, "OfficesOnHierarchy", null);
    storingSession(request, "MainAccountGlCodes", null);
    storingSession(request, "AccountHeadGlCodes", null);
    storingSession(request, "DynamicOfficesOnHierarchy", null);
    return mapping.findForward(ActionForwards.load_success.toString());
}
Also used : SingleGeneralLedgerActionForm(org.mifos.accounting.struts.actionform.SingleGeneralLedgerActionForm) UserContext(org.mifos.security.util.UserContext) ArrayList(java.util.ArrayList) OfficesList(org.mifos.dto.domain.OfficesList) List(java.util.List) RolesActivityDto(org.mifos.dto.domain.RolesActivityDto)

Aggregations

ArrayList (java.util.ArrayList)3 List (java.util.List)3 OfficesList (org.mifos.dto.domain.OfficesList)3 RolesActivityDto (org.mifos.dto.domain.RolesActivityDto)3 UserContext (org.mifos.security.util.UserContext)3 JournalVoucherActionForm (org.mifos.accounting.struts.actionform.JournalVoucherActionForm)1 MultipleGeneralLedgerActionForm (org.mifos.accounting.struts.actionform.MultipleGeneralLedgerActionForm)1 SingleGeneralLedgerActionForm (org.mifos.accounting.struts.actionform.SingleGeneralLedgerActionForm)1 GLCodeDto (org.mifos.dto.domain.GLCodeDto)1