Search in sources :

Example 26 with OrganizacaoDTO

use of com.tomasio.projects.trainning.dto.OrganizacaoDTO in project trainning by fernandotomasio.

the class CommonsController method initializeSelectableOrganizacoes.

public Map<Object, Object> initializeSelectableOrganizacoes(Long parentId) {
    Map<Object, Object> result = new HashMap<>();
    OrganizacaoDTO[] organizacoes;
    if (parentId != null) {
        organizacoes = organizationalService.findAllOrganizacoesSubordinadas(parentId);
    } else {
        organizacoes = organizationalService.findAllOrganizacoes();
    }
    OrganizacaoDTO parent = organizationalService.findOrganizacao(parentId);
    result.put(parent.getId(), parent.getSigla());
    for (OrganizacaoDTO organizacao : organizacoes) {
        result.put(organizacao.getId(), organizacao.getSigla());
    }
    return result;
}
Also used : OrganizacaoDTO(com.tomasio.projects.trainning.dto.OrganizacaoDTO)

Example 27 with OrganizacaoDTO

use of com.tomasio.projects.trainning.dto.OrganizacaoDTO in project trainning by fernandotomasio.

the class CommonsController method getOrganizacaoData.

public Map getOrganizacaoData(SelectOrganizacaoForm form) {
    Map result = new HashMap<>();
    OrganizacaoDTO organizacao = organizationalService.findOrganizacao(form.getOrganizacaoId());
    result.put("nome", organizacao.getNome());
    result.put("id", organizacao.getId());
    result.put("sigla", organizacao.getSigla());
    return result;
}
Also used : OrganizacaoDTO(com.tomasio.projects.trainning.dto.OrganizacaoDTO)

Example 28 with OrganizacaoDTO

use of com.tomasio.projects.trainning.dto.OrganizacaoDTO in project trainning by fernandotomasio.

the class CommonsController method getGestoraData.

public Map<Object, Object> getGestoraData(SelectGestoraForm form) {
    Map<Object, Object> result = new HashMap<>();
    OrganizacaoDTO organizacaoDTO = organizationalService.findOrganizacao(form.getOrganizacaoId());
    result.put("id", organizacaoDTO.getId());
    result.put("sigla", organizacaoDTO.getSigla());
    return result;
}
Also used : OrganizacaoDTO(com.tomasio.projects.trainning.dto.OrganizacaoDTO)

Example 29 with OrganizacaoDTO

use of com.tomasio.projects.trainning.dto.OrganizacaoDTO in project trainning by fernandotomasio.

the class CommonsController method initializeSelectableOrganizacoes.

public Map<Object, Object> initializeSelectableOrganizacoes() {
    Map<Object, Object> result = new HashMap<>();
    OrganizacaoDTO[] organizacoes;
    organizacoes = organizationalService.findAllOrganizacoes();
    for (OrganizacaoDTO organizacao : organizacoes) {
        result.put(organizacao.getId(), organizacao.getSigla());
    }
    return result;
}
Also used : OrganizacaoDTO(com.tomasio.projects.trainning.dto.OrganizacaoDTO)

Example 30 with OrganizacaoDTO

use of com.tomasio.projects.trainning.dto.OrganizacaoDTO in project trainning by fernandotomasio.

the class CommonsController method initializeSelectableOrganizacoesGestoras.

public Map<Object, Object> initializeSelectableOrganizacoesGestoras() {
    Map<Object, Object> result = new HashMap<>();
    OrganizacaoDTO[] organizacoes;
    organizacoes = atividadesEnsinoService.findAllOrganizacoesGestoras();
    for (OrganizacaoDTO organizacao : organizacoes) {
        result.put(organizacao.getId(), organizacao.getSigla());
    }
    return result;
}
Also used : OrganizacaoDTO(com.tomasio.projects.trainning.dto.OrganizacaoDTO)

Aggregations

OrganizacaoDTO (com.tomasio.projects.trainning.dto.OrganizacaoDTO)150 CoreException (com.tomasio.projects.trainning.exeption.CoreException)54 RequestMapping (org.springframework.web.bind.annotation.RequestMapping)52 ArrayList (java.util.ArrayList)41 HashMap (java.util.HashMap)39 TurmaEfetivaDTO (com.tomasio.projects.trainning.dto.TurmaEfetivaDTO)37 DAOException (com.tomasio.projects.trainning.exception.DAOException)37 Organizacao (com.tomasio.projects.trainning.model.Organizacao)35 Map (java.util.Map)35 Transactional (org.springframework.transaction.annotation.Transactional)35 PessoaDTO (com.tomasio.projects.trainning.dto.PessoaDTO)33 Date (java.util.Date)23 SimpleDateFormat (java.text.SimpleDateFormat)21 List (java.util.List)18 IndicacaoAlunoDTO (com.tomasio.projects.trainning.dto.IndicacaoAlunoDTO)17 FaseDTO (com.tomasio.projects.trainning.dto.FaseDTO)14 MatriculaDTO (com.tomasio.projects.trainning.dto.MatriculaDTO)14 CancelamentoMatriculaDTO (com.tomasio.projects.trainning.dto.CancelamentoMatriculaDTO)12 CustoDTO (com.tomasio.projects.trainning.dto.CustoDTO)12 IndicacaoDTO (com.tomasio.projects.trainning.dto.IndicacaoDTO)12