Misc UI tweaks/fixes
This commit is contained in:
@@ -23,7 +23,7 @@ class ReportFile : ChangeNotifier
|
||||
public ReportFile(ReportFile other)
|
||||
{
|
||||
Title = _title = other.Title;
|
||||
ReceiptDateTime = _receiptDateTime = other.ReceiptDateTime;
|
||||
ReceiptDateTime = _receiptDateTime = other.ReceiptDateTime ?? DateTime.Now;
|
||||
Notes = _notes = other.Notes;
|
||||
FilePath = _filePath = other.FilePath;
|
||||
}
|
||||
@@ -34,12 +34,12 @@ class ReportFile : ChangeNotifier
|
||||
set { _title = value; NotifyPropertyChanged(); }
|
||||
}
|
||||
|
||||
public DateTime ReceiptDateTime
|
||||
public DateTime? ReceiptDateTime
|
||||
{
|
||||
get => _receiptDateTime;
|
||||
set
|
||||
{
|
||||
_receiptDateTime = value;
|
||||
_receiptDateTime = value ?? DateTime.Now;
|
||||
NotifyPropertyChanged();
|
||||
NotifyPropertyChanged(nameof(ReceiptDate));
|
||||
}
|
||||
|
||||
@@ -136,7 +136,7 @@
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTemplateColumn Header="Receipt Date"
|
||||
IsReadOnly="False"
|
||||
Width="125">
|
||||
Width="150">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<Label VerticalAlignment="Center"
|
||||
@@ -156,6 +156,8 @@
|
||||
<CalendarDatePicker SelectedDate="{Binding ReceiptDateTime}"
|
||||
DisplayDate="{Binding ReceiptDateTime}"
|
||||
SelectedDateFormat="Custom"
|
||||
HorizontalAlignment="Stretch"
|
||||
Watermark="12/31/2025"
|
||||
CustomDateFormatString="{Binding $parent[UserControl].((vm:MainViewModel)DataContext).DataGridDateFormat}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
@@ -167,6 +169,7 @@
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding FileName}"
|
||||
VerticalAlignment="Center"
|
||||
TextTrimming="PrefixCharacterEllipsis"
|
||||
ToolTip.Tip="{Binding FileName}"
|
||||
Margin="8,0,8,0"
|
||||
HorizontalAlignment="Left"/>
|
||||
@@ -175,7 +178,7 @@
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTemplateColumn Header=""
|
||||
IsReadOnly="True"
|
||||
Width="*">
|
||||
Width="200">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<StackPanel Orientation="Horizontal"
|
||||
@@ -184,6 +187,7 @@
|
||||
CommandParameter="{Binding}"
|
||||
Classes="accent"
|
||||
Margin="2"
|
||||
FontSize="12"
|
||||
IsEnabled="{Binding !$parent[UserControl].((vm:MainViewModel)DataContext).IsCreatingPDF}">
|
||||
<Button.Content>
|
||||
<TextBlock><Run Text="" FontFamily="{StaticResource FontAwesomeSolid}"/> Edit</TextBlock>
|
||||
@@ -193,6 +197,7 @@
|
||||
CommandParameter="{Binding}"
|
||||
Classes="Danger"
|
||||
Margin="2"
|
||||
FontSize="12"
|
||||
IsEnabled="{Binding !$parent[UserControl].((vm:MainViewModel)DataContext).IsCreatingPDF}">
|
||||
<Button.Content>
|
||||
<TextBlock><Run Text="" FontFamily="{StaticResource FontAwesomeSolid}"/> Remove</TextBlock>
|
||||
|
||||
Reference in New Issue
Block a user