<localView:BeWoView x:Class="BeWo.View.Report.FLSReport.FLSReportView" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:localView="clr-namespace:BeWo.View"
                    xmlns:localSearchView="clr-namespace:BeWo.View.Search"
                    xmlns:uc="clr-namespace:BeWo.Controls;assembly=BeWo.Controls"
                    xmlns:proxy="clr-namespace:BeWo.ServiceProxy"
                    xmlns:sharedCompact="clr-namespace:BS.Shared.DataContracts.Compact;assembly=BS.Shared" Height="Auto" Width="Auto"
                    xmlns:shared="clr-namespace:BS.Shared.DataContracts;assembly=BS.Shared"
                    xmlns:core="clr-namespace:BeWo.Core"
                    HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Focusable="True"
                    xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
                    xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"
                    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
                    xmlns:localViewControls="clr-namespace:BeWo.View.Controls" mc:Ignorable="d">
	<GroupBox Style="{StaticResource ObjectEditGroupBox}" Header="Auswertung über erbrachte Stunden">
		<Grid>
			<Grid.ColumnDefinitions>
				<ColumnDefinition Width="*" />
			</Grid.ColumnDefinitions>
			<Grid.RowDefinitions>
				<RowDefinition Height="Auto" />
				<RowDefinition Height="*" />
			</Grid.RowDefinitions>
			<uc:ExpanderPanel x:Name="expanderPanel" HorizontalAlignment="Stretch" Height="Auto" Style="{DynamicResource SearchExpanderPanelStyle}" BorderThickness="0,0,0,0" Margin="0,0,0,2">
				<uc:ExpanderPanel.Header>
					<Grid>
						<Grid.ColumnDefinitions>
							<ColumnDefinition Width="Auto" />
							<ColumnDefinition Width="Auto" />
							<ColumnDefinition Width="Auto" />
							<ColumnDefinition Width="Auto" />
							<ColumnDefinition Width="Auto"/>
						</Grid.ColumnDefinitions>
						<Button x:Name="button_generate" Grid.Column="0" Content="Aktualisieren" Click="button_generate_Click" Height="24" HorizontalAlignment="Left" Width="80" />
						<RadioButton x:Name="radioEmployeeReport" Grid.Column="1" Content="Nach Mitarbeiter gruppieren" GroupName="radioReportType" IsChecked="True" Margin="4,4,0,0" Checked="RadioButton_Checked" />
						<RadioButton x:Name="radioClientReport" Grid.Column="2" GroupName="radioReportType" Content="Nach Klient gruppieren" Margin="4,4,0,0" Checked="RadioButton_Checked" />
						<RadioButton x:Name="radioCostbearerReport" Grid.Column="3" GroupName="radioReportType" Content="Nach Kostenträger gruppieren" Margin="4,4,0,0" Checked="RadioButton_Checked" />
						<RadioButton x:Name="radioTeamReport" Grid.Column="4" GroupName="radioReportType" Content="Nach Team gruppieren" Margin="4,4,0,0" Checked="RadioButton_Checked"/>
					</Grid>
				</uc:ExpanderPanel.Header>
				<Grid>
					<Grid.ColumnDefinitions>
						<ColumnDefinition Width="Auto" />
						<ColumnDefinition Width="Auto" />
						<ColumnDefinition Width="Auto" />
						<ColumnDefinition Width="*" />
					</Grid.ColumnDefinitions>
					<Grid.RowDefinitions>
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
						<RowDefinition Height="Auto" />
					</Grid.RowDefinitions>
					<CheckBox x:Name="checkbox_all" IsChecked="False" Content="Für alle Mitarbeiter" Checked="CheckBox_Checked" Margin="0,5,0,0" Grid.ColumnSpan="1" />
					<CheckBox x:Name="checkbox_archivierte_mitarbeiter" IsChecked="False" Content="Archivierte Mitarbeiter" Margin="0,5,0,0"
					          Grid.Row="0" Grid.Column="1" HorizontalAlignment="Right" 
							  Visibility="{Binding Path=IsChecked, Converter={StaticResource BoolVisibilityHiddenConverter}, ConverterParameter=true, ElementName=checkbox_all}"
							  IsEnabled="{Binding Path=IsEnabled, ElementName=checkbox_all}"/>
					<Label x:Name="lblEmployee" Visibility="{Binding Path=IsChecked, Converter={StaticResource BoolVisibilityHiddenConverter}, ConverterParameter=false, ElementName=checkbox_all}" Content="Mitarbeiter:" HorizontalAlignment="Left" Grid.Column="0" Grid.Row="1" VerticalAlignment="Center" />
					<uc:PopUpEdit IsReadOnly="True"
                                  Visibility="{Binding Path=IsChecked, Converter={StaticResource BoolVisibilityHiddenConverter}, ConverterParameter=false, ElementName=checkbox_all}"
                                  x:Name="popupedit_employee" DeleteButtonVisibility="Collapsed"
                                  PopUpClick="popupedit_employee_PopUpClick" HorizontalAlignment="Left"
                                  Width="175" HorizontalContentAlignment="Left" Height="24" Grid.Column="1"
					              Grid.Row="1" Margin="3,0,0,0" Cursor="Arrow" PreviewMouseDoubleClick="Popupedit_employee_OnPreviewMouseDoubleClick" />
					<CheckBox x:Name="checkbox_all_client" IsChecked="False" Content="Für alle Klienten" Checked="CheckBox_Customer_Checked" Margin="0,5,0,0" Grid.ColumnSpan="2" Grid.Column="0" Grid.Row="2" />
					<Label x:Name="lblClient" Visibility="{Binding Path=IsChecked, Converter={StaticResource BoolVisibilityHiddenConverter}, ConverterParameter=false, ElementName=checkbox_all_client}" Content="Klient:" HorizontalAlignment="Left" Grid.Column="0" Grid.Row="3" VerticalAlignment="Center" />
					<uc:PopUpEdit IsReadOnly="True" Visibility="{Binding Path=IsChecked, Converter={StaticResource BoolVisibilityHiddenConverter}, ConverterParameter=false, ElementName=checkbox_all_client}"
                                  x:Name="popupedit_client" DeleteButtonVisibility="Collapsed"
                                  PopUpClick="popupedit_customer_PopUpClick" HorizontalAlignment="Left" Width="175"
                                  HorizontalContentAlignment="Left" Height="24" Grid.Column="1"
					              Grid.Row="3" Margin="3,0,0,0" Cursor="Arrow" PreviewMouseDoubleClick="Popupedit_client_OnPreviewMouseDoubleClick" />
					<Label Content="Startdatum:" Grid.Column="0" Grid.Row="4" VerticalAlignment="Center" />
					<dxe:DateEdit MaskType="DateTimeAdvancingCaret" Grid.Column="1" Grid.Row="4" x:Name="datePickerStartDate" Width="120" HorizontalAlignment="Left" Margin="3,0,0,0" />
					<Label Content="Enddatum:" Grid.Column="0" Grid.Row="5" VerticalAlignment="Center" />
					<dxe:DateEdit MaskType="DateTimeAdvancingCaret" Grid.Column="1" Grid.Row="5" x:Name="datePickerEndDate" HorizontalAlignment="Left" Width="120" Margin="3,0,0,0" />
					<Label Grid.Row="0" Content="Intervall" Margin="10,0,0,0" Grid.Column="2" Padding="0,5,0,0" />
					<StackPanel Grid.ColumnSpan="1" Grid.Row="1" Grid.Column="2" HorizontalAlignment="Left" Orientation="Vertical" Margin="10,8,0,0" Grid.RowSpan="7" VerticalAlignment="Stretch">
						<RadioButton Content="Tag" Height="23" GroupName="interval" x:Name="radioButtonIntervalDay" />
						<RadioButton Content="Woche" Height="23" IsChecked="True" GroupName="interval" x:Name="radioButtonIntervalWeek" Margin="0,0,0,0" />
						<RadioButton Content="Monat" Height="23" GroupName="interval" x:Name="radioButtonIntervalMonth" Margin="0,0,0,0" />
						<RadioButton Content="Quartal" Height="23" GroupName="interval" x:Name="radioButtonIntervalQuarter" Margin="0,0,0,0" />
						<RadioButton Content="Jahr" Height="23" GroupName="interval" x:Name="radioButtonIntervalYear" Margin="0,0,0,0" />
					</StackPanel>
					<Label Grid.Row="0" Content="Leistungskategorien" Margin="10,0,0,0" Grid.Column="3" Padding="0,5,0,0" />
					<!--<ListBox IsSynchronizedWithCurrentItem="True" Grid.Column="3" Grid.Row="1" Grid.RowSpan="3" Margin="10,0,0,0" x:Name="serviceCategoryList" Height="72" VerticalAlignment="Top" />-->

					<localViewControls:ComboBoxTreeViewControlV2  Margin="5,0,0,0"
																  x:Name="ComboBoxTreeViewControlV2"
																  Grid.Column="3" Grid.Row="1" Grid.RowSpan="1" VerticalAlignment="Top"/>
					<Label Grid.Column="3" Grid.Row="2" Content="Ziele" x:Name="lblGoals" Margin="10,0,0,0" Padding="0,5,0,0" />
					<localViewControls:ComboBoxTreeViewControl  Margin="5,0,0,0"
																x:Name="ComboBoxTreeViewControl"
																Grid.Column="3" Grid.Row="3" Grid.RowSpan="1" VerticalAlignment="Top"/>
					<CheckBox x:Name="checkbox_showServiceRecords" Grid.Column="3" Grid.Row="4" IsChecked="False" Content="Einträge auflisten" Margin="10,5,0,0" Grid.ColumnSpan="1" />
					<CheckBox x:Name="checkbox_sortBySubGroup" Grid.Column="3" Grid.Row="5" IsChecked="False" Content="Nach Klienten sortieren" Margin="10,5,0,0" Grid.ColumnSpan="1" />
					<CheckBox x:Name="checkbox_showChart" Grid.Column="3" Grid.Row="6" IsChecked="False" Content="Diagramm anzeigen" Margin="10,5,0,0" Grid.ColumnSpan="1" />

					<CheckBox x:Name="checkbox_showMarker" Grid.Column="3" Grid.Row="4" IsChecked="False" Content="Nur Marker anzeigen" Margin="170,5,0,0" />

				</Grid>
			</uc:ExpanderPanel>
			<Grid Background="{DynamicResource EmployeeContentBrush}" x:Name="reportContent" Grid.Row="1" Grid.ColumnSpan="7" Margin="0,0,0,18" />
			<TextBlock Grid.Column="0" Grid.ColumnSpan="7" Grid.Row="1" x:Name="textblock_link_pdfexport" VerticalAlignment="Bottom" Margin="0,0,90,0" HorizontalAlignment="Right" FontSize="14">
				<Hyperlink x:Name="linkPdfExport" TargetName="_NewWindow" Foreground="#FF2B508B" RequestNavigate="linkPdfExport_RequestNavigate">
					<Run Text="Drucken" />
				</Hyperlink>
			</TextBlock>
			<TextBlock Grid.Column="0" Grid.ColumnSpan="7" Grid.Row="1" x:Name="textblock_link" VerticalAlignment="Bottom" Margin="0,0,5,0" HorizontalAlignment="Right" FontSize="14">
				<Hyperlink x:Name="linkExcelExport" TargetName="newWindow" Foreground="#FF2B508B" RequestNavigate="linkExcelExport_RequestNavigate">
					<Run Text="Excel Export" />
				</Hyperlink>
			</TextBlock>
			<Popup Margin="10" x:Name="popup_employee" StaysOpen="False" Placement="MousePoint" Width="400" Grid.Row="5" Height="400" Grid.ColumnSpan="7">
				<localSearchView:EmployeeSearchView ItemSelected="EmployeeSearchView_CustomerSelected" ShowArchived="True" x:Name="employeeSearchView" />
			</Popup>
			<Popup Margin="10" x:Name="popup_customer" StaysOpen="False" Placement="MousePoint" Width="400" Grid.Row="5" Height="400" Grid.ColumnSpan="7">
				<localSearchView:CustomerSearchView ItemSelected="CustomerSearchView_CustomerSelected" x:Name="customerSearchView" />
			</Popup>
		</Grid>
	</GroupBox>
</localView:BeWoView>