|
|
|
@ -83,7 +83,7 @@ public class InvitationsManager {
|
|
|
|
|
eu.eudat.data.entities.Invitation invitation = apiContext.getOperationsContext().getDatabaseRepository().getInvitationDao().find(invitationID);
|
|
|
|
|
if (invitation == null)
|
|
|
|
|
throw new UnauthorisedException("There is no Data Management Plan assigned to this Link");
|
|
|
|
|
if (invitation.getAcceptedInvitation()) throw new UnauthorisedException("This Url Has Expired");
|
|
|
|
|
if (invitation.getAcceptedInvitation()) return invitation.getDmp().getId(); //throw new UnauthorisedException("This Url Has Expired");
|
|
|
|
|
JAXBContext context = JAXBContext.newInstance(Properties.class);
|
|
|
|
|
Unmarshaller unmarshaller = context.createUnmarshaller();
|
|
|
|
|
Properties properties = (Properties) unmarshaller.unmarshal(new StringReader(invitation.getProperties()));
|
|
|
|
|