[pal-cvs 3920] [1655] set holiday color.

svnno****@sourc***** svnno****@sourc*****
2009年 1月 4日 (日) 08:08:59 JST


Revision: 1655
          http://svn.sourceforge.jp/view?root=pal&view=rev&rev=1655
Author:   shinsuke
Date:     2009-01-04 08:08:58 +0900 (Sun, 04 Jan 2009)

Log Message:
-----------
set holiday color.

Modified Paths:
--------------
    scheduler/trunk/src/main/java/jp/sf/pal/scheduler/SchedulerConstants.java
    scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/ConfigAction.java
    scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/facility/CalendarAction.java
    scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/schedule/CalendarAction.java
    scheduler/trunk/src/main/java/jp/sf/pal/scheduler/form/ConfigForm.java
    scheduler/trunk/src/main/java/jp/sf/pal/scheduler/util/SchedulerUtil.java
    scheduler/trunk/src/main/resources/application.properties
    scheduler/trunk/src/main/resources/application_ja.properties
    scheduler/trunk/src/main/webapp/WEB-INF/portlet.xml
    scheduler/trunk/src/main/webapp/WEB-INF/view/config/index.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityday.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilitymonth.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityweek.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/groupweek.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/groupweek.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalday.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalmonth.jsp
    scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalweek.jsp

Added Paths:
-----------
    scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig.properties
    scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_en.properties
    scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_ja.properties


-------------- next part --------------
Modified: scheduler/trunk/src/main/java/jp/sf/pal/scheduler/SchedulerConstants.java
===================================================================
--- scheduler/trunk/src/main/java/jp/sf/pal/scheduler/SchedulerConstants.java	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/java/jp/sf/pal/scheduler/SchedulerConstants.java	2009-01-03 23:08:58 UTC (rev 1655)
@@ -2,14 +2,19 @@
 
 public class SchedulerConstants {
 
-    public static final String ROLE_AVAILABLE = "features.role";
-
-    public static final String GROUP_AVAILABLE = "features.group";
-
     public static final String ONETIME_SCHEDULE = "ONETIME";
 
     public static final String ROLE_PREFIX = "role::";
 
     public static final String GROUP_PREFIX = "group::";
 
+    public static final String SCHEDULER_HOLIDAYS = "scheduler.holidays";
+
+    public static final String HOLIDAY_COLOR = "#FFCCCC";
+
+    public static final String SUNDAY_COLOR = "#FFCCCC";
+
+    public static final String SATURDAY_COLOR = "#CCFFFF";
+
+    public static final String TODAY_COLOR = "#CCFFCC";
 }

Modified: scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/ConfigAction.java
===================================================================
--- scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/ConfigAction.java	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/ConfigAction.java	2009-01-03 23:08:58 UTC (rev 1655)
@@ -1,6 +1,8 @@
 package jp.sf.pal.scheduler.action;
 
 import java.io.Serializable;
+import java.util.HashSet;
+import java.util.Set;
 
 import javax.servlet.http.HttpServletRequest;
 
@@ -8,8 +10,10 @@
 import jp.sf.pal.scheduler.common.util.ConfigUtil;
 import jp.sf.pal.scheduler.common.util.SAStrutsUtil;
 import jp.sf.pal.scheduler.form.ConfigForm;
+import jp.sf.pal.scheduler.util.SchedulerUtil;
 
 import org.apache.commons.configuration.ConfigurationException;
+import org.apache.commons.lang.StringUtils;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.seasar.struts.annotation.ActionForm;
@@ -28,10 +32,8 @@
     private transient HttpServletRequest request;
 
     protected String displayIndex() {
-        configForm.roleAvailable = ConfigUtil.getString(
-                SchedulerConstants.ROLE_AVAILABLE, "true");
-        configForm.groupAvailable = ConfigUtil.getString(
-                SchedulerConstants.GROUP_AVAILABLE, "true");
+        configForm.holidays = ConfigUtil.getString(
+                SchedulerConstants.SCHEDULER_HOLIDAYS, "");
         return "index.jsp";
     }
 
@@ -44,10 +46,22 @@
     @Execute(validator = false, input = "index.jsp")
     public String update() {
         ConfigUtil.init(request);
-        ConfigUtil.setProperty(SchedulerConstants.ROLE_AVAILABLE,
-                configForm.roleAvailable);
-        ConfigUtil.setProperty(SchedulerConstants.GROUP_AVAILABLE,
-                configForm.groupAvailable);
+        ConfigUtil.setProperty(SchedulerConstants.SCHEDULER_HOLIDAYS,
+                configForm.holidays);
+
+        if (configForm.holidays == null) {
+            configForm.holidays = "";
+        }
+
+        Set<String> holidaySet = new HashSet<String>();
+        String[] holidays = configForm.holidays.split("\n");
+        for (int i = 0; i < holidays.length; i++) {
+            if (!StringUtils.isEmpty(holidays[i])) {
+                holidaySet.add(holidays[i].trim());
+            }
+        }
+        SchedulerUtil.setHolidaySet(holidaySet);
+
         try {
             ConfigUtil.save();
             SAStrutsUtil.addMessage(request, "success.update_config");

Modified: scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/facility/CalendarAction.java
===================================================================
--- scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/facility/CalendarAction.java	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/facility/CalendarAction.java	2009-01-03 23:08:58 UTC (rev 1655)
@@ -10,6 +10,7 @@
 
 import javax.servlet.http.HttpServletRequest;
 
+import jp.sf.pal.scheduler.SchedulerConstants;
 import jp.sf.pal.scheduler.common.util.CalendarUtil;
 import jp.sf.pal.scheduler.common.util.ConfigUtil;
 import jp.sf.pal.scheduler.db.exentity.Facility;
@@ -45,6 +46,8 @@
 
     public int maxCols;
 
+    public String dayColor;
+
     public Facility facility;
 
     @ActionForm
@@ -124,6 +127,31 @@
             }
         }
 
+        // day color
+        StringBuilder sb = new StringBuilder();
+        sb.append(tYear).append("-");
+        if (tMonth < 10) {
+            sb.append("0").append(tMonth);
+        } else {
+            sb.append(tMonth);
+        }
+        sb.append("-");
+        if (tDate < 10) {
+            sb.append("0").append(tDate);
+        } else {
+            sb.append(tDate);
+        }
+        if (tDay == 1) {
+            // sunday
+            dayColor = SchedulerConstants.SUNDAY_COLOR;
+        } else if (SchedulerUtil.getHolidaySet().contains(sb.toString())) {
+            // holiday
+            dayColor = SchedulerConstants.HOLIDAY_COLOR;
+        } else if (tDay == 7) {
+            // saturday
+            dayColor = SchedulerConstants.SATURDAY_COLOR;
+        }
+
         return "facilityday.jsp";
     }
 
@@ -144,13 +172,38 @@
             int year = CalendarUtil.getYear(cal);
             int month = CalendarUtil.getMonth(cal) + 1;
             int date = CalendarUtil.getDate(cal);
+            int dayOfWeek = CalendarUtil.getDay(cal);
 
-            Map<String, Object> map = new HashMap<String, Object>(5);
+            Map<String, Object> map = new HashMap<String, Object>(6);
             map.put("displayedDate", sdf.format(cal.getTime()));
-            map.put("dayOfWeek", String.valueOf(CalendarUtil.getDay(cal)));
+            map.put("dayOfWeek", String.valueOf(dayOfWeek));
             map.put("date", String.valueOf(date));
             map.put("month", String.valueOf(month));
             map.put("year", String.valueOf(year));
+            // day color
+            StringBuilder sb = new StringBuilder();
+            sb.append(year).append("-");
+            if (month < 10) {
+                sb.append("0").append(month);
+            } else {
+                sb.append(month);
+            }
+            sb.append("-");
+            if (date < 10) {
+                sb.append("0").append(date);
+            } else {
+                sb.append(date);
+            }
+            if (dayOfWeek == 1) {
+                // sunday
+                map.put("color", SchedulerConstants.SUNDAY_COLOR);
+            } else if (SchedulerUtil.getHolidaySet().contains(sb.toString())) {
+                // holiday
+                map.put("color", SchedulerConstants.HOLIDAY_COLOR);
+            } else if (dayOfWeek == 7) {
+                // saturday
+                map.put("color", SchedulerConstants.SATURDAY_COLOR);
+            }
             weekDayItems.add(map);
             cal = CalendarUtil.getNext(cal);
 
@@ -246,13 +299,38 @@
             int year = CalendarUtil.getYear(cal);
             int month = CalendarUtil.getMonth(cal) + 1;
             int date = CalendarUtil.getDate(cal);
+            int dayOfWeek = CalendarUtil.getDay(cal);
 
-            Map<String, Object> map = new HashMap<String, Object>(5);
+            Map<String, Object> map = new HashMap<String, Object>(6);
             map.put("displayedDate", sdf.format(cal.getTime()));
-            map.put("dayOfWeek", String.valueOf(CalendarUtil.getDay(cal)));
+            map.put("dayOfWeek", String.valueOf(dayOfWeek));
             map.put("date", String.valueOf(date));
             map.put("month", String.valueOf(month));
             map.put("year", String.valueOf(year));
+            // day color
+            StringBuilder sb = new StringBuilder();
+            sb.append(year).append("-");
+            if (month < 10) {
+                sb.append("0").append(month);
+            } else {
+                sb.append(month);
+            }
+            sb.append("-");
+            if (date < 10) {
+                sb.append("0").append(date);
+            } else {
+                sb.append(date);
+            }
+            if (dayOfWeek == 1) {
+                // sunday
+                map.put("color", SchedulerConstants.SUNDAY_COLOR);
+            } else if (SchedulerUtil.getHolidaySet().contains(sb.toString())) {
+                // holiday
+                map.put("color", SchedulerConstants.HOLIDAY_COLOR);
+            } else if (dayOfWeek == 7) {
+                // saturday
+                map.put("color", SchedulerConstants.SATURDAY_COLOR);
+            }
             weekDayItems.add(map);
             cal = CalendarUtil.getNext(cal);
 

Modified: scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/schedule/CalendarAction.java
===================================================================
--- scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/schedule/CalendarAction.java	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/java/jp/sf/pal/scheduler/action/user/schedule/CalendarAction.java	2009-01-03 23:08:58 UTC (rev 1655)
@@ -47,6 +47,8 @@
 
     public int maxCols;
 
+    public String dayColor;
+
     @ActionForm
     private CalendarForm calendarForm;
 
@@ -121,6 +123,31 @@
             }
         }
 
+        // day color
+        StringBuilder sb = new StringBuilder();
+        sb.append(tYear).append("-");
+        if (tMonth < 10) {
+            sb.append("0").append(tMonth);
+        } else {
+            sb.append(tMonth);
+        }
+        sb.append("-");
+        if (tDate < 10) {
+            sb.append("0").append(tDate);
+        } else {
+            sb.append(tDate);
+        }
+        if (tDay == 1) {
+            // sunday
+            dayColor = SchedulerConstants.SUNDAY_COLOR;
+        } else if (SchedulerUtil.getHolidaySet().contains(sb.toString())) {
+            // holiday
+            dayColor = SchedulerConstants.HOLIDAY_COLOR;
+        } else if (tDay == 7) {
+            // saturday
+            dayColor = SchedulerConstants.SATURDAY_COLOR;
+        }
+
         return "personalday.jsp";
     }
 
@@ -142,14 +169,40 @@
             int year = CalendarUtil.getYear(cal);
             int month = CalendarUtil.getMonth(cal) + 1;
             int date = CalendarUtil.getDate(cal);
+            int dayOfWeek = CalendarUtil.getDay(cal);
 
-            Map<String, Object> map = new HashMap<String, Object>(5);
+            Map<String, Object> map = new HashMap<String, Object>(6);
             map.put("displayedDate", sdf.format(cal.getTime()));
-            map.put("dayOfWeek", String.valueOf(CalendarUtil.getDay(cal)));
+            map.put("dayOfWeek", String.valueOf(dayOfWeek));
             map.put("date", String.valueOf(date));
             map.put("month", String.valueOf(month));
             map.put("year", String.valueOf(year));
+            // day color
+            StringBuilder sb = new StringBuilder();
+            sb.append(year).append("-");
+            if (month < 10) {
+                sb.append("0").append(month);
+            } else {
+                sb.append(month);
+            }
+            sb.append("-");
+            if (date < 10) {
+                sb.append("0").append(date);
+            } else {
+                sb.append(date);
+            }
+            if (dayOfWeek == 1) {
+                // sunday
+                map.put("color", SchedulerConstants.SUNDAY_COLOR);
+            } else if (SchedulerUtil.getHolidaySet().contains(sb.toString())) {
+                // holiday
+                map.put("color", SchedulerConstants.HOLIDAY_COLOR);
+            } else if (dayOfWeek == 7) {
+                // saturday
+                map.put("color", SchedulerConstants.SATURDAY_COLOR);
+            }
             weekDayItems.add(map);
+
             cal = CalendarUtil.getNext(cal);
 
             indexMap.put(year + "-" + month + "-" + date, i);
@@ -254,13 +307,38 @@
             int year = CalendarUtil.getYear(cal);
             int month = CalendarUtil.getMonth(cal) + 1;
             int date = CalendarUtil.getDate(cal);
+            int dayOfWeek = CalendarUtil.getDay(cal);
 
-            Map<String, Object> map = new HashMap<String, Object>(5);
+            Map<String, Object> map = new HashMap<String, Object>(6);
             map.put("displayedDate", sdf.format(cal.getTime()));
-            map.put("dayOfWeek", String.valueOf(CalendarUtil.getDay(cal)));
+            map.put("dayOfWeek", String.valueOf(dayOfWeek));
             map.put("date", String.valueOf(date));
             map.put("month", String.valueOf(month));
             map.put("year", String.valueOf(year));
+            // day color
+            StringBuilder sb = new StringBuilder();
+            sb.append(year).append("-");
+            if (month < 10) {
+                sb.append("0").append(month);
+            } else {
+                sb.append(month);
+            }
+            sb.append("-");
+            if (date < 10) {
+                sb.append("0").append(date);
+            } else {
+                sb.append(date);
+            }
+            if (dayOfWeek == 1) {
+                // sunday
+                map.put("color", SchedulerConstants.SUNDAY_COLOR);
+            } else if (SchedulerUtil.getHolidaySet().contains(sb.toString())) {
+                // holiday
+                map.put("color", SchedulerConstants.HOLIDAY_COLOR);
+            } else if (dayOfWeek == 7) {
+                // saturday
+                map.put("color", SchedulerConstants.SATURDAY_COLOR);
+            }
             weekDayItems.add(map);
             cal = CalendarUtil.getNext(cal);
 

Modified: scheduler/trunk/src/main/java/jp/sf/pal/scheduler/form/ConfigForm.java
===================================================================
--- scheduler/trunk/src/main/java/jp/sf/pal/scheduler/form/ConfigForm.java	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/java/jp/sf/pal/scheduler/form/ConfigForm.java	2009-01-03 23:08:58 UTC (rev 1655)
@@ -6,12 +6,9 @@
 
 public class ConfigForm implements Serializable {
 
-    private static final long serialVersionUID = -8652826957783721623L;
+    private static final long serialVersionUID = 5428451370958739560L;
 
     @Required(target = "update")
-    public String roleAvailable;
+    public String holidays;
 
-    @Required(target = "update")
-    public String groupAvailable;
-
 }

Modified: scheduler/trunk/src/main/java/jp/sf/pal/scheduler/util/SchedulerUtil.java
===================================================================
--- scheduler/trunk/src/main/java/jp/sf/pal/scheduler/util/SchedulerUtil.java	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/java/jp/sf/pal/scheduler/util/SchedulerUtil.java	2009-01-03 23:08:58 UTC (rev 1655)
@@ -5,20 +5,25 @@
 import java.util.Calendar;
 import java.util.Date;
 import java.util.HashMap;
+import java.util.HashSet;
 import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
+import java.util.Set;
 
 import jp.sf.pal.scheduler.SchedulerConstants;
 import jp.sf.pal.scheduler.common.util.CalendarUtil;
+import jp.sf.pal.scheduler.common.util.ConfigUtil;
 import jp.sf.pal.scheduler.common.util.DateUtil;
 import jp.sf.pal.scheduler.db.exentity.EventSchedule;
 import jp.sf.pal.scheduler.db.exentity.EventScheduleMapping;
 import jp.sf.pal.scheduler.db.exentity.FacilityScheduleMapping;
 
+import org.apache.commons.lang.StringUtils;
 import org.seasar.struts.exception.ActionMessagesException;
 
 public class SchedulerUtil {
+    private static Set<String> holidaySet;
 
     public static boolean compare(String yyyymmdd1, String HHmm1,
             String yyyymmdd2, String HHmm2) {
@@ -116,6 +121,7 @@
             calendarDayItems.add(createCalendarDayItem(cal, targetYear,
                     targetMonth, targetDate, true));
             cal = CalendarUtil.getNext(cal);
+
         }
 
         // create a next month
@@ -146,7 +152,7 @@
         int month = CalendarUtil.getMonth(cal) + 1;
         int dayOfMonth = CalendarUtil.getDate(cal);
         int dayOfWeek = CalendarUtil.getDay(cal);
-        Map<String, Object> map = new HashMap<String, Object>(6);
+        Map<String, Object> map = new HashMap<String, Object>(7);
         map.put("year", String.valueOf(year));
         map.put("month", String.valueOf(month));
         map.put("dayOfMonth", String.valueOf(dayOfMonth));
@@ -157,6 +163,31 @@
         } else {
             map.put("target", "false");
         }
+        // day color
+        StringBuilder sb = new StringBuilder();
+        sb.append(year);
+        sb.append("-");
+        if (month < 10) {
+            sb.append("0").append(month);
+        } else {
+            sb.append(month);
+        }
+        sb.append("-");
+        if (dayOfMonth < 10) {
+            sb.append("0").append(dayOfMonth);
+        } else {
+            sb.append(dayOfMonth);
+        }
+        if (dayOfWeek == 1) {
+            // sunday
+            map.put("color", SchedulerConstants.SUNDAY_COLOR);
+        } else if (getHolidaySet().contains(sb.toString())) {
+            // holiday
+            map.put("color", SchedulerConstants.HOLIDAY_COLOR);
+        } else if (dayOfWeek == 7) {
+            // saturday
+            map.put("color", SchedulerConstants.SATURDAY_COLOR);
+        }
         return map;
     }
 
@@ -971,4 +1002,29 @@
             }
         }
     }
+
+    public static void setHolidaySet(Set<String> holidaySet) {
+        if (SchedulerUtil.holidaySet != null) {
+            synchronized (SchedulerUtil.holidaySet) {
+                SchedulerUtil.holidaySet = holidaySet;
+            }
+        } else {
+            SchedulerUtil.holidaySet = holidaySet;
+        }
+    }
+
+    public static Set<String> getHolidaySet() {
+        if (holidaySet == null) {
+            Set<String> hSet = new HashSet<String>();
+            String[] holidays = ConfigUtil.getString(
+                    SchedulerConstants.SCHEDULER_HOLIDAYS, "").split("\n");
+            for (int i = 0; i < holidays.length; i++) {
+                if (!StringUtils.isEmpty(holidays[i])) {
+                    hSet.add(holidays[i].trim());
+                }
+            }
+            holidaySet = hSet;
+        }
+        return holidaySet;
+    }
 }

Modified: scheduler/trunk/src/main/resources/application.properties
===================================================================
--- scheduler/trunk/src/main/resources/application.properties	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/resources/application.properties	2009-01-03 23:08:58 UTC (rev 1655)
@@ -216,3 +216,6 @@
 labels.startTimeM=Start Time
 labels.type=Type
 labels.userGroup=User Group
+
+labels.holiday_list=Holiday List
+labels.holiday_format=ex. YYYY-MM-DD

Modified: scheduler/trunk/src/main/resources/application_ja.properties
===================================================================
--- scheduler/trunk/src/main/resources/application_ja.properties	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/resources/application_ja.properties	2009-01-03 23:08:58 UTC (rev 1655)
@@ -208,3 +208,6 @@
 labels.startTimeM=\u958b\u59cb\u6642\u523b
 labels.type=\u30bf\u30a4\u30d7
 labels.userGroup=\u30e6\u30fc\u30b6\u30fc\u30b0\u30eb\u30fc\u30d7
+
+labels.holiday_list=\u4f11\u65e5\u4e00\u89a7
+labels.holiday_format=\u4f8b: YYYY-MM-DD

Added: scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig.properties
===================================================================


Property changes on: scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig.properties
___________________________________________________________________
Name: svn:eol-style
   + native

Added: scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_en.properties
===================================================================
--- scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_en.properties	                        (rev 0)
+++ scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_en.properties	2009-01-03 23:08:58 UTC (rev 1655)
@@ -0,0 +1,5 @@
+# portlet info
+javax.portlet.title=Scheduler Config
+javax.portlet.short-title=Config
+javax.portlet.keywords=Schedule,Config,Groupware
+


Property changes on: scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_en.properties
___________________________________________________________________
Name: svn:eol-style
   + native

Added: scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_ja.properties
===================================================================
--- scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_ja.properties	                        (rev 0)
+++ scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_ja.properties	2009-01-03 23:08:58 UTC (rev 1655)
@@ -0,0 +1,5 @@
+# portlet info
+javax.portlet.title=\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u8a2d\u5b9a
+javax.portlet.short-title=\u8a2d\u5b9a
+javax.portlet.keywords=\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb,\u8a2d\u5b9a,\u30b0\u30eb\u30fc\u30d7\u30a6\u30a7\u30a2
+


Property changes on: scheduler/trunk/src/main/resources/jp/sf/pal/scheduler/resources/SchedulerConfig_ja.properties
___________________________________________________________________
Name: svn:eol-style
   + native

Modified: scheduler/trunk/src/main/webapp/WEB-INF/portlet.xml
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/portlet.xml	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/portlet.xml	2009-01-03 23:08:58 UTC (rev 1655)
@@ -1,10 +1,11 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd">
-<!-- 
   <portlet>
+    <description>Edit configurations.</description>
+    <description xml:lang="ja">設定を編集します。</description>
     <portlet-name>SchedulerConfig</portlet-name>
     <display-name>Scheduler: Scheduler Configuration</display-name>
-    <description>Edit configurations.</description>
+    <display-name xml:lang="ja">スケジュール: 設定</display-name>
     <portlet-class>org.seasar.struts.portlet.SAStrutsPortlet</portlet-class>
     <init-param>
       <name>viewPage</name>
@@ -17,13 +18,13 @@
     </supports>
     <supported-locale>en</supported-locale>
     <supported-locale>ja</supported-locale>
+    <resource-bundle>jp.sf.pal.scheduler.resources.SchedulerConfig</resource-bundle>
     <portlet-info>
-      <title>Scheduler Configuration</title>
+      <title>Scheduler Config</title>
       <short-title>Config</short-title>
-      <keywords>Scheduler,URL</keywords>
+      <keywords>Scheduler</keywords>
     </portlet-info>
   </portlet>
- -->
   <portlet>
     <description>Manage facilities.</description>
     <description xml:lang="ja">施設情報を管理します。</description>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/config/index.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/config/index.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/config/index.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -28,23 +28,11 @@
 	<caption><bean:message key="labels.config"/></caption>
 	<tbody>
 		<tr>
-			<th><bean:message key="labels.role"/></th>
-			<td>
-				<html:select property="roleAvailable">
-					<html:option value="true"><bean:message key="labels.enabled"/></html:option>
-					<html:option value="false"><bean:message key="labels.disabled"/></html:option>
-				</html:select>
+			<th><bean:message key="labels.holiday_list"/></th>
+			<td><html:textarea property="holidays" cols="10" rows="5"/>
+			<br/><bean:message key="labels.holiday_format"/>
 			</td>
 		</tr>
-		<tr>
-			<th><bean:message key="labels.group"/></th>
-			<td>
-				<html:select property="groupAvailable">
-					<html:option value="true"><bean:message key="labels.enabled"/></html:option>
-					<html:option value="false"><bean:message key="labels.disabled"/></html:option>
-				</html:select>
-			</td>
-		</tr>
 	</tbody>
 	<tfoot>
 		<tr>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityday.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityday.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityday.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,8 +65,8 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
-<s:link href="selectfacilityday/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
+<s:link href="selectfacilityday/${facilityId}/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
 </c:forEach>
@@ -81,7 +81,7 @@
 	<thead>
 		<tr>
 			<th style="width:50px;text-align: center;"><bean:message key="labels.time"/></th>
-			<th style="width:550px;text-align: center;" colspan="${maxCols}"><bean:message key="labels.events"/></th>
+			<th style="width:550px;text-align: center;background-color:${dayColor!=null?dayColor:'#f5f5f5'};" colspan="${maxCols}"><bean:message key="labels.events"/></th>
 		</tr>
 	</thead>
 	<tbody>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilitymonth.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilitymonth.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilitymonth.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,7 +65,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectfacilitymonth/${facilityId}/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -90,7 +90,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="vertical-align: top;height:100px;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="vertical-align: top;height:100px;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectfacilityday/${facilityId}/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link><br/>
 <ul style="margin:0;padding:0;">
 <c:forEach var="event" varStatus="s" items="${day.allDayEventItems}">

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityweek.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityweek.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/facilityweek.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,7 +65,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectfacilityweek/${facilityId}/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -82,7 +82,7 @@
 		<tr>
 			<th style="width:50px;text-align: center;"><bean:message key="labels.time"/></th>
 <c:forEach var="day" varStatus="s" items="${weekDayItems}">
-			<th style="width:70px;text-align: center;font-size:xx-small;">${day.displayedDate}</th>
+			<th style="width:70px;text-align: center;font-size:xx-small;background-color:${day.color != null ? day.color : '#f5f5f5'};">${day.displayedDate}</th>
 </c:forEach>
 		</tr>
 	</thead>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/groupweek.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/groupweek.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/facility/calendar/groupweek.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -61,7 +61,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectgroupweek/0/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -98,7 +98,7 @@
 		<tr>
 			<th style="width:50px;text-align: center;">&nbsp;</th>
 <c:forEach var="day" varStatus="s" items="${weekDayItems}">
-			<th style="width:70px;text-align: center;font-size:xx-small;">${day.displayedDate}</th>
+			<th style="width:70px;text-align: center;font-size:xx-small;background-color:${day.color != null ? day.color : '#f5f5f5'};">${day.displayedDate}</th>
 </c:forEach>
 		</tr>
 	</thead>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/groupweek.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/groupweek.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/groupweek.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,7 +65,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectgroupweek/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -102,7 +102,7 @@
 		<tr>
 			<th style="width:50px;text-align: center;">&nbsp;</th>
 <c:forEach var="day" varStatus="s" items="${weekDayItems}">
-			<th style="width:70px;text-align: center;font-size:xx-small;">${day.displayedDate}</th>
+			<th style="width:70px;text-align: center;font-size:xx-small;background-color:${day.color != null ? day.color : '#f5f5f5'};">${day.displayedDate}</th>
 </c:forEach>
 		</tr>
 	</thead>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalday.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalday.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalday.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,7 +65,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectpersonalday/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -80,7 +80,7 @@
 	<thead>
 		<tr>
 			<th style="width:50px;text-align: center;"><bean:message key="labels.time"/></th>
-			<th style="width:550px;text-align: center;" colspan="${maxCols}"><bean:message key="labels.events"/></th>
+			<th style="width:550px;text-align: center;background-color:${dayColor!=null?dayColor:'#f5f5f5'};" colspan="${maxCols}"><bean:message key="labels.events"/></th>
 		</tr>
 	</thead>
 	<tbody>

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalmonth.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalmonth.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalmonth.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,7 +65,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectpersonalmonth/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -89,7 +89,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="vertical-align: top;height:100px;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="vertical-align: top;height:100px;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectpersonalday/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link><br/>
 <ul style="margin:0;padding:0;">
 <c:forEach var="event" varStatus="s" items="${day.allDayEventItems}">

Modified: scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalweek.jsp
===================================================================
--- scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalweek.jsp	2008-12-31 22:27:20 UTC (rev 1654)
+++ scheduler/trunk/src/main/webapp/WEB-INF/view/user/schedule/calendar/personalweek.jsp	2009-01-03 23:08:58 UTC (rev 1655)
@@ -65,7 +65,7 @@
 	<tbody>
 		<tr>
 <c:forEach var="day" varStatus="s" items="${calendarDayItems}">
-			<td style="text-align: center;${day.target == 'true' ? 'background-color:#ffffa1;' : ''}">
+			<td style="text-align: center;background-color:${day.target == 'true' ? '#CCFFCC' : day.color != null ? day.color : '#ffffff'};">
 <s:link href="selectpersonalweek/${day.year}/${day.month}/${day.dayOfMonth}" style="text-decoration: none;"><span style="${day.thisMonth == 'true' ? '' : 'color:gray;'}">${day.dayOfMonth}</span></s:link>
 			</td>
 <c:if test="${day.dayOfWeek==7}"></tr><tr></c:if>
@@ -81,7 +81,7 @@
 		<tr>
 			<th style="width:50px;text-align: center;"><bean:message key="labels.time"/></th>
 <c:forEach var="day" varStatus="s" items="${weekDayItems}">
-			<th style="width:70px;text-align: center;font-size:xx-small;">${day.displayedDate}</th>
+			<th style="width:70px;text-align: center;font-size:xx-small;background-color:${day.color != null ? day.color : '#f5f5f5'};">${day.displayedDate}</th>
 </c:forEach>
 		</tr>
 	</thead>


pal-cvs メーリングリストの案内