Checkpoint: return all exchanges works

Signed-off-by: Marcin Woźniak <y0rune@aol.com>
This commit is contained in:
2021-01-07 16:51:35 +01:00
parent 56120c4724
commit 842e38898a
6 changed files with 109 additions and 11 deletions

View File

@ -1,5 +1,6 @@
package com.plannaplan.services;
import java.util.List;
import java.util.Optional;
import com.plannaplan.entities.Assignment;
@ -32,6 +33,14 @@ public class ExchangeService {
return this.repo.findById(id);
}
/**
* @param id Id of user
* @return List of exchanges that belong to user
*/
public List<Exchange> getByUserId(Long id){
return this.repo.getByUserId(id);
}
/**
* @param entity Exchange entity which we would like to delete
*/