Removed unused role CREATOR
This commit is contained in:
parent
694d7f04b8
commit
95d1da10bb
|
@ -623,7 +623,7 @@ public class DataManagementPlanManager {
|
||||||
UserDMP userDMP = new UserDMP();
|
UserDMP userDMP = new UserDMP();
|
||||||
userDMP.setDmp(dmp);
|
userDMP.setDmp(dmp);
|
||||||
userDMP.setUser(userInfo);
|
userDMP.setUser(userInfo);
|
||||||
userDMP.setRole(UserDMP.UserDMPRoles.CREATOR.getValue());
|
userDMP.setRole(UserDMP.UserDMPRoles.OWNER.getValue());
|
||||||
databaseRepository.getUserDmpDao().createOrUpdate(userDMP);
|
databaseRepository.getUserDmpDao().createOrUpdate(userDMP);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1230,7 +1230,7 @@ public class DataManagementPlanManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean isUserOwnerOfDmp(DMP dmp, Principal principal) {
|
private boolean isUserOwnerOfDmp(DMP dmp, Principal principal) {
|
||||||
return (dmp.getUsers().stream().filter(userDMP -> userDMP.getRole().equals(UserDMP.UserDMPRoles.CREATOR.getValue()) || userDMP.getRole().equals(UserDMP.UserDMPRoles.OWNER.getValue())).findFirst().get().getUser().getId()).equals(principal.getId());
|
return (dmp.getUsers().stream().filter(userDMP -> userDMP.getRole().equals(UserDMP.UserDMPRoles.OWNER.getValue())).findFirst().get().getUser().getId()).equals(principal.getId());
|
||||||
}
|
}
|
||||||
|
|
||||||
public String createZenodoDoi(UUID id, Principal principal, ConfigLoader configLoader) throws Exception {
|
public String createZenodoDoi(UUID id, Principal principal, ConfigLoader configLoader) throws Exception {
|
||||||
|
|
Loading…
Reference in New Issue