2024-10-17 15:54:06 +02:00
|
|
|
|
using BeWo.ViewModel;
|
2025-07-04 15:33:15 +02:00
|
|
|
|
using BeWo.ViewModel.Light;
|
2024-10-17 15:54:06 +02:00
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Globalization;
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
using System.Windows.Data;
|
|
|
|
|
|
|
|
|
|
|
|
namespace BeWo.Converter
|
|
|
|
|
|
{
|
|
|
|
|
|
public class TooltipTextConverter : IValueConverter
|
|
|
|
|
|
{
|
|
|
|
|
|
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
|
|
|
|
|
{
|
2024-11-06 18:57:57 +01:00
|
|
|
|
if (value is bool val_bool)
|
|
|
|
|
|
{
|
|
|
|
|
|
return val_bool ? null : parameter;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2025-07-04 15:33:15 +02:00
|
|
|
|
if (value is GkvAbrechnungLightVM gkv)
|
2024-10-18 16:09:17 +02:00
|
|
|
|
{
|
|
|
|
|
|
if (parameter is string s)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (s == "Send")
|
|
|
|
|
|
{
|
|
|
|
|
|
return gkv.SendTooltip;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2025-08-12 11:13:41 +02:00
|
|
|
|
if (value is GkvAbrechnungVM gkv2)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (parameter is string s)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (s == "Send")
|
|
|
|
|
|
{
|
|
|
|
|
|
return gkv2.SendTooltip;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2025-07-04 15:33:15 +02:00
|
|
|
|
if (value is InvoiceBaseLightVM invoice)
|
2024-10-17 15:54:06 +02:00
|
|
|
|
{
|
|
|
|
|
|
return invoice.IsGkvValidError;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2025-08-12 11:13:41 +02:00
|
|
|
|
if (value is InvoiceBaseVM invoice2)
|
|
|
|
|
|
{
|
|
|
|
|
|
return invoice2.IsGkvValidError;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2024-11-06 15:40:45 +01:00
|
|
|
|
if (value is MandatorVM mandator)
|
|
|
|
|
|
{
|
|
|
|
|
|
return mandator.CanEditIKLeistungserbringerTooltip;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2024-10-17 15:54:06 +02:00
|
|
|
|
return "xxx";
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
|
|
|
|
|
{
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|