refactoring and view form to login done