From b11949fba3b7194d1e2de78607b8b3dfbede12af Mon Sep 17 00:00:00 2001 From: Francesco Mangiacrapa Date: Wed, 25 Sep 2019 09:14:35 +0000 Subject: [PATCH] Replaced the HTML code in the POST_MESSAGE Replaced citation with @username Updated pom version at 1.4.1 git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/widgets/grsf-manage-widget@181849 82a268e6-3cf1-43bd-a215-b396298e98cf --- distro/changelog.xml | 9 ++++++++- pom.xml | 2 +- .../server/manage/SocialCommunications.java | 12 ++++++++---- 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/distro/changelog.xml b/distro/changelog.xml index ef606c1..bf2160a 100644 --- a/distro/changelog.xml +++ b/distro/changelog.xml @@ -1,9 +1,16 @@ + + [Feature #17576] Modify grsf-manage-widget posts to cite people with @username + + [Feature #16312] Report the name of the editor as tag in the - published feed + published feed + org.gcube.portlets.widgets grsf-manage-widget - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT gCube GRSF Manage widget diff --git a/src/main/java/org/gcube/datacatalogue/grsf_manage_widget/server/manage/SocialCommunications.java b/src/main/java/org/gcube/datacatalogue/grsf_manage_widget/server/manage/SocialCommunications.java index a4396a0..235627f 100644 --- a/src/main/java/org/gcube/datacatalogue/grsf_manage_widget/server/manage/SocialCommunications.java +++ b/src/main/java/org/gcube/datacatalogue/grsf_manage_widget/server/manage/SocialCommunications.java @@ -72,8 +72,8 @@ public class SocialCommunications { // emails to be sent to editors and reviewers and post to be written into the grsf admin vre private static final String POST_MESSAGE = "Dear members," - + "
The record 'PRODUCT_TITLE' has been just updated by USER_FULLNAME." - + "
You can inspect it here: LINK_RECORD."; + + "\nThe record 'PRODUCT_TITLE' has been just updated by USER_FULLNAME." + + "\nYou can inspect it here: LINK_RECORD."; private static final String EMAIL_MESSAGE_REVIEWER = "Dear GRSF Reviewer," + "
an update on the record named 'PRODUCT_TITLE' has been requested by USER_FULLNAME." @@ -311,12 +311,16 @@ public class SocialCommunications { // require url String applicationToken = requireApplicationToken(serviceUrl); - - final String profilePageURL = GCubePortalConstants.PREFIX_GROUP_URL + extractOrgFriendlyURL(userCurrentUrl) + GCubePortalConstants.USER_PROFILE_FRIENDLY_URL; + + //see Feature #17576 Updated by Francesco + /*final String profilePageURL = GCubePortalConstants.PREFIX_GROUP_URL + extractOrgFriendlyURL(userCurrentUrl) + GCubePortalConstants.USER_PROFILE_FRIENDLY_URL; String userFullNameHighlighted = ""+fullName+ " "; + */ + + String userFullNameHighlighted = "@"+username; // replace String message = POST_MESSAGE.replace("PRODUCT_TITLE", bean.getTitle()).replace("LINK_RECORD", bean.getUrl()).