Added commisions endponts

This commit is contained in:
Filip Izydorczyk
2020-09-30 17:46:04 +02:00
parent b4d1c87461
commit b503ebcbcc
6 changed files with 58 additions and 22 deletions

View File

@ -1,6 +1,9 @@
package com.plannaplan.services;
import java.util.List;
import com.plannaplan.entities.Commision;
import com.plannaplan.entities.User;
import com.plannaplan.repositories.CommisionRepository;
import org.springframework.beans.factory.annotation.Autowired;
@ -19,4 +22,9 @@ public class CommisionService {
return commision;
}
public List<Commision> getUsersCommisions(User user) {
Long id = user.getId();
return this.repo.getUsers(id);
}
}