Skip to content

Commit

Permalink
LPS-34583
Browse files Browse the repository at this point in the history
  • Loading branch information
brandizzi committed May 8, 2013
1 parent 00da444 commit fbcc043
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 9 deletions.
4 changes: 2 additions & 2 deletions portlets/calendar-portlet/docroot/edit_calendar.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<%
String tabs1 = ParamUtil.getString(request, "tabs1", "general");
String redirect = ParamUtil.getString(request, "redirect");
String backToURL = ParamUtil.getString(request, "backTo");
Calendar calendar = (Calendar)request.getAttribute(WebKeys.CALENDAR);
Expand All @@ -29,7 +29,7 @@ CalendarResource calendarResource = (CalendarResource)request.getAttribute(WebKe
<liferay-portlet:renderURL var="portletURL">
<portlet:param name="mvcPath" value="/edit_calendar.jsp" />
<portlet:param name="tabs1" value="<%= tabs1 %>" />
<portlet:param name="redirect" value="<%= redirect %>" />
<portlet:param name="backTo" value="<%= backToURL %>" />
<portlet:param name="calendarId" value="<%= (calendar != null) ? String.valueOf(calendar.getCalendarId()) : StringPool.BLANK %>" />
<portlet:param name="calendarResourceId" value="<%= (calendarResource != null) ? String.valueOf(calendarResource.getCalendarResourceId()) : StringPool.BLANK %>" />
</liferay-portlet:renderURL>
Expand Down
6 changes: 3 additions & 3 deletions portlets/calendar-portlet/docroot/edit_calendar_general.jspf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
--%>

<liferay-ui:header
backURL="<%= redirect %>"
backURL="<%= backToURL %>"
title='<%= (calendar != null) ? calendar.getName(locale) : LanguageUtil.format(pageContext, "add-new-calendar-for-x", calendarResource.getName(locale)) %>'
/>

Expand All @@ -24,7 +24,7 @@
<aui:form action="<%= updateCalendarURL %>" method="post" name="fm">
<aui:input name="mvcPath" type="hidden" value="/edit_calendar.jsp" />
<portlet:param name="tabs1" value="<%= tabs1 %>" />
<aui:input name="redirect" type="hidden" value="<%= redirect %>" />
<aui:input name="redirect" type="hidden" value="<%= (calendar != null) ? currentURL : backToURL %>" />
<aui:input name="calendarId" type="hidden" value="<%= (calendar != null) ? String.valueOf(calendar.getCalendarId()) : StringPool.BLANK %>" />
<aui:input name="calendarResourceId" type="hidden" value="<%= (calendarResource != null) ? String.valueOf(calendarResource.getCalendarResourceId()) : StringPool.BLANK %>" />

Expand Down Expand Up @@ -58,7 +58,7 @@
<aui:button-row>
<aui:button type="submit" />

<aui:button href="<%= redirect %>" type="cancel" />
<aui:button href="<%= backToURL %>" type="cancel" />
</aui:button-row>
</aui:fieldset>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ String defaultTemplateBody = NotificationUtil.getDefaultTemplate(notificationTyp
String notificationTemplateBody = BeanPropertiesUtil.getString(calendarNotificationTemplate, "body", defaultTemplateBody);
%>

<liferay-ui:header
backURL="<%= backToURL %>"
title='<%= calendar.getName(locale) %>'
/>

<liferay-ui:tabs
names="invite-email,reminder-email"
param="tabs2"
Expand All @@ -51,7 +56,7 @@ String notificationTemplateBody = BeanPropertiesUtil.getString(calendarNotificat
<aui:input name="calendarNotificationTemplateId" type="hidden" value="<%= calendarNotificationTemplateId %>" />
<aui:input name="tabs1" type="hidden" value="<%= tabs1 %>" />
<aui:input name="tabs2" type="hidden" value="<%= tabs2 %>" />
<aui:input name="redirect" type="hidden" value="<%= redirect %>" />
<aui:input name="redirect" type="hidden" value="<%= currentURL %>" />
<aui:input name="calendarId" type="hidden" value="<%= String.valueOf(calendar.getCalendarId()) %>" />
<aui:input name="calendarResourceId" type="hidden" value="<%= (calendarResource != null) ? String.valueOf(calendarResource.getCalendarResourceId()) : StringPool.BLANK %>" />
<aui:input name="notificationType" type="hidden" value="<%= notificationType.getValue() %>" />
Expand Down Expand Up @@ -131,7 +136,7 @@ String notificationTemplateBody = BeanPropertiesUtil.getString(calendarNotificat
<aui:button-row>
<aui:button type="submit" />

<aui:button href="<%= redirect %>" type="cancel" />
<aui:button href="<%= backToURL %>" type="cancel" />
</aui:button-row>
</aui:form>

Expand Down
4 changes: 2 additions & 2 deletions portlets/calendar-portlet/docroot/view_calendar_menus.jspf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
if (calendarResourceId) {
<portlet:renderURL var="editCalendarURL">
<portlet:param name="mvcPath" value="/edit_calendar.jsp" />
<portlet:param name="redirect" value="<%= currentURL %>" />
<portlet:param name="backTo" value="<%= currentURL %>" />
<portlet:param name="calendarResourceId" value="{calendarResourceId}" />
</portlet:renderURL>

Expand Down Expand Up @@ -104,7 +104,7 @@

<portlet:renderURL var="editCalendarURL">
<portlet:param name="mvcPath" value="/edit_calendar.jsp" />
<portlet:param name="redirect" value="<%= currentURL %>" />
<portlet:param name="backTo" value="<%= currentURL %>" />
<portlet:param name="calendarId" value="{calendarId}" />
</portlet:renderURL>

Expand Down

0 comments on commit fbcc043

Please sign in to comment.