Add view count logic to other views (history etc) and move to view decorator.