suuport for calendar events completed, testing phase inititated
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/user/notifications@79061 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
386512ed63
commit
e4d7b8346c
|
@ -127,7 +127,7 @@ public class NotificationSettingsDialog extends GCubeDialog {
|
||||||
mainPanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
|
mainPanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
|
||||||
if (success) {
|
if (success) {
|
||||||
setText("Notifications Settings Saved");
|
setText("Notifications Settings Saved");
|
||||||
mainPanel.add(new HTML("<span style=\"font-size: 28px;\">Notifications Settings correctly saved.</span>"));
|
mainPanel.add(new HTML("<span style=\"font-size: 24px;\">Notifications Settings correctly saved.</span>"));
|
||||||
mainPanel.add(new Image(mailSentOK));
|
mainPanel.add(new Image(mailSentOK));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -143,8 +143,8 @@ public class NotificationSettingsDialog extends GCubeDialog {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
Button close = new Button("Close");
|
Button close = new Button("Close");
|
||||||
close.setSize("200px", "70px");
|
close.setSize("150px", "40px");
|
||||||
close.getElement().getStyle().setFontSize(24, Unit.PX);
|
close.getElement().getStyle().setFontSize(16, Unit.PX);
|
||||||
close.addClickHandler(new ClickHandler() {
|
close.addClickHandler(new ClickHandler() {
|
||||||
@Override
|
@Override
|
||||||
public void onClick(ClickEvent event) {
|
public void onClick(ClickEvent event) {
|
||||||
|
|
|
@ -52,7 +52,6 @@ public class SingleNotificationView extends Composite {
|
||||||
String removeMarkup = notificationToShow.replaceAll("&", "&");
|
String removeMarkup = notificationToShow.replaceAll("&", "&");
|
||||||
String actualHTML = new HTML(removeMarkup).getText();
|
String actualHTML = new HTML(removeMarkup).getText();
|
||||||
|
|
||||||
|
|
||||||
//in case of links behave differently, i know is terrible //TODO: write better code here i think
|
//in case of links behave differently, i know is terrible //TODO: write better code here i think
|
||||||
if (new HTML(actualHTML).getText().equalsIgnoreCase(LINK_TEXT)) {
|
if (new HTML(actualHTML).getText().equalsIgnoreCase(LINK_TEXT)) {
|
||||||
actualHTML = actualHTML.replace("your post:", "");
|
actualHTML = actualHTML.replace("your post:", "");
|
||||||
|
@ -104,6 +103,11 @@ public class SingleNotificationView extends Composite {
|
||||||
case WP_ITEM_UPDATED:
|
case WP_ITEM_UPDATED:
|
||||||
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> Go to Folder.</a>");
|
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> Go to Folder.</a>");
|
||||||
break;
|
break;
|
||||||
|
case CALENDAR_ADDED_EVENT:
|
||||||
|
case CALENDAR_UPDATED_EVENT:
|
||||||
|
case CALENDAR_DELETED_EVENT:
|
||||||
|
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> Go to Calendar.</a>");
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -151,6 +155,12 @@ public class SingleNotificationView extends Composite {
|
||||||
return images.workflowForward();
|
return images.workflowForward();
|
||||||
case DOCUMENT_WORKFLOW_FORWARD_STEP_COMPLETED_OWNER:
|
case DOCUMENT_WORKFLOW_FORWARD_STEP_COMPLETED_OWNER:
|
||||||
return images.workflowForwardComplete();
|
return images.workflowForwardComplete();
|
||||||
|
case CALENDAR_ADDED_EVENT:
|
||||||
|
return images.calendar();
|
||||||
|
case CALENDAR_UPDATED_EVENT:
|
||||||
|
return images.calendarEdit();
|
||||||
|
case CALENDAR_DELETED_EVENT:
|
||||||
|
return images.calendarDelete();
|
||||||
default:
|
default:
|
||||||
return images.generic();
|
return images.generic();
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,6 +16,15 @@ public interface NotificationImages extends ClientBundle {
|
||||||
@Source("mail.png")
|
@Source("mail.png")
|
||||||
ImageResource message();
|
ImageResource message();
|
||||||
|
|
||||||
|
@Source("calendar.png")
|
||||||
|
ImageResource calendar();
|
||||||
|
|
||||||
|
@Source("calendar_edit.png")
|
||||||
|
ImageResource calendarEdit();
|
||||||
|
|
||||||
|
@Source("calendar_delete.png")
|
||||||
|
ImageResource calendarDelete();
|
||||||
|
|
||||||
@Source("share_blue.png")
|
@Source("share_blue.png")
|
||||||
ImageResource share();
|
ImageResource share();
|
||||||
|
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 601 B |
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
Binary file not shown.
After Width: | Height: | Size: 646 B |
|
@ -132,6 +132,7 @@ public class NotificationsServiceImpl extends RemoteServiceServlet implements No
|
||||||
} else {
|
} else {
|
||||||
toReturn.get(dateWithoutTime).add(notification);
|
toReturn.get(dateWithoutTime).add(notification);
|
||||||
}
|
}
|
||||||
|
System.out.println(notification.getDescription());
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
_log.error("While trying to get User notifications");
|
_log.error("While trying to get User notifications");
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 4.0 KiB |
Loading…
Reference in New Issue