Files
BeWoPlaner/BeWo/View/Report/FLSReport/FLSOverviewGrid.xaml.cs

803 lines
36 KiB
C#

using BeWo.Core;
using BeWo.ServiceProxy;
using BS.Shared.DataContracts;
using BS.Shared.Translation;
using System;
using System.Collections.Generic;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Threading;
namespace BeWo.View.Report.FLSReport
{
public partial class FLSOverviewGrid : UserControl
{
public static readonly DependencyProperty DetailRowProperty = DependencyProperty.Register("DetailRow", typeof(FLSOverviewDetailRow), typeof(FLSOverviewGrid), new UIPropertyMetadata(new FLSOverviewDetailRow(DetailRowTypes.Header), RowChanged));
public FLSOverviewGrid()
{
this.InitializeComponent();
}
public FLSOverviewDetailRow DetailRow
{
get
{
return (FLSOverviewDetailRow)this.GetValue(DetailRowProperty);
}
set
{
this.SetValue(DetailRowProperty, value);
}
}
public void RefreshGrid(FLSOverviewDetailRow row)
{
Grid grid = this.detailRowGrid;
grid.RowDefinitions.Add(new RowDefinition());
// Employee Column
if (row.ShowServiceRecords && row.ShowOnlyTotalRows)
{
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(175));
}
else
{
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(120));
}
Label lbl;
lbl = new Label();
if (row.DetailRowType != DetailRowTypes.Detail)
{
lbl.FontWeight = FontWeights.Bold;
}
lbl.SetValue(Grid.ColumnProperty, 0);
if (row.ShowServiceRecords && row.ShowOnlyTotalRows && row.DetailRowType == DetailRowTypes.Header)
{
lbl.Content = "Datum";
}
else
{
lbl.Content = row.GroupName;
}
grid.Children.Add(lbl);
if (row.ShowServiceRecords)
{
// grid.Margin = new Thickness(0, 0, 8, 0);
if (row.ShowServiceRecords && row.ShowOnlyTotalRows)
{
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(150));
}
else
{
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(175));
}
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(175));
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(1, GridUnitType.Star));
if (row.DetailRowType == DetailRowTypes.Header)
{
lbl = new Label();
lbl.FontWeight = FontWeights.Bold;
lbl.SetValue(Grid.ColumnProperty, 1);
if (row.ShowOnlyTotalRows)
{
lbl.Content = row.GroupName;
}
else
{
lbl.Content = "Datum";
}
grid.Children.Add(lbl);
lbl = new Label();
lbl.FontWeight = FontWeights.Bold;
lbl.SetValue(Grid.ColumnProperty, 2);
lbl.Content = "Leistung";
grid.Children.Add(lbl);
lbl = new Label();
lbl.FontWeight = FontWeights.Bold;
lbl.SetValue(Grid.ColumnProperty, 3);
lbl.Content = "Dokumentation";
grid.Children.Add(lbl);
}
else if (row.DetailRowType == DetailRowTypes.Detail)
{
int rowIndex = 0;
foreach (var item in row.DateValues)
{
bool evenRow = false;
if (rowIndex > 0)
{
grid.RowDefinitions.Add(new RowDefinition());
}
Border border = new Border();
if (row.ShowOnlyTotalRows)
{
border.SetValue(Grid.ColumnProperty, 0);
border.SetValue(Grid.ColumnSpanProperty, 4);
}
else
{
border.SetValue(Grid.ColumnProperty, 1);
border.SetValue(Grid.ColumnSpanProperty, 3);
}
border.SetValue(Grid.RowProperty, rowIndex);
border.CornerRadius = new CornerRadius(3, 3, 0, 0);
border.BorderThickness = new Thickness(1, 1, 1, 0);
border.BorderBrush = Brushes.Gray;
border.Background = Brushes.Cornsilk;
if (rowIndex > 0)
{
border.Margin = new Thickness(0, 4, 0, 0);
// border.Height = 35;
}
grid.Children.Add(border);
lbl = new Label();
if (row.ShowOnlyTotalRows)
{
lbl.SetValue(Grid.ColumnProperty, 0);
}
else
{
lbl.SetValue(Grid.ColumnProperty, 1);
}
lbl.SetValue(Grid.ColumnSpanProperty, 2);
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.FontWeight = FontWeights.Bold;
lbl.Content = item.HeaderLongValue;
if (rowIndex > 0)
{
lbl.Margin = new Thickness(0, 4, 0, 0);
}
grid.Children.Add(lbl);
lbl = new Label();
if (row.ShowOnlyTotalRows)
{
lbl.SetValue(Grid.ColumnProperty, 1);
}
else
{
lbl.SetValue(Grid.ColumnProperty, 2);
}
lbl.SetValue(Grid.ColumnSpanProperty, 2);
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.FontWeight = FontWeights.Bold;
if (row.ShowEinheitInMinuten)
{
lbl.Content = "Summe: " + item.DateValueText + " Min.";
}
else
{
lbl.Content = "Summe: " + item.DateValueText + " Std.";
}
lbl.Margin = new Thickness(-100, 0, 0, 0);
if (rowIndex > 0)
{
lbl.Margin = new Thickness(-100, 4, 0, 0);
}
grid.Children.Add(lbl);
rowIndex++;
int count = 0;
if (item.ServiceRecordList != null)
{
foreach (var sr in item.ServiceRecordList)
{
var srei = new ServiceRecordEditInfo();
grid.RowDefinitions.Add(new RowDefinition());
border = new Border();
if (row.ShowOnlyTotalRows)
{
border.SetValue(Grid.ColumnProperty, 0);
border.SetValue(Grid.ColumnSpanProperty, 4);
}
else
{
border.SetValue(Grid.ColumnProperty, 1);
border.SetValue(Grid.ColumnSpanProperty, 3);
}
border.SetValue(Grid.RowProperty, rowIndex);
border.BorderThickness = new Thickness(1, 0, 1, 0);
border.BorderBrush = Brushes.Gray;
if (evenRow)
{
border.Background = Brushes.WhiteSmoke;
}
else
{
border.Background = Brushes.White;
}
evenRow = !evenRow;
if (count == item.ServiceRecordList.Count - 1)
{
border.CornerRadius = new CornerRadius(0, 0, 3, 3);
border.BorderThickness = new Thickness(1, 0, 1, 1);
}
grid.Children.Add(border);
if (row.ShowOnlyTotalRows)
{
lbl = new Label();
lbl.SetValue(Grid.ColumnProperty, 1);
lbl.SetValue(Grid.RowProperty, rowIndex);
if (sr.GroupOid != null && sr.GroupPersonCount != null)
{
lbl.Content = "Gruppe (" + sr.GroupPersonCount.Value + " Teilnehmer)";
}
else
{
lbl.Content = "Sonstiges".Equals(sr.GroupName) ? string.Empty : sr.GroupName;
}
grid.Children.Add(lbl);
}
lbl = new Label();
if (row.ShowOnlyTotalRows)
{
lbl.SetValue(Grid.ColumnProperty, 0);
}
else
{
lbl.SetValue(Grid.ColumnProperty, 1);
}
lbl.SetValue(Grid.RowProperty, rowIndex);
srei.DateLabel = lbl;
if (sr.Start != null && sr.Start.Value.Second == 0)
{
if (sr.GroupOid != null && sr.GroupRoundedDuration != null && sr.GroupPersonCount != null)
{
//lbl.Content = sr.Start.Value.ToShortDateString().Substring(0, 6) + " " + sr.Start.Value.ToShortTimeString() + "-" + sr.Start.Value.AddMinutes((double)sr.GroupRoundedDuration).ToShortTimeString() + " (" + (int)sr.RoundedDuration + " min.)";
var contentVorher = sr.Start.Value.ToShortDateString().Substring(0, 6) + " " + sr.Start.Value.ToShortTimeString() + "-" + sr.Start.Value.AddMinutes((double)sr.GroupRoundedDuration).ToShortTimeString() + " (" + (int)sr.RoundedDuration + " min.)";
//lbl.Content = string.Format("ok TEST DURATIONXXX 1");
lbl.Content = sr.DateTimeRange;
if (contentVorher != sr.DateTimeRange)
{
int test = 0;
}
grid.Children.Add(lbl);
lbl = new Label();
if (row.ShowOnlyTotalRows)
{
lbl.SetValue(Grid.ColumnProperty, 0);
}
else
{
lbl.SetValue(Grid.ColumnProperty, 1);
}
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.VerticalAlignment = VerticalAlignment.Top;
lbl.Margin = new Thickness(0, 20, 0, 0);
lbl.Content += sr.GroupPersonCount.Value + " Personen, " + sr.GroupEmployeeCount.Value + " Betreuuer";
srei.GroupLabel = lbl;
}
else
{
var contentVorher = sr.Start.Value.ToShortDateString().Substring(0, 6) + " " + sr.Start.Value.ToShortTimeString() + "-" + sr.Start.Value.AddMinutes((double)sr.RoundedDuration).ToShortTimeString() + " (" + (int)sr.RoundedDuration + " min.)";
//lbl.Content = string.Format("ok TEST DURATIONXXX 2");
lbl.Content = sr.DateTimeRange;
if (contentVorher != sr.DateTimeRange)
{
int test = 0;
}
}
}
else
{
if (sr.GroupOid != null && sr.GroupRoundedDuration != null && sr.GroupPersonCount != null)
{
var contentVorher = sr.Start.Value.ToShortDateString().Substring(0, 6) + " " + (int)sr.GroupRoundedDuration.Value + " min.";
lbl.Content = sr.DateTimeRange;
if (contentVorher != sr.DateTimeRange)
{
int test = 0;
}
grid.Children.Add(lbl);
lbl = new Label();
if (row.ShowOnlyTotalRows)
{
lbl.SetValue(Grid.ColumnProperty, 0);
}
else
{
lbl.SetValue(Grid.ColumnProperty, 1);
}
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.VerticalAlignment = VerticalAlignment.Top;
lbl.Margin = new Thickness(0, 20, 0, 0);
lbl.Content += sr.GroupPersonCount.Value + " Personen, " + sr.GroupEmployeeCount.Value + " Betreuuer";
srei.GroupLabel = lbl;
}
else
{
var contentVorher = sr.Start.Value.ToShortDateString().Substring(0, 6) + " " + (int)sr.RoundedDuration + " min.";
//lbl.Content = string.Format("ok TEST DURATIONXXX 3");
lbl.Content = sr.DateTimeRange;
if (contentVorher != sr.DateTimeRange)
{
int test = 0;
}
}
}
grid.Children.Add(lbl);
TextBlock block = new TextBlock();
block.TextWrapping = TextWrapping.Wrap;
block.HorizontalAlignment = HorizontalAlignment.Left;
block.SetValue(Grid.ColumnProperty, 2);
block.SetValue(Grid.RowProperty, rowIndex);
if (sr.ServiceDescription != null)
{
block.Text = sr.ServiceDescription.Name;
}
// block.MaxWidth = 500;
block.Margin = new Thickness(0, 5, 5, 3);
srei.ServiceDescriptionTextBlock = block;
grid.Children.Add(block);
block = new TextBlock();
block.TextWrapping = TextWrapping.Wrap;
block.HorizontalAlignment = HorizontalAlignment.Left;
block.SetValue(Grid.ColumnProperty, 3);
block.SetValue(Grid.RowProperty, rowIndex);
block.Text = sr.Notice;
block.MaxWidth = 500;
block.Margin = new Thickness(5, 5, 5, 3);
srei.NoticeTextBlock = block;
grid.Children.Add(block);
if (!row.ShowOnlyDeleted)
{
srei.ServiceRecordOid = sr.ServiceRecordOid.Value;
srei.OldDateString = srei.DateLabel.Content != null ? srei.DateLabel.Content.ToString() : "";
srei.SupportConcept2CostbearerOid = sr.CostBearer2SupportConceptOid ?? 0;
srei.EmployeeOid = sr.EmployeeOid ?? 0;
var img = new Image();
img.SetValue(Grid.ColumnProperty, 3);
img.SetValue(Grid.RowProperty, rowIndex);
img.Width = 16;
img.Height = 16;
img.HorizontalAlignment = HorizontalAlignment.Right;
img.VerticalAlignment = VerticalAlignment.Top;
img.Margin = new Thickness(3);
img.Cursor = Cursors.Hand;
img.Source = new BitmapImage(new Uri(@"..\..\..\Ressources\Icons\edit.png", UriKind.Relative));
img.Tag = srei;
img.MouseUp += Img_MouseUp;
grid.Children.Add(img);
}
rowIndex++;
count++;
}
}
if (count == 0)
{
border.CornerRadius = new CornerRadius(3, 3, 3, 3);
border.BorderThickness = new Thickness(1, 1, 1, 1);
}
}
}
else if (row.DetailRowType == DetailRowTypes.Total)
{
lbl = new Label();
lbl.SetValue(Grid.ColumnProperty, 1);
lbl.SetValue(Grid.ColumnSpanProperty, 2);
// lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.FontWeight = FontWeights.Bold;
if (row.ShowEinheitInMinuten)
{
lbl.Content = row.RowTotalFLS + " Min.";
}
else
{
lbl.Content = row.RowTotalFLS + " Std.";
}
grid.Children.Add(lbl);
}
}
else
{
if (row.DateValues != null)
{
int idx = 1;
foreach (FLSOverviewDateValue dv in row.DateValues)
{
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(65));
Label lblDate = new Label();
if (row.DetailRowType != DetailRowTypes.Detail)
{
lblDate.FontWeight = FontWeights.Bold;
lblDate.Content = dv.DateValueText;
}
else
{
if (dv.DateValue != 0)
{
lblDate.Content = dv.DateValueText;
}
}
lblDate.SetValue(Grid.ColumnProperty, idx++);
lblDate.HorizontalAlignment = HorizontalAlignment.Right;
lblDate.ToolTip = this.CreateToolTip(dv);
ToolTipService.SetShowDuration(lblDate, 1000000);
grid.Children.Add(lblDate);
}
}
// Total Column
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(70));
lbl = new Label();
if (row.DetailRowType != DetailRowTypes.Detail)
{
lbl.FontWeight = FontWeights.Bold;
}
lbl.SetValue(Grid.ColumnProperty, grid.ColumnDefinitions.Count - 1);
lbl.Content = row.RowTotalFLS;
lbl.HorizontalAlignment = HorizontalAlignment.Right;
grid.Children.Add(lbl);
}
if (row.ShowChart && (row.DetailRowType == DetailRowTypes.Detail || row.DetailRowType == DetailRowTypes.Total))
{
FLSOverviewChart chart = this.CreateChart(row);
RowDefinition rowDef = new RowDefinition();
rowDef.Height = new GridLength(200, GridUnitType.Pixel);
grid.RowDefinitions.Add(rowDef);
chart.SetValue(Grid.RowProperty, grid.RowDefinitions.Count - 1);
chart.SetValue(Grid.ColumnProperty, 1);
if (row.ShowServiceRecords)
{
double width = 0;
if (row.DateValues != null)
{
width = row.DateValues.Count * 50;
}
if (width < 600)
{
width = 600;
}
chart.Width = width;
// chart.HorizontalAlignment = HorizontalAlignment.Stretch;
chart.HorizontalAlignment = HorizontalAlignment.Left;
chart.SetValue(Grid.ColumnSpanProperty, grid.ColumnDefinitions.Count);
}
else
{
chart.SetValue(Grid.ColumnSpanProperty, grid.ColumnDefinitions.Count - 2);
chart.Margin = new Thickness(10, 0, 0, 0);
}
grid.Children.Add(chart);
}
}
private void Img_MouseUp(object sender, MouseButtonEventArgs e)
{
var img = sender as Image;
if (img?.Tag is ServiceRecordEditInfo)
{
OpenServiceRecordEditView(img.Tag as ServiceRecordEditInfo);
}
}
private ServiceRecordEditInfo lastServiceRecordEditInfo = null;
public void OpenServiceRecordEditView(ServiceRecordEditInfo srei)
{
lastServiceRecordEditInfo = srei;
var dc = new ServiceRecordDC();
dc.ServiceRecordOid = srei.ServiceRecordOid;
BeWoUtils.EditServiceRecord(dc, this, ServiceRecordSaved);
}
private void ServiceRecordSaved(List<ServiceRecordDC> records)
{
Dispatcher.BeginInvoke(DispatcherPriority.Normal, (Action)(() =>
{
if (lastServiceRecordEditInfo != null)
{
var record = ServiceFacade.DoOperationsServiceSync(s => s.GetServiceRecordById(lastServiceRecordEditInfo.ServiceRecordOid));
String date = String.Format("{0:dd.MM.}", record.Start);
if (record.Start.Value.Second == 0)
{
if (record.GroupOid.HasValue && record.GroupRoundedDuration.HasValue)
{
date += String.Format(" {0:HH:mm}-{1:HH:mm} ({2:0} min.)", record.Start, record.End, record.GroupRoundedDuration);
}
else
{
date += String.Format(" {0:HH:mm}-{1:HH:mm} ({2:0} min.)", record.Start, record.End, record.RoundedDuration);
}
}
else
{
date += String.Format(" {0:0} min.", record.RoundedDuration);
}
String group = "";
if (record.GroupOid.HasValue && record.GroupPersonCount.HasValue && record.GroupEmployeeCount.HasValue)
{
group = record.GroupPersonCount.Value + " Personen, " + record.GroupEmployeeCount.Value + " Betreuuer";
}
bool modified = false;
if (!date.Equals(lastServiceRecordEditInfo.OldDateString))
{
modified = true;
}
if (lastServiceRecordEditInfo.SupportConcept2CostbearerOid != (record.CostBearer2SupportConceptOid ?? 0))
{
modified = true;
}
if (lastServiceRecordEditInfo.EmployeeOid != (record.Employee != null ? record.Employee.EmployeeOid : 0))
{
modified = true;
}
if (record.ServiceDescription.Name != lastServiceRecordEditInfo.ServiceDescriptionTextBlock.Text)
{
modified = true;
}
if (lastServiceRecordEditInfo.GroupLabel != null && !group.Equals(lastServiceRecordEditInfo.GroupLabel.Content))
{
modified = true;
}
if (modified)
{
String tt = Translator.Translate("Möglicherweise wurden durch die Änderungen Summen verändert oder der Eintrag wurde in der Ansicht verschoben. Bitte aktualisieren Sie die Auswertung.");
lastServiceRecordEditInfo.DateLabel.Foreground = Brushes.Red;
lastServiceRecordEditInfo.DateLabel.ToolTip = tt;
if (lastServiceRecordEditInfo.GroupLabel != null)
{
lastServiceRecordEditInfo.GroupLabel.Foreground = Brushes.Red;
lastServiceRecordEditInfo.GroupLabel.ToolTip = tt;
}
lastServiceRecordEditInfo.NoticeTextBlock.Foreground = Brushes.Red;
lastServiceRecordEditInfo.NoticeTextBlock.ToolTip = tt;
lastServiceRecordEditInfo.ServiceDescriptionTextBlock.Foreground = Brushes.Red;
lastServiceRecordEditInfo.ServiceDescriptionTextBlock.ToolTip = tt;
}
lastServiceRecordEditInfo.DateLabel.Content = date;
lastServiceRecordEditInfo.NoticeTextBlock.Text = record.Notice;
lastServiceRecordEditInfo.ServiceDescriptionTextBlock.Text = record.ServiceDescription.Name;
}
}
));
}
private static void RowChanged(DependencyObject obj, DependencyPropertyChangedEventArgs e)
{
FLSOverviewGrid item = (FLSOverviewGrid)obj;
FLSOverviewDetailRow row = (FLSOverviewDetailRow)e.NewValue;
if (row != null)
{
item.RefreshGrid(row);
}
}
private FLSOverviewChart CreateChart(FLSOverviewDetailRow row)
{
FLSOverviewChart chart = new FLSOverviewChart();
chart.InitChart(row);
return chart;
}
private ColumnDefinition CreateColumnDefinition(int p)
{
ColumnDefinition def = new ColumnDefinition();
def.Width = new GridLength(p);
return def;
}
private ColumnDefinition CreateColumnDefinition(double value, GridUnitType type)
{
ColumnDefinition def = new ColumnDefinition();
def.Width = new GridLength(value, type);
return def;
}
private object CreateToolTip(FLSOverviewDateValue dv)
{
if (dv.ServiceRecordList != null && dv.ServiceRecordList.Count > 0)
{
Grid grid = new Grid();
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(40));
grid.ColumnDefinitions.Add(this.CreateColumnDefinition(130));
ColumnDefinition def = this.CreateColumnDefinition(1, GridUnitType.Auto);
// def.MaxWidth = 330;
grid.ColumnDefinitions.Add(def);
int rowIndex = 0;
foreach (var item in dv.ServiceRecordList)
{
grid.RowDefinitions.Add(new RowDefinition());
Label lbl = new Label();
lbl.SetValue(Grid.ColumnProperty, 0);
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.Content = item.Start.Value.ToShortDateString().Substring(0, 6);
grid.Children.Add(lbl);
lbl = new Label();
lbl.SetValue(Grid.ColumnProperty, 1);
lbl.SetValue(Grid.RowProperty, rowIndex);
if (item.Start != null && item.Start.Value.Second == 0)
{
if (item.GroupOid != null && item.GroupRoundedDuration != null && item.GroupPersonCount != null)
{
var contentVorher = item.Start.Value.ToShortTimeString() + "-" + item.Start.Value.AddMinutes((double)item.GroupRoundedDuration).ToShortTimeString() + " (" + (int)item.RoundedDuration + " min.)";
//lbl.Content = string.Format("ok TEST DURATIONXXX 4");
lbl.Content = item.TimeRange;
if (contentVorher != item.TimeRange)
{
int test = 0;
}
grid.Children.Add(lbl);
lbl = new Label();
lbl.SetValue(Grid.ColumnProperty, 0);
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.SetValue(Grid.ColumnSpanProperty, 2);
lbl.VerticalAlignment = VerticalAlignment.Top;
lbl.Margin = new Thickness(0, 20, 0, 0);
lbl.Content += item.GroupPersonCount.Value + " Personen, " + item.GroupEmployeeCount.Value + " Betreuuer";
}
else
{
var contentVorher = item.Start.Value.ToShortTimeString() + "-" + item.Start.Value.AddMinutes((double)item.RoundedDuration).ToShortTimeString() + " (" + (int)item.RoundedDuration + " min.)";
lbl.Content = item.TimeRange;
if (contentVorher != item.TimeRange)
{
int test = 0;
}
//lbl.Content = string.Format("OK TEST DURATIONXXX 5");
}
}
else
{
if (item.GroupOid != null && item.GroupRoundedDuration != null && item.GroupPersonCount != null)
{
lbl.Content = item.TimeRange;
grid.Children.Add(lbl);
lbl = new Label();
lbl.SetValue(Grid.ColumnProperty, 0);
lbl.SetValue(Grid.RowProperty, rowIndex);
lbl.SetValue(Grid.ColumnSpanProperty, 2);
lbl.VerticalAlignment = VerticalAlignment.Top;
lbl.Margin = new Thickness(0, 20, 0, 0);
lbl.Content += item.GroupPersonCount.Value + " Personen, " + item.GroupEmployeeCount.Value + " Betreuuer";
}
else
{
var contentVorher = (int)item.RoundedDuration + " min.";
//lbl.Content = item.TimeRange;
lbl.Content = contentVorher;
//if (contentVorher != item.TimeRange)
//{
// int test = 0;
//}
//lbl.Content = string.Format("TEST DURATIONXXX 6");
}
}
grid.Children.Add(lbl);
TextBlock block = new TextBlock();
block.TextWrapping = TextWrapping.Wrap;
block.MaxWidth = 400;
block.SetValue(Grid.ColumnProperty, 2);
block.SetValue(Grid.RowProperty, rowIndex);
block.Text = item.Notice;
block.Margin = new Thickness(0, 5, 3, 0);
grid.Children.Add(block);
rowIndex++;
}
return grid;
}
return null;
}
}
public class ServiceRecordEditInfo
{
public long ServiceRecordOid { get; set; }
public long? SupportConcept2CostbearerOid { get; set; }
public long? EmployeeOid { get; set; }
public String OldDateString { get; set; }
public Label DateLabel { get; set; }
public Label GroupLabel { get; set; }
public TextBlock ServiceDescriptionTextBlock { get; set; }
public TextBlock NoticeTextBlock { get; set; }
}
}