create controllers
fix "invalid date" issue