working on calendar and logic