|  |  | @ -42,6 +42,7 @@ class ContestsController < ApplicationController | 
			
		
	
		
		
			
				
					
					|  |  |  |     @offset, @limit = api_offset_and_limit(:limit => 10) |  |  |  |     @offset, @limit = api_offset_and_limit(:limit => 10) | 
			
		
	
		
		
			
				
					
					|  |  |  |     #@contests = Contest.visible |  |  |  |     #@contests = Contest.visible | 
			
		
	
		
		
			
				
					
					|  |  |  |     #@contests = @contests.like(params[:name]) if params[:name].present? |  |  |  |     #@contests = @contests.like(params[:name]) if params[:name].present? | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |     @is_search = params[:name] ? true:false | 
			
		
	
		
		
			
				
					
					|  |  |  |     @contests =  Contest.visible.where("name like '%#{params[:name]}%'") |  |  |  |     @contests =  Contest.visible.where("name like '%#{params[:name]}%'") | 
			
		
	
		
		
			
				
					
					|  |  |  |     if params[:contests_search] |  |  |  |     if params[:contests_search] | 
			
		
	
		
		
			
				
					
					|  |  |  |       (redirect_to contests_url, :notice => l(:label_sumbit_empty);return) if params[:name].blank? |  |  |  |       (redirect_to contests_url, :notice => l(:label_sumbit_empty);return) if params[:name].blank? | 
			
		
	
	
		
		
			
				
					|  |  | 
 |