mirror of
				https://github.com/Nioux/AideDeJeu.git
				synced 2025-10-30 23:16:09 +00:00 
			
		
		
		
	Filtres
This commit is contained in:
		
							parent
							
								
									f1ee0e3833
								
							
						
					
					
						commit
						8970b61b99
					
				
					 1 changed files with 12 additions and 0 deletions
				
			
		|  | @ -39,6 +39,18 @@ namespace AideDeJeu.ViewModels | |||
|             return string.IsNullOrEmpty(filterValue) || (itemValue != null && itemValue.ToLower().Contains(filterValue.ToLower())); | ||||
|         } | ||||
| 
 | ||||
|         public bool MatchEquals(string itemValue, string filterValue) | ||||
|         { | ||||
|             return string.IsNullOrEmpty(filterValue) || (itemValue != null && itemValue.ToLower().Equals(filterValue.ToLower())); | ||||
|         } | ||||
| 
 | ||||
|         public bool MatchRange(string itemValue, string filterMinValue, string filterMaxValue, IComparer<string> comparer) | ||||
|         { | ||||
|             return | ||||
|                 (string.IsNullOrEmpty(filterMinValue) || comparer.Compare(itemValue, filterMinValue) >= 0) && | ||||
|                 (string.IsNullOrEmpty(filterMaxValue) || comparer.Compare(itemValue, filterMaxValue) <= 0); | ||||
|         } | ||||
| 
 | ||||
|         protected void RegisterFilters() | ||||
|         { | ||||
|             foreach (var filter in Filters) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Yan Maniez
						Yan Maniez