added document controller
refactor documents