diff --git a/wise-webapp/src/main/java/com/wisemapping/rest/model/RestCollaboration.java b/wise-webapp/src/main/java/com/wisemapping/rest/model/RestCollaboration.java index b5057e87..b9a9eab4 100644 --- a/wise-webapp/src/main/java/com/wisemapping/rest/model/RestCollaboration.java +++ b/wise-webapp/src/main/java/com/wisemapping/rest/model/RestCollaboration.java @@ -24,7 +24,7 @@ public class RestCollaboration { public RestCollaboration(@NotNull Collaboration collaboration) { this.email = collaboration.getCollaborator().getEmail(); - this.role = collaboration.getRole().name(); + this.role = collaboration.getRole().getLabel(); } public RestCollaboration() { diff --git a/wise-webapp/src/main/java/com/wisemapping/service/MindmapServiceImpl.java b/wise-webapp/src/main/java/com/wisemapping/service/MindmapServiceImpl.java index f8382cfe..90bab924 100755 --- a/wise-webapp/src/main/java/com/wisemapping/service/MindmapServiceImpl.java +++ b/wise-webapp/src/main/java/com/wisemapping/service/MindmapServiceImpl.java @@ -166,12 +166,16 @@ public class MindmapServiceImpl mindmap.getCollaborations().add(collaboration); mindmapManager.saveMindmap(mindmap); - // Sent collaboration email ... - final Map model = new HashMap(); - model.put("role", role); - model.put("map", mindmap); - model.put("message", "message"); - mailer.sendEmail(mailer.getSiteEmail(), email, "Collaboration", model, "newColaborator.vm"); + try { + // Sent collaboration email ... + final Map model = new HashMap(); + model.put("role", role); + model.put("map", mindmap); + model.put("message", "message"); + mailer.sendEmail(mailer.getSiteEmail(), email, "Collaboration", model, "newColaborator.vm"); + } catch (Exception e) { + e.printStackTrace(); + } } else if (collaboration.getRole() != role) { // If the relationship already exists and the role changed then only update the role diff --git a/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp b/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp index d315e3d1..7f604d4e 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp @@ -28,6 +28,11 @@
+ + + + +
@@ -51,19 +56,25 @@