32 lines
		
	
	
		
			803 B
		
	
	
	
		
			C#
		
	
	
	
			
		
		
	
	
			32 lines
		
	
	
		
			803 B
		
	
	
	
		
			C#
		
	
	
	
using SqlSugar.Extensions;
 | 
						|
using System;
 | 
						|
using System.Collections.Generic;
 | 
						|
using System.Globalization;
 | 
						|
using System.Linq;
 | 
						|
using System.Text;
 | 
						|
using System.Threading.Tasks;
 | 
						|
using System.Windows;
 | 
						|
using System.Windows.Data;
 | 
						|
 | 
						|
namespace DM_Weight.Converter
 | 
						|
{
 | 
						|
    class BoxNumConverter : IValueConverter
 | 
						|
    {
 | 
						|
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
 | 
						|
        {
 | 
						|
            if(parameter==null)
 | 
						|
            {
 | 
						|
                return value.ObjToBool();
 | 
						|
            }
 | 
						|
            string str=value.ToString();
 | 
						|
            return !(str == parameter.ToString());
 | 
						|
        }
 | 
						|
 | 
						|
        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
 | 
						|
        {
 | 
						|
            throw new NotImplementedException();
 | 
						|
 | 
						|
        }
 | 
						|
    }
 | 
						|
}
 |