-last_year= SheetYear.find(:first, :order => "year DESC").year
-first_year= SheetYear.find(:first, :order => "year ASC").year
-y = last_year

#stat_years
	=link_to "fiches", admin_sheets_path()
	| Stats :
	
	-while y >= first_year 

		=link_to y, {:controller => :sheets, :action => :stats, :year => y}, :class => ("now" if y == params[:year].to_i)
		
		-y -= 1
	%br
	%br

%h1 Liste des fiches
=render :partial => "sheets_search", :locals => {:url => ""}
%br	
= link_to 'Ajouter une fiche', new_admin_sheet_path, :remote => true, :class => "btn"
%br
%br
#sheets
	=render :partial => "sheets"
=link_to "Exporter au format XLS", admin_sheets_path(:format => :xls), :class => "btn"
%br
%br

