Update WineVarietyTemplate
This commit is contained in:
@ -40,7 +40,8 @@
|
|||||||
<ControlTemplate x:Key="WineVarietyTemplateExtended">
|
<ControlTemplate x:Key="WineVarietyTemplateExtended">
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="{Binding SortId}" MinWidth="36" Margin="0,0,10,0"/>
|
<TextBlock Text="{Binding SortId}" MinWidth="36" Margin="0,0,10,0"/>
|
||||||
<TextBlock Text="{Binding NameWithComment}"/>
|
<TextBlock Text="{Binding Name}"/>
|
||||||
|
<TextBlock Text="{Binding CommentFormat}" FontSize="10" VerticalAlignment="Bottom" Margin="0,0,0,2"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</ControlTemplate>
|
</ControlTemplate>
|
||||||
<DataTemplate x:Key="WineVarietyTemplate">
|
<DataTemplate x:Key="WineVarietyTemplate">
|
||||||
|
@ -16,7 +16,7 @@ namespace Elwig.Models {
|
|||||||
[Column("comment")]
|
[Column("comment")]
|
||||||
public string? Comment { get; private set; }
|
public string? Comment { get; private set; }
|
||||||
|
|
||||||
public string NameWithComment => Name + ((Comment != null) ? $" ({Comment})" : "");
|
public string CommentFormat => (Comment != null) ? $" ({Comment})" : "";
|
||||||
|
|
||||||
public override string ToString() {
|
public override string ToString() {
|
||||||
return Name;
|
return Name;
|
||||||
|
Reference in New Issue
Block a user