using System; using System.Collections.Generic; using System.Globalization; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Data; using System.Windows.Media; namespace BPASmartClient.CustomResource.Converters { public class RecipeStatusConvert : IValueConverter { public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { if (value != null) { if (value.ToString() == "等待制作") return Brushes.Yellow; else if (value.ToString() == "制作完成") return Brushes.Green; } return default; } public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { throw new NotImplementedException(); } } }