modified to support Twitter Monitor Applicaiton
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portal/sbd-uploadshare-portlet@177259 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
aadfc31147
commit
3c872e1c6a
|
@ -25,6 +25,8 @@ public class AccessApplicationAction extends DefaultConfigurationAction {
|
|||
_log.info("applicationName2-Title = " + applicationName2Title + " in ConfigurationAction.processAction() saved correctly");
|
||||
String applicationName3Title = prefs.getValue("applicationName3-Title", "");
|
||||
_log.info("applicationName3-Title = " + applicationName3Title + " in ConfigurationAction.processAction() saved correctly");
|
||||
String applicationName4Title = prefs.getValue("applicationName4-Title", "");
|
||||
_log.info("applicationName4-Title = " + applicationName4Title + " in ConfigurationAction.processAction() saved correctly");
|
||||
|
||||
long applicationName1DocumentId = Long.parseLong(prefs.getValue("applicationName1-DocumentId", "0"));
|
||||
_log.info("applicationName1-DocumentId = " + applicationName1DocumentId + " in ConfigurationAction.processAction() saved correctly");
|
||||
|
@ -32,13 +34,17 @@ public class AccessApplicationAction extends DefaultConfigurationAction {
|
|||
_log.info("applicationName2-DocumentId = " + applicationName2DocumentId + " in ConfigurationAction.processAction() saved correctly");
|
||||
long applicationName3DocumentId = Long.parseLong(prefs.getValue("applicationName3-DocumentId", "0"));
|
||||
_log.info("applicationName3-DocumentId = " + applicationName3DocumentId + " in ConfigurationAction.processAction() saved correctly");
|
||||
|
||||
long applicationName4DocumentId = Long.parseLong(prefs.getValue("applicationName4-DocumentId", "0"));
|
||||
_log.info("applicationName4-DocumentId = " + applicationName4DocumentId + " in ConfigurationAction.processAction() saved correctly");
|
||||
|
||||
String application1Url = prefs.getValue("application1-Url", "");
|
||||
_log.info("application1-Url = " + application1Url + " in ConfigurationAction.processAction() saved correctly");
|
||||
String application2Url = prefs.getValue("application2-Url", "");
|
||||
_log.info("application2-Url = " + application2Url + " in ConfigurationAction.processAction() saved correctly");
|
||||
String application3Url = prefs.getValue("application3-Url", "");
|
||||
_log.info("application3-Url = " + application3Url + " in ConfigurationAction.processAction() saved correctly");
|
||||
String application4Url = prefs.getValue("application4-Url", "");
|
||||
_log.info("application4-Url = " + application4Url + " in ConfigurationAction.processAction() saved correctly");
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -11,14 +11,17 @@ Here you can customise the icon to show besides the application name
|
|||
String applicationName1Title = GetterUtil.getString(portletPreferences.getValue("applicationName1-Title", StringPool.BLANK));
|
||||
String applicationName2Title = GetterUtil.getString(portletPreferences.getValue("applicationName2-Title", StringPool.BLANK));
|
||||
String applicationName3Title = GetterUtil.getString(portletPreferences.getValue("applicationName3-Title", StringPool.BLANK));
|
||||
String applicationName4Title = GetterUtil.getString(portletPreferences.getValue("applicationName4-Title", StringPool.BLANK));
|
||||
|
||||
long applicationName1DocumentId = GetterUtil.getLong(portletPreferences.getValue("applicationName1-DocumentId", StringPool.BLANK));
|
||||
long applicationName2DocumentId = GetterUtil.getLong(portletPreferences.getValue("applicationName2-DocumentId", StringPool.BLANK));
|
||||
long applicationName3DocumentId = GetterUtil.getLong(portletPreferences.getValue("applicationName3-DocumentId", StringPool.BLANK));
|
||||
long applicationName4DocumentId = GetterUtil.getLong(portletPreferences.getValue("applicationName4-DocumentId", StringPool.BLANK));
|
||||
|
||||
String application1Url = GetterUtil.getString(portletPreferences.getValue("application1-Url", StringPool.BLANK));
|
||||
String application2Url = GetterUtil.getString(portletPreferences.getValue("application2-Url", StringPool.BLANK));
|
||||
String application3Url = GetterUtil.getString(portletPreferences.getValue("application3-Url", StringPool.BLANK));
|
||||
String application4Url = GetterUtil.getString(portletPreferences.getValue("application4-Url", StringPool.BLANK));
|
||||
|
||||
|
||||
String displayName_cfg = "";
|
||||
|
@ -117,6 +120,33 @@ Here you can customise the icon to show besides the application name
|
|||
</tr>
|
||||
</table>
|
||||
</aui:field-wrapper>
|
||||
<aui:field-wrapper cssClass="field-group">
|
||||
<table>
|
||||
<tr>
|
||||
<td><aui:input name="preferences--applicationName4-Title--"
|
||||
type="text" cssClass="text long-field" showRequiredLabel="true"
|
||||
label="application Name 4" inlineField="true" inlineLabel="left"
|
||||
placeholder="application"
|
||||
helpMessage="Display Name of the application"
|
||||
value="<%=applicationName4Title%>" required="false" /></td>
|
||||
<td><aui:input
|
||||
name="preferences--applicationName4-DocumentId--" type="text"
|
||||
cssClass="text long-field" showRequiredLabel="true"
|
||||
label="application Document Id 4" inlineField="true"
|
||||
inlineLabel="left" placeholder="ID"
|
||||
helpMessage="ID taken from Liferay CMS in this Site"
|
||||
value="<%=applicationName4DocumentId%>" required="false">
|
||||
<aui:validator name="digits"></aui:validator>
|
||||
</aui:input></td>
|
||||
<td><aui:input name="preferences--application4-Url--"
|
||||
type="text" cssClass="text long-field" showRequiredLabel="true"
|
||||
label="URL of the VRE 4" inlineField="true" inlineLabel="left"
|
||||
placeholder="url" helpMessage="URL" value="<%=application4Url%>"
|
||||
required="false">
|
||||
</aui:input></td>
|
||||
</tr>
|
||||
</table>
|
||||
</aui:field-wrapper>
|
||||
<aui:button-row>
|
||||
<aui:button type="submit" />
|
||||
</aui:button-row>
|
||||
|
|
|
@ -15,6 +15,8 @@
|
|||
GetterUtil.getString(portletPreferences.getValue("applicationName2-Title", StringPool.BLANK)));
|
||||
pageContext.setAttribute("applicationName3Title",
|
||||
GetterUtil.getString(portletPreferences.getValue("applicationName3-Title", StringPool.BLANK)));
|
||||
pageContext.setAttribute("applicationName4Title",
|
||||
GetterUtil.getString(portletPreferences.getValue("applicationName4-Title", StringPool.BLANK)));
|
||||
|
||||
long applicationName1DocumentId = GetterUtil
|
||||
.getLong(portletPreferences.getValue("applicationName1-DocumentId", StringPool.BLANK));
|
||||
|
@ -22,6 +24,8 @@
|
|||
.getLong(portletPreferences.getValue("applicationName2-DocumentId", StringPool.BLANK));
|
||||
long applicationName3DocumentId = GetterUtil
|
||||
.getLong(portletPreferences.getValue("applicationName3-DocumentId", StringPool.BLANK));
|
||||
long applicationName4DocumentId = GetterUtil
|
||||
.getLong(portletPreferences.getValue("applicationName4-DocumentId", StringPool.BLANK));
|
||||
|
||||
|
||||
String url1 = GetterUtil.getString(portletPreferences.getValue("application1-Url", StringPool.BLANK));
|
||||
|
@ -32,6 +36,9 @@
|
|||
|
||||
String url3 = GetterUtil.getString(portletPreferences.getValue("application3-Url", StringPool.BLANK));
|
||||
pageContext.setAttribute("application3Url", Utils.getVREFriendlyURL(currentUser, url3));
|
||||
|
||||
String url4 = GetterUtil.getString(portletPreferences.getValue("application4-Url", StringPool.BLANK));
|
||||
pageContext.setAttribute("application4Url", url4);
|
||||
|
||||
String content1 = "";
|
||||
if (applicationName1DocumentId > 0) {
|
||||
|
@ -59,6 +66,14 @@
|
|||
Node node = document.selectSingleNode("/root/static-content");
|
||||
content3 = node.getText();
|
||||
}
|
||||
String content4 = "";
|
||||
if (applicationName4DocumentId > 0) {
|
||||
JournalArticle article = JournalArticleLocalServiceUtil.getArticle(groupId,
|
||||
"" + applicationName4DocumentId);
|
||||
Document document = SAXReaderUtil.read(article.getContent());
|
||||
Node node = document.selectSingleNode("/root/static-content");
|
||||
content4 = node.getText();
|
||||
}
|
||||
%>
|
||||
<c:if test="${not empty applicationName1Title}">
|
||||
<div class="asset-abstract">
|
||||
|
@ -142,4 +157,32 @@
|
|||
<div class="asset-metadata"></div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
<c:if test="${not empty applicationName4Title}">
|
||||
<!-- THIRD -->
|
||||
<div class="asset-abstract">
|
||||
<h3 class="asset-title">
|
||||
<a href="${application4Url}"><img alt="" src="${icondocURL}">
|
||||
${applicationName4Title}</a>
|
||||
</h3>
|
||||
<div class="asset-content">
|
||||
<div class="asset-summary" style="margin-left: 25px;">
|
||||
<span id="asset-app-summarypre4"> <%
|
||||
if (content4.length() > 225)
|
||||
out.println(HtmlUtil.stripHtml(content4.substring(0, 222) + " ..."));
|
||||
%>
|
||||
<div>
|
||||
<a
|
||||
href="javascript:switchView('#asset-app-summarypre4', '#asset-app-summary-4');">Read
|
||||
More » </a>
|
||||
</div>
|
||||
</span>
|
||||
<div class="asset-more">
|
||||
<div id="asset-app-summary-4" class="asset-summary"
|
||||
style="display: none;"><%=content4%></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="asset-metadata"></div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
Loading…
Reference in New Issue