fix errors
refactor cache module
add login page