517 lines
30 KiB
XML
517 lines
30 KiB
XML
<localView:BeWoView
|
|
x:Class="BeWo.View.Detail.AccountingTransactionBookingView"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:Microsoft_Windows_Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Classic"
|
|
xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"
|
|
xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
|
|
xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
|
|
xmlns:localView="clr-namespace:BeWo.View"
|
|
xmlns:localViewControls="clr-namespace:BeWo.View.Controls"
|
|
xmlns:localViewDetail="clr-namespace:BeWo.View.Detail"
|
|
xmlns:localViewModel="clr-namespace:BeWo.ViewModel"
|
|
xmlns:proxy="clr-namespace:BeWo.ServiceProxy"
|
|
xmlns:r="clr-namespace:BeWo.Security"
|
|
xmlns:s="clr-namespace:System;assembly=mscorlib"
|
|
xmlns:uc="clr-namespace:BeWo.Controls;assembly=BeWo.Controls"
|
|
xmlns:val="clr-namespace:BeWo.Validation"
|
|
Width="Auto"
|
|
Height="Auto"
|
|
HorizontalAlignment="Stretch"
|
|
VerticalAlignment="Stretch"
|
|
Focusable="True"
|
|
KeyUp="AccountingTransactionBookingView_OnKeyUp">
|
|
<localView:BeWoView.Resources>
|
|
<ControlTemplate x:Key="AccountingTransactionListBoxTemplate" TargetType="{x:Type ListBox}">
|
|
<Border
|
|
x:Name="Bd"
|
|
Background="{TemplateBinding Background}"
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
SnapsToDevicePixels="True">
|
|
<ScrollViewer
|
|
Padding="{TemplateBinding Padding}"
|
|
Focusable="False"
|
|
HorizontalScrollBarVisibility="Disabled">
|
|
<ItemsPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
|
|
</ScrollViewer>
|
|
</Border>
|
|
</ControlTemplate>
|
|
<Style x:Key="AccountingTransactionListStyle" TargetType="{x:Type ListBox}">
|
|
<Setter Property="Template" Value="{StaticResource AccountingTransactionListBoxTemplate}" />
|
|
<Setter Property="Padding" Value="2,0,2,2" />
|
|
</Style>
|
|
<Style x:Key="AccountingTransactionListBoxItemStyle" TargetType="{x:Type ListBoxItem}">
|
|
<Setter Property="Background" Value="#00FFFFFF" />
|
|
<Setter Property="HorizontalContentAlignment" Value="{Binding Path=HorizontalContentAlignment, RelativeSource={RelativeSource FindAncestor, AncestorLevel=1, AncestorType={x:Type ItemsControl}}}" />
|
|
<Setter Property="VerticalContentAlignment" Value="{Binding Path=VerticalContentAlignment, RelativeSource={RelativeSource FindAncestor, AncestorLevel=1, AncestorType={x:Type ItemsControl}}}" />
|
|
<Setter Property="Padding" Value="2,0,0,0" />
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ListBoxItem}">
|
|
<Border
|
|
x:Name="Bd"
|
|
Padding="{TemplateBinding Padding}"
|
|
Background="{TemplateBinding Background}"
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
BorderThickness="{TemplateBinding BorderThickness}"
|
|
SnapsToDevicePixels="True">
|
|
<ContentPresenter
|
|
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
|
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
|
|
Content="{TemplateBinding Content}"
|
|
ContentStringFormat="{TemplateBinding ContentStringFormat}"
|
|
ContentTemplate="{TemplateBinding ContentTemplate}"
|
|
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
|
|
</Border>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}" />
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</localView:BeWoView.Resources>
|
|
<Grid>
|
|
<Grid x:Name="rootGrid">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="*" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<CheckBox
|
|
x:Name="chkWithClient"
|
|
Grid.Row="0"
|
|
Margin="0,3,0,0"
|
|
Checked="chkWithClient_Checked"
|
|
Content="Buchungen für ausgewählten Hilfeplan"
|
|
IsChecked="True"
|
|
Unchecked="chkWithClient_Unchecked" />
|
|
<uc:PopUpEdit
|
|
Name="popupedit_file"
|
|
Grid.Row="0"
|
|
Grid.Column="1"
|
|
Width="250"
|
|
Height="23"
|
|
Margin="30,0,0,0"
|
|
HorizontalAlignment="Left"
|
|
DeleteButtonVisibility="Collapsed"
|
|
IsReadOnly="True"
|
|
PopUpClick="popupedit_file_PopUpClick" />
|
|
<Button
|
|
x:Name="ButtonImport"
|
|
Grid.Column="2"
|
|
Height="22"
|
|
Margin="5,0,0,0"
|
|
HorizontalAlignment="Left"
|
|
VerticalAlignment="Center"
|
|
Click="ButtonImport_Click"
|
|
Content="Abschlagszahlungen importieren"
|
|
Visibility="Visible" />
|
|
<Grid
|
|
x:Name="customerInfoGrid"
|
|
Grid.Row="1"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="3"
|
|
Margin="0,3,0,0">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="250" />
|
|
<ColumnDefinition />
|
|
</Grid.ColumnDefinitions>
|
|
<!--<uc:NullItemComboBox x:Name="customerComboBox" IsSynchronizedWithCurrentItem="True" AlternationCount="-1"
|
|
ItemTemplate="{DynamicResource CustomerComboBoxItemTemplate}"
|
|
SelectionChanged="customerComboBox_SelectionChanged" Height="62"
|
|
ItemsPanel="{DynamicResource CustomerComboBoxItemsPanelTemplate}"
|
|
Background="{DynamicResource SupportConceptListBrush}" HorizontalContentAlignment="Stretch"
|
|
Style="{DynamicResource ObjectComboBoxStyle}" PreviewTextInput="customerComboBox_PreviewTextInput"
|
|
LostFocus="customerComboBox_LostFocus" GotFocus="customerComboBox_GotFocus"
|
|
PreviewKeyDown="customerComboBox_PreviewKeyDown" />-->
|
|
<localViewControls:SingleSupportConceptSelectionControl
|
|
x:Name="supportConceptSelectionControl"
|
|
Height="62"
|
|
VerticalAlignment="Top"
|
|
HorizontalContentAlignment="Stretch"
|
|
ItemSelected="supportConceptSelectionControl_ItemSelected" />
|
|
<Grid
|
|
Grid.Row="0"
|
|
Grid.Column="1"
|
|
Margin="5,5,0,0"
|
|
VerticalAlignment="Top">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="*" />
|
|
<ColumnDefinition Width="Auto" />
|
|
</Grid.ColumnDefinitions>
|
|
<TextBlock
|
|
FontSize="14"
|
|
Foreground="#FF2B508B"
|
|
Text="{Binding Path=InformationString}" />
|
|
</Grid>
|
|
</Grid>
|
|
<Grid
|
|
x:Name="customerDetailGrid"
|
|
Grid.Row="2"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="3"
|
|
Margin="0,5,0,0">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<GroupBox
|
|
Margin="0,0,0,-3"
|
|
Padding="0,0,0,0"
|
|
Header="Neue Buchung anlegen"
|
|
Style="{DynamicResource ObjectEditGroupBox}">
|
|
<Grid>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="*" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<Grid x:Name="newObjectInfoGrid">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="*" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="*" />
|
|
<RowDefinition Height="Auto" />
|
|
</Grid.RowDefinitions>
|
|
<Grid>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="250" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<!-- TextBlock Foreground="Black" TextWrapping="Wrap" Margin="3,3,7,3" Text="Klient/in:"/ -->
|
|
<Grid Grid.Row="1" Grid.Column="0">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="*" />
|
|
<ColumnDefinition Width="Auto" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<Label
|
|
Grid.Row="0"
|
|
Grid.Column="0"
|
|
VerticalAlignment="Center"
|
|
Content="Betrag €" />
|
|
<dxe:TextEdit
|
|
Grid.Row="0"
|
|
Grid.Column="1"
|
|
Height="23"
|
|
Margin="3"
|
|
AllowNullInput="True"
|
|
EditValue="{val:ValidationBinding Path=PrototypeVM.Amount,
|
|
Mode=TwoWay}"
|
|
Mask="c"
|
|
MaskType="Numeric"
|
|
MaskUseAsDisplayFormat="True" />
|
|
<StackPanel
|
|
Grid.Row="0"
|
|
Grid.Column="2"
|
|
Margin="3,0,0,0"
|
|
Orientation="Vertical">
|
|
<TextBlock x:Name="txtMonthlyAmount">
|
|
<Hyperlink
|
|
x:Name="linkMonthlyAmount"
|
|
Click="linkMonthlyAmount_Click"
|
|
Foreground="#FF2B508B">
|
|
mtl. Abschlag
|
|
</Hyperlink></TextBlock>
|
|
<TextBlock x:Name="txtOpenAmount">
|
|
<Hyperlink
|
|
x:Name="linkOpenAmount"
|
|
Click="linkOpenAmount_Click"
|
|
Foreground="#FF2B508B">
|
|
Restbetrag
|
|
</Hyperlink></TextBlock>
|
|
</StackPanel>
|
|
<Label
|
|
Grid.Row="1"
|
|
Grid.Column="0"
|
|
VerticalAlignment="Center"
|
|
Content="Buchungsdatum" />
|
|
<dxe:DateEdit
|
|
Grid.Row="1"
|
|
Grid.Column="1"
|
|
Grid.ColumnSpan="2"
|
|
Height="23"
|
|
Margin="3"
|
|
Background="White"
|
|
EditValue="{val:ValidationBinding Path=PrototypeVM.BookingDate,
|
|
Mode=TwoWay}"
|
|
MaskType="DateTimeAdvancingCaret" />
|
|
|
|
<Label
|
|
Grid.Row="2"
|
|
Grid.Column="0"
|
|
VerticalAlignment="Center"
|
|
Content="Gültigkeitsdatum" />
|
|
<dxe:DateEdit
|
|
Grid.Row="2"
|
|
Grid.Column="1"
|
|
Grid.ColumnSpan="2"
|
|
Height="23"
|
|
Margin="3"
|
|
Background="White"
|
|
EditValue="{val:ValidationBinding Path=PrototypeVM.ValidityDate,
|
|
Mode=TwoWay}"
|
|
MaskType="DateTimeAdvancingCaret" />
|
|
|
|
<Label Grid.Row="3" Content="Kategorie" />
|
|
<uc:NullItemComboBox
|
|
x:Name="combobox_categories"
|
|
Grid.Row="3"
|
|
Grid.Column="1"
|
|
Grid.ColumnSpan="2"
|
|
Height="23"
|
|
Margin="3"
|
|
SelectedItem="{val:ValidationBinding Path=PrototypeVM.Category}" />
|
|
<Label
|
|
Grid.Row="4"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="3"
|
|
HorizontalAlignment="Left"
|
|
VerticalAlignment="Top"
|
|
Content="Kommentar" />
|
|
<TextBox
|
|
Grid.Row="5"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="3"
|
|
Margin="3"
|
|
VerticalAlignment="Stretch"
|
|
AcceptsReturn="True"
|
|
AutoWordSelection="True"
|
|
HorizontalScrollBarVisibility="Hidden"
|
|
Text="{val:ValidationBinding Path=PrototypeVM.Notice,
|
|
UpdateSourceTrigger=PropertyChanged}"
|
|
TextWrapping="Wrap"
|
|
VerticalScrollBarVisibility="Auto" />
|
|
</Grid>
|
|
</Grid>
|
|
<Grid Grid.Row="1" Margin="0,0,0,0">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="*" />
|
|
<ColumnDefinition Width="Auto" />
|
|
</Grid.ColumnDefinitions>
|
|
<TextBlock
|
|
Margin="0,0,3,0"
|
|
VerticalAlignment="Center"
|
|
Foreground="#FF000000"
|
|
Text="{Binding Path=Information}"
|
|
TextWrapping="Wrap" />
|
|
<Button
|
|
x:Name="button_add"
|
|
Grid.Column="1"
|
|
Height="23"
|
|
Margin="0,0,3,0"
|
|
BorderThickness="3,3,3,3"
|
|
Click="button_add_Click"
|
|
Content="Speichern"
|
|
FontWeight="Normal" />
|
|
</Grid>
|
|
</Grid>
|
|
</Grid>
|
|
</GroupBox>
|
|
|
|
<ListBox
|
|
x:Name="accountingTransactionGrid"
|
|
Grid.Row="0"
|
|
Grid.Column="1"
|
|
Margin="0,0,0,25"
|
|
HorizontalContentAlignment="Stretch"
|
|
AlternationCount="-1"
|
|
Background="{x:Null}"
|
|
IsSynchronizedWithCurrentItem="True"
|
|
ItemContainerStyle="{DynamicResource AccountingTransactionListBoxItemStyle}"
|
|
ItemTemplate="{DynamicResource AccountingTransactionListBoxItemTemplate}"
|
|
MouseDoubleClick="AccountingTransactionGrid_MouseDoubleClick"
|
|
ScrollViewer.CanContentScroll="True"
|
|
Style="{DynamicResource AccountingTransactionListStyle}"
|
|
TabIndex="1">
|
|
<ListBox.Resources>
|
|
<DataTemplate x:Key="AccountingTransactionListBoxItemTemplate" DataType="{x:Type localViewModel:AccountingTransactionVM}">
|
|
<Grid
|
|
x:Name="template"
|
|
HorizontalAlignment="Stretch"
|
|
VerticalAlignment="Stretch">
|
|
<Border
|
|
x:Name="ItemBorder"
|
|
Width="Auto"
|
|
Height="Auto"
|
|
Margin="0,0,0,3"
|
|
Padding="6"
|
|
Background="#FFFFFFFF"
|
|
BorderBrush="#FF7E7E7E"
|
|
BorderThickness="1,1,1,1"
|
|
CornerRadius="4,4,4,4">
|
|
<Grid TextBlock.Foreground="{Binding Path=TextBlock.Foreground, RelativeSource={RelativeSource TemplatedParent}}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="80" />
|
|
<ColumnDefinition Width="12" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="12" />
|
|
<ColumnDefinition Width="*" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="14" />
|
|
<RowDefinition Height="*" />
|
|
<RowDefinition Height="24" />
|
|
</Grid.RowDefinitions>
|
|
<TextBlock
|
|
Grid.Row="0"
|
|
Grid.Column="0"
|
|
Background="{x:Null}"
|
|
FontWeight="Bold"
|
|
Foreground="{Binding Path=AmountForegroundBrush}"
|
|
Text="{Binding Path=Amount, StringFormat=\{0:0.00\} €}" />
|
|
|
|
<TextBlock
|
|
Grid.Row="0"
|
|
Grid.Column="2"
|
|
FontWeight="Bold"
|
|
Foreground="#FF494949"
|
|
Text="{Binding Path=DatumsText}" />
|
|
<TextBlock
|
|
Grid.Row="0"
|
|
Grid.Column="4"
|
|
FontWeight="Bold"
|
|
Foreground="#FF494949"
|
|
Text="{Binding Path=Category}" />
|
|
<TextBox
|
|
Grid.Row="1"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="5"
|
|
MaxHeight="200"
|
|
Margin="0,0,0,0"
|
|
HorizontalAlignment="Stretch"
|
|
AutoWordSelection="True"
|
|
Background="{x:Null}"
|
|
BorderBrush="{x:Null}"
|
|
BorderThickness="1,1,1,1"
|
|
Focusable="True"
|
|
GotFocus="TextBox_GotFocus"
|
|
HorizontalScrollBarVisibility="Hidden"
|
|
IsEnabled="True"
|
|
IsReadOnly="True"
|
|
SnapsToDevicePixels="True"
|
|
Tag="{Binding}"
|
|
Text="{Binding Path=Notice}"
|
|
TextWrapping="Wrap"
|
|
VerticalScrollBarVisibility="Hidden" />
|
|
<TextBlock
|
|
Grid.Row="2"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="5"
|
|
VerticalAlignment="Bottom"
|
|
FontSize="10"
|
|
Visibility="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type localViewDetail:AccountingTransactionBookingView}}, Path=InsertedOnAndByVisibility}">
|
|
<TextBlock.Text>
|
|
<MultiBinding StringFormat="{}Angelegt am {0:dd.MM.yyyy hh:mm} von {1}">
|
|
<Binding Path="InsertedOn" />
|
|
<Binding Path="InsUser" />
|
|
</MultiBinding>
|
|
</TextBlock.Text>
|
|
</TextBlock>
|
|
<Button
|
|
x:Name="btnEdit"
|
|
Grid.Row="2"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="5"
|
|
Width="32"
|
|
Height="22"
|
|
Margin="0,0,35,0"
|
|
Padding="1,1,1,1"
|
|
HorizontalAlignment="Right"
|
|
BorderThickness="1,1,1,1"
|
|
Click="btnEdit_Click"
|
|
Style="{DynamicResource GlassButton}"
|
|
Tag="{Binding}"
|
|
Visibility="{Binding Path=EditAllowed, Converter={StaticResource BoolVisibilityConverter}}">
|
|
<Image
|
|
Margin="1,1,1,1"
|
|
Source="..\..\Ressources\Icons\Symbol Edit.png"
|
|
Stretch="Uniform" />
|
|
</Button>
|
|
<Button
|
|
x:Name="btnDelete"
|
|
Grid.Row="2"
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="5"
|
|
Width="32"
|
|
Height="22"
|
|
Margin="0,0,0,0"
|
|
Padding="1,1,1,1"
|
|
HorizontalAlignment="Right"
|
|
BorderThickness="1,1,1,1"
|
|
Click="btnDelete_Click"
|
|
Style="{DynamicResource GlassButton}"
|
|
Tag="{Binding}"
|
|
Visibility="{Binding Path=EditAllowed, Converter={StaticResource BoolVisibilityConverter}}">
|
|
<Image
|
|
Margin="1,1,1,1"
|
|
Source="..\..\Ressources\Icons\Symbol Delete.png"
|
|
Stretch="Uniform" />
|
|
</Button>
|
|
</Grid>
|
|
</Border>
|
|
</Grid>
|
|
<DataTemplate.Triggers>
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
<Setter TargetName="ItemBorder" Property="Background" Value="#FFCCE0FF" />
|
|
</Trigger>
|
|
<DataTrigger Binding="{Binding Path=IsSelected, RelativeSource={RelativeSource AncestorType={x:Type ListBoxItem}, Mode=FindAncestor}}" Value="True">
|
|
<Setter TargetName="ItemBorder" Property="Background" Value="#FF93BCFF" />
|
|
</DataTrigger>
|
|
</DataTemplate.Triggers>
|
|
</DataTemplate>
|
|
</ListBox.Resources>
|
|
</ListBox>
|
|
<TextBlock
|
|
x:Name="txtServiceListCount"
|
|
Grid.Column="1"
|
|
Margin="5,0,5,3"
|
|
HorizontalAlignment="Left"
|
|
VerticalAlignment="Bottom"
|
|
FontSize="14"
|
|
Foreground="#FF2B508B"
|
|
Text="{Binding Path=RecordCountInformationString}" />
|
|
<TextBlock
|
|
x:Name="textblock_link"
|
|
Grid.Column="1"
|
|
Margin="5,0,5,3"
|
|
HorizontalAlignment="Right"
|
|
VerticalAlignment="Bottom"
|
|
FontSize="14">
|
|
<Hyperlink
|
|
x:Name="linkExcelExport"
|
|
Foreground="#FF2B508B"
|
|
RequestNavigate="linkExcelExport_RequestNavigate"
|
|
TargetName="newWindow">
|
|
<Run Text="Excel Export" />
|
|
</Hyperlink></TextBlock>
|
|
</Grid>
|
|
</Grid>
|
|
<Border x:Name="popup_content" />
|
|
</Grid>
|
|
</localView:BeWoView> |