This commit is contained in:
Anton Romanov 2019-05-31 08:12:57 +04:00
parent 330ffc4df1
commit b4b7b9087e

View File

@ -232,10 +232,8 @@ public class GrantService extends BaseService {
private boolean checkSameDeadline(GrantDto grantDto, Integer id) {
Date date = grantDto.getDeadlines().get(0).getDate(); //дата с сайта киас
if (deadlineService.findByGrantIdAndDate(id, date).compareTo(date) == 0) { //если есть такая строка с датой
return true;
}
return false;
Date foundGrantDate = deadlineService.findByGrantIdAndDate(id, date);
return foundGrantDate != null && foundGrantDate.compareTo(date) == 0;
}
public List<User> getGrantAuthors(GrantDto grantDto) {