use of com.tomasio.projects.trainning.form.apostila.ApostilaForm in project trainning by fernandotomasio.
the class ApostilasController method editApostila.
@RequestMapping("/edit")
public String editApostila(Model model, WebRequest request) {
String cursoId = request.getParameter("apostilaId");
ApostilaDTO dto = teachingDocumentsService.findApostila(Long.parseLong(cursoId));
ApostilaForm apostilaForm = new ApostilaForm();
apostilaForm.setDisciplinaId(dto.getDisciplina().getId());
apostilaForm.setDefinicoes(dto.getDefinicoes());
apostilaForm.setIntroducao(dto.getIntroducao());
model.addAttribute(apostilaForm);
return "apostilas/form";
}
use of com.tomasio.projects.trainning.form.apostila.ApostilaForm in project trainning by fernandotomasio.
the class ApostilasController method newApostila.
@RequestMapping("/new")
public String newApostila(Model model, WebRequest request) {
String curriculoMinimoIdParam = request.getParameter("curriculoMinimoId");
Long curriculoMinimoId = Long.parseLong(curriculoMinimoIdParam);
ApostilaForm apostilaForm = new ApostilaForm();
model.addAttribute(apostilaForm);
model.addAttribute("selectableDisciplinas", initializeSelectableDisciplinas(curriculoMinimoId));
return "apostilas/form";
}
Aggregations