use of org.collectiveone.modules.assignations.dto.AssignationDto in project CollectiveOneWebapp by CollectiveOne.
the class AssignationService method getAssignationsOfSubinitiatives.
@Transactional
public GetResult<List<AssignationDto>> getAssignationsOfSubinitiatives(UUID initiativeId, UUID evaluatorAppUserId, PageRequest page) {
/* add assignations of of this initiative */
List<Assignation> assignationsOfSubinitiative = assignationRepository.findByAlsoInInitiatives_Id(initiativeId, page);
List<AssignationDto> assignationsDto = new ArrayList<AssignationDto>();
for (Assignation assignation : assignationsOfSubinitiative) {
assignationsDto.add(getAssignationDto(assignation.getId(), evaluatorAppUserId, false).getData());
}
return new GetResult<List<AssignationDto>>("success", "assignations retrieved", assignationsDto);
}
use of org.collectiveone.modules.assignations.dto.AssignationDto in project CollectiveOneWebapp by CollectiveOne.
the class AssignationService method getAssignationsOfInitiative.
@Transactional
public GetResult<List<AssignationDto>> getAssignationsOfInitiative(UUID initiativeId, UUID evaluatorAppUserId, PageRequest page) {
/* add assignations of of this initiative */
List<Assignation> assignations = assignationRepository.findByInitiativeId(initiativeId, page);
List<AssignationDto> assignationsDto = new ArrayList<AssignationDto>();
for (Assignation assignation : assignations) {
assignationsDto.add(getAssignationDto(assignation.getId(), evaluatorAppUserId, false).getData());
}
return new GetResult<List<AssignationDto>>("success", "assignations retrieved", assignationsDto);
}
Aggregations