Hello,
I'm using SmartGWT 4.1
I've found a problem with operating events on a calendar with polish locale.
1. Events cannot be added by dragging threw hours - after setting a title event does not show up on calendar.
2. After moving event always jumps to 01:00am
3. Resizing not working or jumps to 01:00am depends on setting hour.
Simple test case from showcase:
Compile with and without:
By the way why there isn't a simple way (or I could not find it) to intercept creation of events on day/week view like you can o month view?
I've used a horrible workaround sometime ago, but after upgrading to SmartGWT 4.1 it stopped working and need to find other way.
Best regards
Mariusz Goch
[Update] Bug still exists in nightly SmartGWT 4.1p 2013-03-25
I'm using SmartGWT 4.1
I've found a problem with operating events on a calendar with polish locale.
1. Events cannot be added by dragging threw hours - after setting a title event does not show up on calendar.
2. After moving event always jumps to 01:00am
3. Resizing not working or jumps to 01:00am depends on setting hour.
Simple test case from showcase:
Code:
public void testCalendar() { DataSource eventDS = new DataSource(); DataSourceSequenceField eventIdField = new DataSourceSequenceField("eventId"); eventIdField.setPrimaryKey(true); DataSourceTextField nameField = new DataSourceTextField("name"); DataSourceTextField descField = new DataSourceTextField("description"); DataSourceDateTimeField startDateField = new DataSourceDateTimeField("startDate"); DataSourceDateTimeField endDateField = new DataSourceDateTimeField("endDate"); eventDS.setFields(eventIdField, nameField, descField, startDateField, endDateField); eventDS.setClientOnly(true); eventDS.setTestData(getCalendarRecords()); Calendar calendar = new Calendar(); calendar.setWidth100(); calendar.setHeight100(); calendar.setDataSource(eventDS); calendar.setAutoFetchData(true); this.addChild(calendar); } private static CalendarEvent[] records; private static Date today = new Date(); private static int year = today.getYear(); private static int month = today.getMonth(); private static int start = today.getDate() - today.getDay(); public static CalendarEvent[] getCalendarRecords() { return new CalendarEvent[]{ new CalendarEvent(1, "Meeting", "Shareholders meeting: monthly forecast report", new Date(year, month, start + 2, 9, 0, 0), new Date(year, month, start + 2, 14, 0, 0)), new CalendarEvent(2, "Realtor", "Breakfast with realtor to discuss moving plans", new Date(year, month, start + 3, 8, 0, 0), new Date(year, month, start + 3, 10, 0, 0)), new CalendarEvent(3, "Soccer", "Little league soccer finals", new Date(year, month, start + 4, 13, 0, 0), new Date(year, month, start + 4, 16, 0, 0)), new CalendarEvent(4, "Sleep", "Catch up on sleep", new Date(year, month, start + 4, 5, 0, 0), new Date(year, month, start + 4, 9, 0, 0)), new CalendarEvent(5, "Inspection", "Home inspector coming", new Date(year, month, start + 4, 10, 0, 0), new Date(year, month, start + 4, 12, 0, 0), false, "testStyle"), new CalendarEvent(6, "Airport run", "Pick James up from the airport", new Date(year, month, start + 4, 1, 0, 0), new Date(year, month, start + 4, 3, 0, 0)), new CalendarEvent(7, "Dinner Party", "Prepare elaborate meal for friends", new Date(year, month, start + 4, 17, 0, 0), new Date(year, month, start + 4, 20, 0, 0)), new CalendarEvent(8, "Poker", "Poker at Steve's house", new Date(year, month, start + 4, 21, 0, 0), new Date(year, month, start + 4, 23, 0, 0)), new CalendarEvent(9, "Meeting", "Board of directors meeting: discussion of next months strategy", new Date(year, month, start + 5, 11, 0, 0), new Date(year, month, start + 5, 15, 0, 0)) }; }
Code:
<extend-property name="locale" values="pl" />
I've used a horrible workaround sometime ago, but after upgrading to SmartGWT 4.1 it stopped working and need to find other way.
Best regards
Mariusz Goch
[Update] Bug still exists in nightly SmartGWT 4.1p 2013-03-25
Comment