<UserControl x:Class="MeterVision.Patch.UCPatchGrid"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:local="clr-namespace:MeterVision.Patch"
             mc:Ignorable="d" 
             Background="White"
             BorderThickness="0"
             Padding="5"
             BorderBrush="#E0E0E0"
             d:DesignHeight="800" d:DesignWidth="1000">
    <Grid>
        <DataGrid Name="dgPatchDetail" GridLinesVisibility="All" HorizontalGridLinesBrush="#D3D3D3" VerticalGridLinesBrush="#D3D3D3" RowHeight="100" BorderBrush="#D3D3D3"
                  HeadersVisibility="Column" SelectionMode="Single" SelectionUnit="FullRow" HorizontalScrollBarVisibility="Auto" CanUserResizeColumns="False"  
                  FrozenColumnCount="2"
                  SelectedItem="{Binding SelectedPatchDetailItem,Mode=TwoWay}"
                  AutoGenerateColumns="False" CanUserAddRows="False" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Background="White">
            <DataGrid.Resources>
                <Style TargetType="DataGridColumnHeader">
                    <Setter Property="Height" Value="40" />
                    <!--Setter Property="Background" Value="White" /-->
                    <Setter Property="Foreground" Value="Black" />
                    <Setter Property="FontSize" Value="13px" />
                    <Setter Property="FontWeight" Value="Bold" />
                    <Setter Property="BorderBrush" Value="#D3D3D3" />
                    <Setter Property="BorderThickness" Value="0,0,1,1" />
                    <Setter Property="HorizontalContentAlignment" Value="Center" />
                </Style>
                <!-- 自定义行的选中样式 -->
                <Style TargetType="DataGridRow">
                    <Style.Triggers>
                        <!-- 当行被选中时 -->
                        <DataTrigger Binding="{Binding IsSelected, RelativeSource={RelativeSource Self}}" Value="True">
                            <!-- 设置选中行的背景色 -->
                            <Setter Property="Background" Value="AliceBlue"/>
                            <!-- 设置选中行的前景色 -->
                            <!--
                            <Setter Property="Foreground" Value="Black"/>
                            -->
                            <!-- 设置选中行的边框 -->
                            <!--
                            <Setter Property="BorderBrush" Value="Red"/>
                            <Setter Property="BorderThickness" Value="0"/>
                            -->
                            <!-- 可以进一步增加效果，比如字体加粗 -->
                            <!--
                            <Setter Property="FontWeight" Value="Bold"/>-->
                        </DataTrigger>
                    </Style.Triggers>
                </Style>

                <!-- 自定义选中单元格的背景色 -->
                <Style TargetType="DataGridCell">
                    <Style.Triggers>
                        <DataTrigger Binding="{Binding IsSelected, RelativeSource={RelativeSource Self}}" Value="True">
                            <!-- 设置选中单元格的背景色 -->
                            <Setter Property="Background" Value="AliceBlue"/>
                            <Setter Property="BorderBrush" Value="Transparent" />
                            <!-- 设置选中单元格的前景色 -->
                            <!--<Setter Property="Foreground" Value="Black"/>-->
                        </DataTrigger>
                    </Style.Triggers>
                </Style>

            </DataGrid.Resources>

            <DataGrid.Columns>
                <!--使用自定义模板-->
                <DataGridTemplateColumn Header="序号" Width="50">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <TextBlock Text="{Binding Index}" FontSize="13px" Foreground="#000000" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="完成" Width="50">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <TextBlock FontSize="14px" FontWeight="Normal" HorizontalAlignment="Center" VerticalAlignment="Center">
                                <TextBlock.Style>
                                    <Style TargetType="TextBlock">
                                        <Style.Triggers>
                                            <!-- 当 FinishedFlag == 1 时，显示 "完成"，并设置为绿色 -->
                                            <DataTrigger Binding="{Binding RunFlag}" Value="1">
                                                <Setter Property="Text" Value="已测"/>
                                                <Setter Property="Foreground" Value="BlueViolet"/>
                                            </DataTrigger>

                                            <!-- 当 FinishedFlag == 0 时，显示空，并设置为透明 -->
                                            <DataTrigger Binding="{Binding RunFlag}" Value="0">
                                                <Setter Property="Text" Value=""/>
                                                <Setter Property="Foreground" Value="Transparent"/>
                                            </DataTrigger>
                                        </Style.Triggers>
                                    </Style>
                                </TextBlock.Style>
                            </TextBlock>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>


                <DataGridTemplateColumn Header="原始图片" Width="120">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <Image Source="{Binding SrcImage}" VerticalAlignment="Center" HorizontalAlignment="Center"  Margin="2,2,2,2"/>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="识别时间" Width="90">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <StackPanel Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Center">
                                <TextBlock Text="{Binding RunTime_date}" FontSize="13px" Foreground="#000000" HorizontalAlignment="Center" Margin="0 0 0 5"/>
                                <TextBlock Text="{Binding RunTIme_time}" FontSize="14px" Foreground="#000000" HorizontalAlignment="Center"/>
                            </StackPanel>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="正确" Width="45">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <TextBlock FontSize="16px" FontWeight="Normal" VerticalAlignment="Center" HorizontalAlignment="Center">
                                <TextBlock.Style>
                                    <Style TargetType="TextBlock">
                                        <Style.Triggers>
                                            <!-- 当 FinishedFlag == 1 时，显示 "完成"，并设置为绿色 -->
                                            <DataTrigger Binding="{Binding EqualFlag}" Value="2">
                                                <Setter Property="Text" Value="×"/>
                                                <Setter Property="Foreground" Value="Red"/>
                                            </DataTrigger>
                                            <DataTrigger Binding="{Binding EqualFlag}" Value="1">
                                                <Setter Property="Text" Value="√"/>
                                                <Setter Property="Foreground" Value="Green"/>
                                            </DataTrigger>
                                            <!-- 当 FinishedFlag == 0 时，显示空，并设置为透明 -->
                                            <DataTrigger Binding="{Binding EqualFlag}" Value="0">
                                                <Setter Property="Text" Value="-"/>
                                                <Setter Property="Foreground" Value="#333333"/>
                                            </DataTrigger>
                                        </Style.Triggers>
                                    </Style>
                                </TextBlock.Style>
                            </TextBlock>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn> 

                <DataGridTemplateColumn Header="结果比对" Width="155">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <StackPanel Visibility="{Binding ResultVisiable}" Orientation="Vertical" VerticalAlignment="Center">
                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="0 0 0 5" Background="Transparent">
                                    <TextBlock Text="识别值：" FontSize="13px" Padding="5 0 0 0" VerticalAlignment="Center">
                                        <TextBlock.Style>
                                            <Style TargetType="TextBlock">
                                                <Style.Triggers>
                                                    <!-- 当 FinalResultFlag == 1 时，显示绿色 -->
                                                    <DataTrigger Binding="{Binding EqualFlag}" Value="1">
                                                        <Setter Property="Foreground" Value="Green"/>
                                                    </DataTrigger>

                                                    <!-- 当 FinalResultFlag == 0 时，显示红色 -->
                                                    <DataTrigger Binding="{Binding EqualFlag}" Value="0">
                                                        <Setter Property="Foreground" Value="#666666"/>
                                                    </DataTrigger>

                                                    <DataTrigger Binding="{Binding EqualFlag}" Value="2">
                                                        <Setter Property="Foreground" Value="Red"/>
                                                    </DataTrigger>
                                                </Style.Triggers>
                                            </Style>
                                        </TextBlock.Style>
                                    </TextBlock>

                                    <TextBlock Text="{Binding FinalValue}" FontSize="14px" Margin="0 0 0 0" VerticalAlignment="Center" Padding="2">
                                        <TextBlock.Style>
                                            <Style TargetType="TextBlock">
                                                <Style.Triggers>
                                                    <!-- 当 FinalResultFlag == 1 时，显示绿色 -->
                                                    <DataTrigger Binding="{Binding EqualFlag}" Value="1">
                                                        <Setter Property="Text" Value="{Binding FinalResult}"/>
                                                        <Setter Property="Foreground" Value="Green"/>
                                                    </DataTrigger>

                                                    <!-- 当 FinalResultFlag == 0 时，显示红色 -->
                                                    <DataTrigger Binding="{Binding EqualFlag}" Value="0">
                                                        <Setter Property="Text" Value="{Binding FinalResult}"/>
                                                        <Setter Property="Foreground" Value="#000000"/>
                                                    </DataTrigger>

                                                    <DataTrigger Binding="{Binding EqualFlag}" Value="2">
                                                        <Setter Property="Text" Value="{Binding FinalResult}"/>
                                                        <Setter Property="Foreground" Value="Red"/>
                                                    </DataTrigger>
                                                </Style.Triggers>
                                            </Style>
                                        </TextBlock.Style>
                                    </TextBlock>
                                </StackPanel>

                                <StackPanel Orientation="Horizontal" Margin="0 5 0 0" VerticalAlignment="Center">
                                    <TextBlock Text="标准值：" FontSize="13px" Foreground="#666666" Padding="5 0 0 0" VerticalAlignment="Center" />
                                    <Border BorderBrush="CornflowerBlue" BorderThickness="1" Width="85" Padding="2">
                                        <TextBlock Text="{Binding StandResult}" FontSize="14px" Foreground="#000000" 
                                                   VerticalAlignment="Center" ToolTip="双击修改" PreviewMouseLeftButtonDown="StandResultTextBlock_PreviewMouseLeftButtonDown" />
                                    </Border>
                                </StackPanel>
                            </StackPanel>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="结果图片" Width="120">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <Image Visibility="{Binding ResultVisiable}" Source="{Binding DstImage}" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="2,2,2,2"/>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="识别信息" Width="120">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <StackPanel Visibility="{Binding ResultVisiable}" Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="5,0,0,0">
                                <TextBlock FontSize="14px" Text="{Binding MeterTypeName}" Foreground="#000000" Margin="0 0 0 5" HorizontalAlignment="Center"/>
                                <TextBlock FontSize="14px" Text="{Binding NumCountName}" Foreground="#000000" Margin="0 0 0 5" HorizontalAlignment="Center" />
                                <TextBlock FontSize="13px" HorizontalAlignment="Center">
                                    <Run Text="尾数:" Foreground="#666666"/> 
                                    <Run Text="{Binding LastUnitName}" Foreground="#000000" FontSize="14px"/>
                                </TextBlock>
                            </StackPanel>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="识别结果" Width="140">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <StackPanel Visibility="{Binding ResultVisiable}" Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Stretch" Margin="5 0 0 0">
                                <Grid Width="20" Height="20" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0 0 0 5">
                                    <!-- Ellipse: 圆形 -->
                                    <Ellipse x:Name="circle" HorizontalAlignment="Center" VerticalAlignment="Center" Width="18" Height="18">
                                        <Ellipse.Fill>
                                            <SolidColorBrush Color="{Binding ResultFlagColor}"/>
                                            <!--颜色值要做动态绑定-->
                                        </Ellipse.Fill>
                                    </Ellipse>
                                    <!-- TextBlock: 显示文本 -->
                                    <TextBlock Text="{Binding ResultType}" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="13px" Foreground="White" />
                                </Grid>
                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="0 0 0 5">
                                    <TextBlock Text="结果：" FontSize="13px" Foreground="#666666" Padding="5 0 0 0"/>
                                    <TextBlock Text="{Binding FinalValue}" FontSize="14px" Foreground="#000000" />
                                </StackPanel>
                                <StackPanel Orientation="Horizontal">
                                    <TextBlock Text="原始：" FontSize="13px" Foreground="#666666" Padding="5 0 0 0" />
                                    <TextBlock Text="{Binding RawValue}" FontSize="14px" Foreground="#000000" />
                                </StackPanel>
                            </StackPanel>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>

                <DataGridTemplateColumn Header="调试信息" Width="320">
                    <DataGridTemplateColumn.CellTemplate>
                        <DataTemplate>
                            <Grid Visibility="{Binding ResultVisiable}" VerticalAlignment="Center" HorizontalAlignment="Stretch" Margin="5 0 5 0">
                                <!-- 定义行和列 -->
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition Height="Auto"/>
                                </Grid.RowDefinitions>

                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="*"/>
                                </Grid.ColumnDefinitions>

                                <!-- 第一行 -->
                                <Border Grid.Row="0" Grid.Column="0" BorderBrush="#D3D3D3" BorderThickness="1 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[0]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px" />
                                </Border>
                                <Border Grid.Row="0" Grid.Column="1" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[1]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="2" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[2]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="3" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[3]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="4" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[4]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="5" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[5]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="6" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[6]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="7" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[7]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="8" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[8]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="9" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[9]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="10" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[10]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="0" Grid.Column="11" BorderBrush="#D3D3D3" BorderThickness="0 1 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[11]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>

                                <!-- 第二行 -->
                                <Border Grid.Row="1" Grid.Column="0" BorderBrush="#D3D3D3" BorderThickness="1 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[12]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="1" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[13]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="2" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[14]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="3" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[15]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="4" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[16]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="5" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[17]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="6" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[18]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="7" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[19]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="8" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[20]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="9" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[21]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="10" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[22]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>
                                <Border Grid.Row="1" Grid.Column="11" BorderBrush="#D3D3D3" BorderThickness="0 0 1 1" Padding="0 2">
                                    <TextBlock Text="{Binding AI_result_array[23]}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#333333" FontSize="13px"/>
                                </Border>

                                <StackPanel Grid.Row="2" Grid.ColumnSpan="12">
                                    <TextBlock FontSize="14px" HorizontalAlignment="Left" Margin="5 5 0 0">
                                        <Run Text="AI版本：" Foreground="#666666"/> 
                                        <Run Text="{Binding AiVer}" Foreground="#000000" FontSize="14px"/>
                                    </TextBlock>
                                </StackPanel>

                            </Grid>
                        </DataTemplate>
                    </DataGridTemplateColumn.CellTemplate>
                </DataGridTemplateColumn>
                
                
            </DataGrid.Columns>
        </DataGrid>
    </Grid>
</UserControl>
