Fixing bug in appointment report