added BoxOpenAireRedirect portlet
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/user/VREApp-Integration-portlet@178415 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
da24dc237d
commit
724c72858d
|
@ -0,0 +1,11 @@
|
|||
package org.gcube.portlets.user.generic;
|
||||
|
||||
import com.liferay.util.bridges.mvc.MVCPortlet;
|
||||
|
||||
/**
|
||||
* Portlet implementation class BoxOpenAireRedirect
|
||||
*/
|
||||
public class BoxOpenAireRedirect extends MVCPortlet {
|
||||
|
||||
|
||||
}
|
|
@ -6,4 +6,7 @@
|
|||
<portlet id="vre-app-integration"></portlet>
|
||||
<portlet id="knime-app-integration"></portlet>
|
||||
</category>
|
||||
<category name="OpenAIRE">
|
||||
<portlet id="box-open-aire-redirect"></portlet>
|
||||
</category>
|
||||
</display>
|
|
@ -28,6 +28,17 @@
|
|||
knime-app-integration-portlet
|
||||
</css-class-wrapper>
|
||||
</portlet>
|
||||
<portlet>
|
||||
<portlet-name>box-open-aire-redirect</portlet-name>
|
||||
<icon>/icon.png</icon>
|
||||
<header-portlet-css>/css/main.css</header-portlet-css>
|
||||
<footer-portlet-javascript>
|
||||
/js/main.js
|
||||
</footer-portlet-javascript>
|
||||
<css-class-wrapper>
|
||||
box-open-aire-redirect-portlet
|
||||
</css-class-wrapper>
|
||||
</portlet>
|
||||
<role-mapper>
|
||||
<role-name>administrator</role-name>
|
||||
<role-link>Administrator</role-link>
|
||||
|
|
|
@ -88,4 +88,41 @@
|
|||
<role-name>user</role-name>
|
||||
</security-role-ref>
|
||||
</portlet>
|
||||
<portlet>
|
||||
<portlet-name>box-open-aire-redirect</portlet-name>
|
||||
<display-name>Box Open Aire Redirect</display-name>
|
||||
<portlet-class>org.gcube.portlets.user.generic.BoxOpenAireRedirect</portlet-class>
|
||||
<init-param>
|
||||
<name>view-template</name>
|
||||
<value>/html/boxopenaireredirect/view.jsp</value>
|
||||
</init-param>
|
||||
<expiration-cache>0</expiration-cache>
|
||||
<supports>
|
||||
<mime-type>text/html</mime-type>
|
||||
<portlet-mode>view</portlet-mode>
|
||||
</supports>
|
||||
<portlet-info>
|
||||
<title>Box Open Aire Redirect</title>
|
||||
<short-title>Box Open Aire Redirect</short-title>
|
||||
<keywords></keywords>
|
||||
</portlet-info>
|
||||
<portlet-preferences>
|
||||
<preference>
|
||||
<name>portletSetupShowBorders</name>
|
||||
<value>false</value>
|
||||
</preference>
|
||||
</portlet-preferences>
|
||||
<security-role-ref>
|
||||
<role-name>administrator</role-name>
|
||||
</security-role-ref>
|
||||
<security-role-ref>
|
||||
<role-name>guest</role-name>
|
||||
</security-role-ref>
|
||||
<security-role-ref>
|
||||
<role-name>power-user</role-name>
|
||||
</security-role-ref>
|
||||
<security-role-ref>
|
||||
<role-name>user</role-name>
|
||||
</security-role-ref>
|
||||
</portlet>
|
||||
</portlet-app>
|
|
@ -0,0 +1,10 @@
|
|||
<%@ taglib uri="http://java.sun.com/portlet_2_0" prefix="portlet" %>
|
||||
<%@page import="com.liferay.portal.service.UserLocalServiceUtil"%>
|
||||
<%@ page import="com.liferay.portal.util.PortalUtil" %>
|
||||
<portlet:defineObjects />
|
||||
<%
|
||||
String screenName = UserLocalServiceUtil.getUser(PortalUtil.getUserId(request)).getScreenName();
|
||||
%>
|
||||
<script>
|
||||
location.href= 'https://box.openaire.eu?user=<%=screenName%>';
|
||||
</script>
|
Loading…
Reference in New Issue