fixed date parsing problem for displaying events in calendar