-
Notifications
You must be signed in to change notification settings - Fork 101
16. View Student Feature Backend
Ramesh Fadatare edited this page Jul 26, 2022
·
1 revision
<a th:href="@{/students/{studentId}/view(studentId=${student.id})}" class="btn btn-info">View</a>
// handler method to handle view student request
@GetMapping("students/{studentId}/view")
public String viewStudent(@PathVariable("studentId") Long studentId,
Model model){
StudentDto studentDto = studentService.getStudentById(studentId);
model.addAttribute("student", studentDto);
return "view_student";
}