ErrorCodeLevelConverter.cs
919 Bytes
using HHECS.Infrastructure.Enums;
using HHECS.Infrastructure.CommonHelper;
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;
using HHECS.Application.Error;
namespace HHECS.WinCommon.ValueConverter
{
public class ErrorCodeLevelConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is int)
{
return typeof(ErrorCodeLevel).GetDescriptionString((int)value);
}
else
{
return "未识别的标志";
}
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}