using System; using System.Collections.Generic; using System.Globalization; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Data; namespace XGLFinishPro.Tools { public class BatchStatusValueConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { if (value.Equals("0")) { return "已报工"; } else { return "未报工"; } return "未派"; } public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { // 如果需要双向绑定,也需要实现 ConvertBack 方法 throw new NotImplementedException(); } } }