<% course_file_num = visable_attachemnts_incourse(@course).count%> <% is_teacher = User.current.logged? && (User.current.admin? || User.current.allowed_to?(:as_teacher,@course)) %> <% if show_nav?(@course.homework_commons.count) %> <% end %> <% if show_nav?(@course.news.count) %> <% end %> <% if show_nav?(course_file_num) %> <% end %> <% if show_nav?(@course.boards.first ? @course.boards.first.topics.count : 0) %> <% end %> <% if show_nav?(course_feedback_count) %> <% end %> <% if show_nav?(course_poll_count) %> <% end %> <% if show_nav?(User.current.allowed_to?(:as_teacher,@course)? @course.exercises.count : @course.exercises.where("exercise_status=2").count) %> <% end %>