integrated gwt bootstrap 2 for notification settings modal
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/user/notifications@115398 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
9fc46962bb
commit
c56c77c0c8
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<classpath>
|
<classpath>
|
||||||
<classpathentry kind="src" output="target/notifications-1.3.1-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
<classpathentry kind="src" output="target/notifications-1.4.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="optional" value="true"/>
|
<attribute name="optional" value="true"/>
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
|
@ -30,5 +30,5 @@
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry kind="output" path="target/notifications-1.3.1-SNAPSHOT/WEB-INF/classes"/>
|
<classpathentry kind="output" path="target/notifications-1.4.0-SNAPSHOT/WEB-INF/classes"/>
|
||||||
</classpath>
|
</classpath>
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
eclipse.preferences.version=1
|
||||||
|
validateFragments=false
|
||||||
|
validation.use-project-settings=true
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
|
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
|
||||||
<wb-module deploy-name="${module}">
|
<wb-module deploy-name="notifications-portlet">
|
||||||
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
|
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
|
||||||
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
||||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
||||||
|
|
|
@ -4,4 +4,5 @@
|
||||||
<installed facet="wst.jsdt.web" version="1.0"/>
|
<installed facet="wst.jsdt.web" version="1.0"/>
|
||||||
<installed facet="jst.web" version="2.5"/>
|
<installed facet="jst.web" version="2.5"/>
|
||||||
<installed facet="java" version="1.7"/>
|
<installed facet="java" version="1.7"/>
|
||||||
|
<installed facet="liferay.portlet" version="6.0"/>
|
||||||
</faceted-project>
|
</faceted-project>
|
||||||
|
|
12
pom.xml
12
pom.xml
|
@ -13,12 +13,12 @@
|
||||||
<groupId>org.gcube.portlets.user</groupId>
|
<groupId>org.gcube.portlets.user</groupId>
|
||||||
<artifactId>notifications</artifactId>
|
<artifactId>notifications</artifactId>
|
||||||
<packaging>war</packaging>
|
<packaging>war</packaging>
|
||||||
<version>1.3.1-SNAPSHOT</version>
|
<version>1.4.0-SNAPSHOT</version>
|
||||||
<name>gCube Notifications Portlet</name>
|
<name>gCube Notifications Portlet</name>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<!-- Convenience property to set the GWT version -->
|
<!-- Convenience property to set the GWT version -->
|
||||||
<gwtVersion>2.5.1</gwtVersion>
|
<gwtVersion>2.7.0</gwtVersion>
|
||||||
<distroDirectory>distro</distroDirectory>
|
<distroDirectory>distro</distroDirectory>
|
||||||
<maven.compiler.source>1.7</maven.compiler.source>
|
<maven.compiler.source>1.7</maven.compiler.source>
|
||||||
<maven.compiler.target>1.7</maven.compiler.target>
|
<maven.compiler.target>1.7</maven.compiler.target>
|
||||||
|
@ -42,13 +42,20 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.google.gwt</groupId>
|
<groupId>com.google.gwt</groupId>
|
||||||
<artifactId>gwt-user</artifactId>
|
<artifactId>gwt-user</artifactId>
|
||||||
|
<version>2.7.0</version>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.google.gwt</groupId>
|
<groupId>com.google.gwt</groupId>
|
||||||
<artifactId>gwt-servlet</artifactId>
|
<artifactId>gwt-servlet</artifactId>
|
||||||
|
<version>2.7.0</version>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.github.gwtbootstrap</groupId>
|
||||||
|
<artifactId>gwt-bootstrap</artifactId>
|
||||||
|
<version>2.3.2.0</version>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.googlecode.gwtquery</groupId>
|
<groupId>com.googlecode.gwtquery</groupId>
|
||||||
<artifactId>gwtquery</artifactId>
|
<artifactId>gwtquery</artifactId>
|
||||||
|
@ -85,6 +92,7 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.core</groupId>
|
<groupId>org.gcube.core</groupId>
|
||||||
<artifactId>common-scope-maps</artifactId>
|
<artifactId>common-scope-maps</artifactId>
|
||||||
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.applicationsupportlayer</groupId>
|
<groupId>org.gcube.applicationsupportlayer</groupId>
|
||||||
|
|
|
@ -3,50 +3,36 @@ package org.gcube.portlets.user.notifications.client.view;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.LinkedHashMap;
|
import java.util.LinkedHashMap;
|
||||||
import java.util.List;
|
|
||||||
import java.util.TreeMap;
|
|
||||||
|
|
||||||
import org.gcube.portal.databook.shared.NotificationChannelType;
|
import org.gcube.portal.databook.shared.NotificationChannelType;
|
||||||
import org.gcube.portal.databook.shared.NotificationType;
|
import org.gcube.portal.databook.shared.NotificationType;
|
||||||
import org.gcube.portlets.user.gcubewidgets.client.popup.GCubeDialog;
|
|
||||||
import org.gcube.portlets.user.notifications.client.NotificationsServiceAsync;
|
import org.gcube.portlets.user.notifications.client.NotificationsServiceAsync;
|
||||||
import org.gcube.portlets.user.notifications.client.view.templates.CategoryWrapper;
|
import org.gcube.portlets.user.notifications.client.view.templates.CategoryWrapper;
|
||||||
import org.gcube.portlets.user.notifications.client.view.templates.NotificationPreferenceView;
|
|
||||||
import org.gcube.portlets.user.notifications.shared.NotificationPreference;
|
import org.gcube.portlets.user.notifications.shared.NotificationPreference;
|
||||||
|
|
||||||
|
import com.github.gwtbootstrap.client.ui.Modal;
|
||||||
|
import com.github.gwtbootstrap.client.ui.ModalFooter;
|
||||||
import com.google.gwt.core.client.GWT;
|
import com.google.gwt.core.client.GWT;
|
||||||
import com.google.gwt.dom.client.Style.Unit;
|
import com.google.gwt.dom.client.Style.Unit;
|
||||||
import com.google.gwt.event.dom.client.ClickEvent;
|
import com.google.gwt.event.dom.client.ClickEvent;
|
||||||
import com.google.gwt.event.dom.client.ClickHandler;
|
import com.google.gwt.event.dom.client.ClickHandler;
|
||||||
import com.google.gwt.user.client.DOM;
|
|
||||||
import com.google.gwt.user.client.Timer;
|
|
||||||
import com.google.gwt.user.client.Window;
|
|
||||||
import com.google.gwt.user.client.rpc.AsyncCallback;
|
import com.google.gwt.user.client.rpc.AsyncCallback;
|
||||||
import com.google.gwt.user.client.ui.Button;
|
import com.github.gwtbootstrap.client.ui.Button;
|
||||||
import com.google.gwt.user.client.ui.CheckBox;
|
import com.github.gwtbootstrap.client.ui.constants.ButtonType;
|
||||||
import com.google.gwt.user.client.ui.HTML;
|
import com.google.gwt.user.client.ui.HTML;
|
||||||
import com.google.gwt.user.client.ui.HasAlignment;
|
import com.google.gwt.user.client.ui.HasAlignment;
|
||||||
import com.google.gwt.user.client.ui.HasHorizontalAlignment;
|
|
||||||
import com.google.gwt.user.client.ui.HasVerticalAlignment;
|
import com.google.gwt.user.client.ui.HasVerticalAlignment;
|
||||||
import com.google.gwt.user.client.ui.HorizontalPanel;
|
|
||||||
import com.google.gwt.user.client.ui.Image;
|
import com.google.gwt.user.client.ui.Image;
|
||||||
import com.google.gwt.user.client.ui.Label;
|
|
||||||
import com.google.gwt.user.client.ui.ScrollPanel;
|
|
||||||
import com.google.gwt.user.client.ui.VerticalPanel;
|
import com.google.gwt.user.client.ui.VerticalPanel;
|
||||||
import com.google.gwt.user.client.ui.Widget;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Massimiliano Assante ISTI-CNR
|
* @author Massimiliano Assante ISTI-CNR
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class NotificationSettingsDialog extends GCubeDialog {
|
public class NotificationSettingsDialog extends Modal {
|
||||||
|
|
||||||
private VerticalPanel mainPanel = new VerticalPanel();
|
private VerticalPanel mainPanel = new VerticalPanel();
|
||||||
private VerticalPanel container = new VerticalPanel();
|
|
||||||
private HorizontalPanel buttonsContainerPanel = new HorizontalPanel();
|
|
||||||
private HorizontalPanel buttonsPanel = new HorizontalPanel();
|
|
||||||
|
|
||||||
public static final String loading = GWT.getModuleBaseURL() + "../images/feeds-loader.gif";
|
public static final String loading = GWT.getModuleBaseURL() + "../images/feeds-loader.gif";
|
||||||
public static final String mailSentOK = GWT.getModuleBaseURL() + "../images/yes.png";
|
public static final String mailSentOK = GWT.getModuleBaseURL() + "../images/yes.png";
|
||||||
|
@ -59,32 +45,22 @@ public class NotificationSettingsDialog extends GCubeDialog {
|
||||||
|
|
||||||
public NotificationSettingsDialog(LinkedHashMap<String, ArrayList<NotificationPreference>> preferences, final NotificationsServiceAsync notificationService) {
|
public NotificationSettingsDialog(LinkedHashMap<String, ArrayList<NotificationPreference>> preferences, final NotificationsServiceAsync notificationService) {
|
||||||
super();
|
super();
|
||||||
ScrollPanel scroller = new ScrollPanel();
|
setAnimation(true);
|
||||||
scroller.setWidth("890px");
|
//container.setStyleName("user-notification");
|
||||||
scroller.setHeight("500px");
|
setWidth(950);
|
||||||
buttonsPanel.setWidth("100%");
|
|
||||||
buttonsPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_RIGHT);
|
|
||||||
|
|
||||||
container.setStyleName("user-notification");
|
|
||||||
container.setWidth("850px");
|
|
||||||
|
|
||||||
for (String category : preferences.keySet()) {
|
for (String category : preferences.keySet()) {
|
||||||
CategoryWrapper cat = new CategoryWrapper(category, preferences.get(category));
|
CategoryWrapper cat = new CategoryWrapper(category, preferences.get(category));
|
||||||
container.add(cat);
|
add(cat);
|
||||||
myCategories.add(cat);
|
myCategories.add(cat);
|
||||||
}
|
}
|
||||||
|
|
||||||
buttonsContainerPanel.add(cancel);
|
setTitle("Notification Settings");
|
||||||
buttonsContainerPanel.add(save);
|
|
||||||
buttonsPanel.add(buttonsContainerPanel);
|
|
||||||
//container.add(buttonsPanel);
|
|
||||||
|
|
||||||
|
ModalFooter footer = new ModalFooter();
|
||||||
setText("Notification Settings");
|
save.setType(ButtonType.PRIMARY);
|
||||||
scroller.add(container);
|
footer.add(save);
|
||||||
mainPanel.add(scroller);
|
footer.add(cancel);
|
||||||
mainPanel.add(buttonsPanel);
|
add(footer);
|
||||||
setWidget(mainPanel);
|
|
||||||
|
|
||||||
save.addClickHandler(new ClickHandler() {
|
save.addClickHandler(new ClickHandler() {
|
||||||
@Override
|
@Override
|
||||||
|
@ -126,12 +102,12 @@ public class NotificationSettingsDialog extends GCubeDialog {
|
||||||
mainPanel.setHorizontalAlignment(HasAlignment.ALIGN_CENTER);
|
mainPanel.setHorizontalAlignment(HasAlignment.ALIGN_CENTER);
|
||||||
mainPanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
|
mainPanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
|
||||||
if (success) {
|
if (success) {
|
||||||
setText("Notifications Settings Saved");
|
setTitle("Notifications Settings Saved");
|
||||||
mainPanel.add(new HTML("<span style=\"font-size: 24px;\">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 {
|
||||||
setText("Notifications Settings Saving Error");
|
setTitle("Notifications Settings Saving Error");
|
||||||
mainPanel.add(new Image(mailSentNOK));
|
mainPanel.add(new Image(mailSentNOK));
|
||||||
mainPanel.add(new HTML("There were problems contacting the server, please try again in a short while."));
|
mainPanel.add(new HTML("There were problems contacting the server, please try again in a short while."));
|
||||||
Button close = new Button("Close");
|
Button close = new Button("Close");
|
||||||
|
|
|
@ -107,7 +107,6 @@ public class NotificationsPanel extends Composite {
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(LinkedHashMap<String, ArrayList<NotificationPreference>> result) {
|
public void onSuccess(LinkedHashMap<String, ArrayList<NotificationPreference>> result) {
|
||||||
NotificationSettingsDialog dlg = new NotificationSettingsDialog(result, notificationService);
|
NotificationSettingsDialog dlg = new NotificationSettingsDialog(result, notificationService);
|
||||||
dlg.center();
|
|
||||||
dlg.show();
|
dlg.show();
|
||||||
showSettingsLoader(false);
|
showSettingsLoader(false);
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,7 @@ import com.google.gwt.event.logical.shared.ValueChangeEvent;
|
||||||
import com.google.gwt.event.logical.shared.ValueChangeHandler;
|
import com.google.gwt.event.logical.shared.ValueChangeHandler;
|
||||||
import com.google.gwt.uibinder.client.UiBinder;
|
import com.google.gwt.uibinder.client.UiBinder;
|
||||||
import com.google.gwt.uibinder.client.UiField;
|
import com.google.gwt.uibinder.client.UiField;
|
||||||
import com.google.gwt.user.client.ui.CheckBox;
|
import com.github.gwtbootstrap.client.ui.CheckBox;
|
||||||
import com.google.gwt.user.client.ui.Composite;
|
import com.google.gwt.user.client.ui.Composite;
|
||||||
import com.google.gwt.user.client.ui.VerticalPanel;
|
import com.google.gwt.user.client.ui.VerticalPanel;
|
||||||
import com.google.gwt.user.client.ui.Widget;
|
import com.google.gwt.user.client.ui.Widget;
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
|
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
|
||||||
xmlns:w="urn:import:org.gcube.portlets.widgets.switchbutton.client"
|
xmlns:w="urn:import:org.gcube.portlets.widgets.switchbutton.client"
|
||||||
xmlns:e="urn:import:org.gcube.portlets.user.gcubewidgets.client.elements"
|
xmlns:e="urn:import:org.gcube.portlets.user.gcubewidgets.client.elements"
|
||||||
xmlns:g="urn:import:com.google.gwt.user.client.ui">
|
xmlns:b="urn:import:com.github.gwtbootstrap.client.ui" xmlns:g="urn:import:com.google.gwt.user.client.ui">
|
||||||
<g:HTMLPanel>
|
<g:HTMLPanel>
|
||||||
<div class="day-wrapper">
|
<div class="day-wrapper">
|
||||||
<e:Span styleName="day-label" ui:field="categoryLabel" />
|
<e:Span styleName="day-label" ui:field="categoryLabel" />
|
||||||
|
@ -10,8 +10,10 @@
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<g:CheckBox ui:field="portalCheckbox">Portal</g:CheckBox>
|
<b:CheckBox ui:field="portalCheckbox">Portal</b:CheckBox>
|
||||||
<g:CheckBox ui:field="emailCheckbox">Email</g:CheckBox>
|
</td>
|
||||||
|
<td>
|
||||||
|
<b:CheckBox ui:field="emailCheckbox">Email</b:CheckBox>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<w:SwitchButton ui:field="switchButton" styleName="paddingLeft" />
|
<w:SwitchButton ui:field="switchButton" styleName="paddingLeft" />
|
||||||
|
|
|
@ -15,7 +15,7 @@ import com.google.gwt.event.logical.shared.ValueChangeEvent;
|
||||||
import com.google.gwt.event.logical.shared.ValueChangeHandler;
|
import com.google.gwt.event.logical.shared.ValueChangeHandler;
|
||||||
import com.google.gwt.uibinder.client.UiBinder;
|
import com.google.gwt.uibinder.client.UiBinder;
|
||||||
import com.google.gwt.uibinder.client.UiField;
|
import com.google.gwt.uibinder.client.UiField;
|
||||||
import com.google.gwt.user.client.ui.CheckBox;
|
import com.github.gwtbootstrap.client.ui.CheckBox;
|
||||||
import com.google.gwt.user.client.ui.Composite;
|
import com.google.gwt.user.client.ui.Composite;
|
||||||
import com.google.gwt.user.client.ui.Widget;
|
import com.google.gwt.user.client.ui.Widget;
|
||||||
|
|
||||||
|
|
|
@ -2,17 +2,22 @@
|
||||||
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
|
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
|
||||||
xmlns:e="urn:import:org.gcube.portlets.user.gcubewidgets.client.elements"
|
xmlns:e="urn:import:org.gcube.portlets.user.gcubewidgets.client.elements"
|
||||||
xmlns:w="urn:import:org.gcube.portlets.widgets.switchbutton.client"
|
xmlns:w="urn:import:org.gcube.portlets.widgets.switchbutton.client"
|
||||||
xmlns:g="urn:import:com.google.gwt.user.client.ui">
|
xmlns:b="urn:import:com.github.gwtbootstrap.client.ui" xmlns:g="urn:import:com.google.gwt.user.client.ui">
|
||||||
<g:HTMLPanel>
|
<g:HTMLPanel>
|
||||||
<table class="single-notification-table">
|
<table class="single-notification-table">
|
||||||
<tr>
|
<tr>
|
||||||
<td valign="TOP" style="width: 200px;" align="left">
|
<td valign="TOP" style="width: 200px;" align="left">
|
||||||
<e:Span styleName="user-notification" ui:field="prefType" />
|
<e:Span styleName="user-notification" ui:field="prefType" />
|
||||||
</td>
|
</td>
|
||||||
<td valign="TOP" style="width: 250px;">
|
<td valign="TOP" style="width: 60px;">
|
||||||
<g:CheckBox ui:field="portalCheckbox">Portal</g:CheckBox>
|
<b:CheckBox ui:field="portalCheckbox">Portal</b:CheckBox>
|
||||||
<g:CheckBox ui:field="emailCheckbox">Email</g:CheckBox>
|
</td>
|
||||||
<w:SwitchButton ui:field="switchButton" styleName="floatingRight paddingRight"/>
|
<td valign="TOP" style="width: 60px;">
|
||||||
|
<b:CheckBox ui:field="emailCheckbox">Email</b:CheckBox>
|
||||||
|
</td>
|
||||||
|
<td valign="TOP" style="width: 150px;">
|
||||||
|
<w:SwitchButton ui:field="switchButton"
|
||||||
|
styleName="floatingRight paddingRight" />
|
||||||
</td>
|
</td>
|
||||||
<td valign="TOP">
|
<td valign="TOP">
|
||||||
<e:Span styleName="user-notification-comment" ui:field="prefDesc" />
|
<e:Span styleName="user-notification-comment" ui:field="prefDesc" />
|
||||||
|
|
|
@ -117,6 +117,13 @@ public class SingleNotificationView extends Composite {
|
||||||
case CALENDAR_DELETED_EVENT:
|
case CALENDAR_DELETED_EVENT:
|
||||||
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> Go to Calendar.</a>");
|
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> Go to Calendar.</a>");
|
||||||
break;
|
break;
|
||||||
|
case TDM_TAB_RESOURCE_SHARE:
|
||||||
|
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> See this Tabular Resource.</a>");
|
||||||
|
break;
|
||||||
|
case TDM_RULE_SHARE:
|
||||||
|
case TDM_TEMPLATE_SHARE:
|
||||||
|
goApp.setHTML("<a class=\"link\" href=\""+toShow.getUri()+"\"> Go to Tabular Data Manager.</a>");
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -169,6 +176,10 @@ public class SingleNotificationView extends Composite {
|
||||||
return images.calendarDelete();
|
return images.calendarDelete();
|
||||||
case POST_ALERT:
|
case POST_ALERT:
|
||||||
return images.postAlert();
|
return images.postAlert();
|
||||||
|
case TDM_TAB_RESOURCE_SHARE:
|
||||||
|
case TDM_RULE_SHARE:
|
||||||
|
case TDM_TEMPLATE_SHARE:
|
||||||
|
return images.tableShare();
|
||||||
default:
|
default:
|
||||||
return images.generic();
|
return images.generic();
|
||||||
}
|
}
|
||||||
|
|
|
@ -57,4 +57,7 @@ public interface NotificationImages extends ClientBundle {
|
||||||
|
|
||||||
@Source("notification-generic.png")
|
@Source("notification-generic.png")
|
||||||
ImageResource generic();
|
ImageResource generic();
|
||||||
|
|
||||||
|
@Source("table_share.png")
|
||||||
|
ImageResource tableShare();
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 744 B |
|
@ -90,7 +90,7 @@ public class NotificationsServiceImpl extends RemoteServiceServlet implements No
|
||||||
*/
|
*/
|
||||||
public String getDevelopmentUser() {
|
public String getDevelopmentUser() {
|
||||||
String user = "test.user";
|
String user = "test.user";
|
||||||
//user = "massimiliano.assante";
|
user = "massimiliano.assante";
|
||||||
return user;
|
return user;
|
||||||
}
|
}
|
||||||
public UserInfo getUserInfo() {
|
public UserInfo getUserInfo() {
|
||||||
|
@ -256,14 +256,14 @@ public class NotificationsServiceImpl extends RemoteServiceServlet implements No
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param type the type to look for
|
* @param type the type to look for
|
||||||
* @return the Category if there is correspodance, null otherwise
|
* @return the Category if there is correspondance, null otherwise
|
||||||
*/
|
*/
|
||||||
private Properties getCategoriesByType() {
|
private Properties getCategoriesByType() {
|
||||||
Properties props = new Properties();
|
Properties props = new Properties();
|
||||||
try {
|
try {
|
||||||
ServletContext servletContext = getServletContext();
|
ServletContext servletContext = getServletContext();
|
||||||
String contextPath = servletContext.getRealPath(File.separator);
|
String contextPath = servletContext.getRealPath(File.separator);
|
||||||
String propertyfile = contextPath + "conf" + File.separator + TYPE_CATEGORIES_FILENAME;
|
String propertyfile = contextPath + File.separator + "conf" + File.separator + TYPE_CATEGORIES_FILENAME;
|
||||||
File propsFile = new File(propertyfile);
|
File propsFile = new File(propertyfile);
|
||||||
FileInputStream fis = new FileInputStream(propsFile);
|
FileInputStream fis = new FileInputStream(propsFile);
|
||||||
props.load(fis);
|
props.load(fis);
|
||||||
|
@ -281,10 +281,11 @@ public class NotificationsServiceImpl extends RemoteServiceServlet implements No
|
||||||
*/
|
*/
|
||||||
private Properties getLabelsByType() {
|
private Properties getLabelsByType() {
|
||||||
Properties props = new Properties();
|
Properties props = new Properties();
|
||||||
|
String propertyfile = "";
|
||||||
try {
|
try {
|
||||||
ServletContext servletContext = getServletContext();
|
ServletContext servletContext = getServletContext();
|
||||||
String contextPath = servletContext.getRealPath(File.separator);
|
String contextPath = servletContext.getRealPath(File.separator);
|
||||||
String propertyfile = contextPath + "conf" + File.separator + TYPE_LABELS_FILENAME;
|
propertyfile = contextPath + File.separator + "conf" + File.separator + TYPE_LABELS_FILENAME;
|
||||||
File propsFile = new File(propertyfile);
|
File propsFile = new File(propertyfile);
|
||||||
FileInputStream fis = new FileInputStream(propsFile);
|
FileInputStream fis = new FileInputStream(propsFile);
|
||||||
props.load( fis);
|
props.load( fis);
|
||||||
|
@ -292,7 +293,7 @@ public class NotificationsServiceImpl extends RemoteServiceServlet implements No
|
||||||
}
|
}
|
||||||
//catch exception in case properties file does not exist
|
//catch exception in case properties file does not exist
|
||||||
catch(IOException e) {
|
catch(IOException e) {
|
||||||
_log.error(TYPE_LABELS_FILENAME + "file not found under conf dir, returning null");
|
_log.error(TYPE_LABELS_FILENAME + "file not found under conf dir, returning null propertyfile -> " + propertyfile);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -305,7 +306,7 @@ public class NotificationsServiceImpl extends RemoteServiceServlet implements No
|
||||||
try {
|
try {
|
||||||
ServletContext servletContext = getServletContext();
|
ServletContext servletContext = getServletContext();
|
||||||
String contextPath = servletContext.getRealPath(File.separator);
|
String contextPath = servletContext.getRealPath(File.separator);
|
||||||
String propertyfile = contextPath + "conf" + File.separator + TYPE_DESCRIPTIONS_FILENAME;
|
String propertyfile = contextPath + File.separator +"conf" + File.separator + TYPE_DESCRIPTIONS_FILENAME;
|
||||||
File propsFile = new File(propertyfile);
|
File propsFile = new File(propertyfile);
|
||||||
FileInputStream fis = new FileInputStream(propsFile);
|
FileInputStream fis = new FileInputStream(propsFile);
|
||||||
props.load( fis);
|
props.load( fis);
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
<!-- Other module inherits -->
|
<!-- Other module inherits -->
|
||||||
<!-- inherits gCube Widgets Library -->
|
<!-- inherits gCube Widgets Library -->
|
||||||
<inherits name='org.gcube.portlets.user.gcubewidgets.WidgetFactory' />
|
<inherits name='org.gcube.portlets.user.gcubewidgets.WidgetFactory' />
|
||||||
|
<inherits name="com.github.gwtbootstrap.Bootstrap" />
|
||||||
<inherits name='org.gcube.portlets.widgets.switchbutton.SwitchButton' />
|
<inherits name='org.gcube.portlets.widgets.switchbutton.SwitchButton' />
|
||||||
<inherits name='org.gcube.portal.databook.GCubeSocialNetworking' />
|
<inherits name='org.gcube.portal.databook.GCubeSocialNetworking' />
|
||||||
<!-- Specify the app entry point class. -->
|
<!-- Specify the app entry point class. -->
|
||||||
|
|
|
@ -78,9 +78,9 @@ a.link:hover {
|
||||||
}
|
}
|
||||||
|
|
||||||
.single-notification-table {
|
.single-notification-table {
|
||||||
width: 100%;
|
width: 920px;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
border-top: 1px solid #EFEFEF;
|
border-bottom: 1px solid #EFEFEF;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@ a.link:hover {
|
||||||
.notification-photo {
|
.notification-photo {
|
||||||
display: block;
|
display: block;
|
||||||
padding: 2px;
|
padding: 2px;
|
||||||
border: 1px solid #E6E6E6;
|
border: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-notification-time {
|
.user-notification-time {
|
||||||
|
|
|
@ -1,10 +1,13 @@
|
||||||
DOCUMENT_WORKFLOW_EDIT=Document Workflow
|
DOCUMENT_WORKFLOW_EDIT=Application: Document Workflow
|
||||||
DOCUMENT_WORKFLOW_VIEW=Document Workflow
|
DOCUMENT_WORKFLOW_VIEW=Application: Document Workflow
|
||||||
DOCUMENT_WORKFLOW_STEP_REQUEST_TASK=Document Workflow
|
DOCUMENT_WORKFLOW_STEP_REQUEST_TASK=Application: Document Workflow
|
||||||
DOCUMENT_WORKFLOW_FIRST_STEP_REQUEST_INVOLVMENT=Document Workflow
|
DOCUMENT_WORKFLOW_FIRST_STEP_REQUEST_INVOLVMENT=Application: Document Workflow
|
||||||
DOCUMENT_WORKFLOW_USER_FORWARD_TO_OWNER=Document Workflow
|
DOCUMENT_WORKFLOW_USER_FORWARD_TO_OWNER=Application: Document Workflow
|
||||||
DOCUMENT_WORKFLOW_FORWARD_STEP_COMPLETED_OWNER=Document Workflow
|
DOCUMENT_WORKFLOW_FORWARD_STEP_COMPLETED_OWNER=Application: Document Workflow
|
||||||
DOCUMENT_WORKFLOW_STEP_FORWARD_PEER=Document Workflow
|
DOCUMENT_WORKFLOW_STEP_FORWARD_PEER=Application: Document Workflow
|
||||||
|
TDM_TAB_RESOURCE_SHARE=Application: Tabular Data Manager
|
||||||
|
TDM_RULE_SHARE=Application: Tabular Data Manager
|
||||||
|
TDM_TEMPLATE_SHARE=Application: Tabular Data Manager
|
||||||
WP_FOLDER_SHARE=Workspace Sharing
|
WP_FOLDER_SHARE=Workspace Sharing
|
||||||
WP_FOLDER_UNSHARE=Workspace Sharing
|
WP_FOLDER_UNSHARE=Workspace Sharing
|
||||||
WP_ADMIN_UPGRADE=Workspace Sharing
|
WP_ADMIN_UPGRADE=Workspace Sharing
|
||||||
|
|
|
@ -25,3 +25,6 @@ DOCUMENT_WORKFLOW_STEP_FORWARD_PEER=Someone completed his task on a document wor
|
||||||
CALENDAR_ADDED_EVENT=Someone added a new event in one of your shared calendars
|
CALENDAR_ADDED_EVENT=Someone added a new event in one of your shared calendars
|
||||||
CALENDAR_UPDATED_EVENT=Someone edited an event in one of your shared calendars
|
CALENDAR_UPDATED_EVENT=Someone edited an event in one of your shared calendars
|
||||||
CALENDAR_DELETED_EVENT=Someone deleted an event in one of your shared calendars
|
CALENDAR_DELETED_EVENT=Someone deleted an event in one of your shared calendars
|
||||||
|
TDM_TAB_RESOURCE_SHARE=Sharing of Tabular Resources with you
|
||||||
|
TDM_RULE_SHARE=Sharing of Tabular Data Manager Rules with you
|
||||||
|
TDM_TEMPLATE_SHARE=Sharing of Tabular Data Manager Templates with you
|
|
@ -18,6 +18,9 @@ POST_ALERT=Post Alerts
|
||||||
CALENDAR_ADDED_EVENT=Added events
|
CALENDAR_ADDED_EVENT=Added events
|
||||||
CALENDAR_UPDATED_EVENT=Edited events
|
CALENDAR_UPDATED_EVENT=Edited events
|
||||||
CALENDAR_DELETED_EVENT=Deleted events
|
CALENDAR_DELETED_EVENT=Deleted events
|
||||||
|
TDM_TAB_RESOURCE_SHARE=Shared Tabular Resource
|
||||||
|
TDM_RULE_SHARE=Shared Tabular Data Manager Rule
|
||||||
|
TDM_TEMPLATE_SHARE=Shared Tabular Data Manager Template
|
||||||
DOCUMENT_WORKFLOW_EDIT=Edit
|
DOCUMENT_WORKFLOW_EDIT=Edit
|
||||||
DOCUMENT_WORKFLOW_VIEW=View
|
DOCUMENT_WORKFLOW_VIEW=View
|
||||||
DOCUMENT_WORKFLOW_STEP_REQUEST_TASK=Task request
|
DOCUMENT_WORKFLOW_STEP_REQUEST_TASK=Task request
|
||||||
|
@ -25,3 +28,4 @@ DOCUMENT_WORKFLOW_FIRST_STEP_REQUEST_INVOLVMENT=Involvement request
|
||||||
DOCUMENT_WORKFLOW_USER_FORWARD_TO_OWNER=Forward
|
DOCUMENT_WORKFLOW_USER_FORWARD_TO_OWNER=Forward
|
||||||
DOCUMENT_WORKFLOW_FORWARD_STEP_COMPLETED_OWNER=Step completed
|
DOCUMENT_WORKFLOW_FORWARD_STEP_COMPLETED_OWNER=Step completed
|
||||||
DOCUMENT_WORKFLOW_STEP_FORWARD_PEER=Forward from peer
|
DOCUMENT_WORKFLOW_STEP_FORWARD_PEER=Forward from peer
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue