refactor booking controller