Commit 6bd46d69 authored by Bùi Bá Trường's avatar Bùi Bá Trường

truongbb - demo MR

parent e6cbd59f
Pipeline #505 failed with stages
in 1 minute and 16 seconds
...@@ -21,5 +21,8 @@ public class StudentController { ...@@ -21,5 +21,8 @@ public class StudentController {
@PostMapping("/getAll") @PostMapping("/getAll")
public ResponseEntity<List<Student>> getAll(){ public ResponseEntity<List<Student>> getAll(){
return new ResponseEntity<>(studentService.getAll(), HttpStatus.OK); return new ResponseEntity<>(studentService.getAll(), HttpStatus.OK);
} }
} }
...@@ -10,10 +10,10 @@ import java.util.List; ...@@ -10,10 +10,10 @@ import java.util.List;
public class StudentRepositoryImpl implements StudentRepository { public class StudentRepositoryImpl implements StudentRepository {
@Override @Override
public List<Student> getAll() { public List<Student> getAll() {
try { // try {
int a = 1 / 0; // int a = 1 / 0;
} catch (Exception e) { // } catch (Exception e) {
} // }
return Arrays.asList(new Student(1, "Nguyen Van 1", "Ha Noi 1"), return Arrays.asList(new Student(1, "Nguyen Van 1", "Ha Noi 1"),
new Student(1, "Nguyen Van 2", "Ha Noi 2"), new Student(1, "Nguyen Van 2", "Ha Noi 2"),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment