added view for login and logout, modified controller