added login view controller and proper behaviors