Added request to generateToken and login dialog

- REST API generateToken ajax request
- Dialog for user/pass and error message
- If successful, add token to local storage