mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged HEAD-BUG-FIX (5.1/Cloud) to HEAD (5.1/Cloud)
92630: Merged 5.0.N (5.0.1) to HEAD-BUG-FIX (5.1/Cloud) 92573: Merged DEV to 5.0.N (5.0.1) 92438: SHA-15 : SPP: Recurrence: null value is displayed in details of event which occurs monthly/yearly on day/weekday/weekend day - Added display message day/weekday/weekend day for monthly/yearly Recurrence git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@94896 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -221,7 +221,7 @@ public class CalendarEntryGet extends AbstractCalendarWebScript
|
||||
{
|
||||
text.append("Occurs the ");
|
||||
text.append(weeks.get((Integer.parseInt(params.get("BYSETPOS")))) + " ");
|
||||
text.append(days.get(params.get("BYDAY")));
|
||||
buildParams(params, text, days);
|
||||
}
|
||||
text.append(" of every " + interval + " month(s) ");
|
||||
}
|
||||
@@ -236,7 +236,7 @@ public class CalendarEntryGet extends AbstractCalendarWebScript
|
||||
{
|
||||
text.append("Occurs the ");
|
||||
text.append(weeks.get((Integer.parseInt(params.get("BYSETPOS")))) + " ");
|
||||
text.append(days.get(params.get("BYDAY")) + " ");
|
||||
buildParams(params, text, days);
|
||||
text.append(" of " + params.get("BYMONTH") + " month ");
|
||||
}
|
||||
}
|
||||
@@ -278,6 +278,24 @@ public class CalendarEntryGet extends AbstractCalendarWebScript
|
||||
return text.toString();
|
||||
}
|
||||
|
||||
private static StringBuffer buildParams(Map<String, String> params, StringBuffer text, Map<String, String> days)
|
||||
{
|
||||
int day = params.get("BYDAY").split(",").length;
|
||||
if(day == 7){
|
||||
text.append(CalendarRecurrenceHelper.DAY);
|
||||
}
|
||||
if(day == 5){
|
||||
text.append(CalendarRecurrenceHelper.WEEKDAYS);
|
||||
}
|
||||
if(day == 2){
|
||||
text.append(CalendarRecurrenceHelper.WEEKENDS);
|
||||
}
|
||||
if(day != 7 && day != 5 && day != 2){
|
||||
text.append(days.get(params.get("BYDAY")));
|
||||
}
|
||||
return text;
|
||||
}
|
||||
|
||||
public void setPermissionService(PermissionService permissionService)
|
||||
{
|
||||
this.permissionService = permissionService;
|
||||
|
Reference in New Issue
Block a user