257 lines
16 KiB
XML
257 lines
16 KiB
XML
<UserControl
|
|
x:Class="BeWo.View.Detail.Wohneinheit.WohneinheitBelegungSchedulerView"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"
|
|
xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars"
|
|
xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
|
|
xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
|
|
xmlns:dxlc="http://schemas.devexpress.com/winfx/2008/xaml/layoutcontrol"
|
|
xmlns:dxr="http://schemas.devexpress.com/winfx/2008/xaml/ribbon"
|
|
xmlns:dxsch="http://schemas.devexpress.com/winfx/2008/xaml/scheduling"
|
|
xmlns:local="clr-namespace:BeWo.View.Detail.Wohneinheit"
|
|
xmlns:markup="clr-namespace:BeWo.MultiLanguage.Markup"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:viewmodel="clr-namespace:BeWo.ViewModel"
|
|
d:DataContext="{d:DesignInstance Type=viewmodel:WohnheimVM,
|
|
IsDesignTimeCreatable=true}"
|
|
d:DesignHeight="450"
|
|
d:DesignWidth="800"
|
|
mc:Ignorable="d">
|
|
<UserControl.Resources>
|
|
<ResourceDictionary>
|
|
<DataTemplate x:Key="resourceHeaderContentTemplate">
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
</Grid.RowDefinitions>
|
|
<StackPanel>
|
|
<TextBlock
|
|
HorizontalAlignment="Center"
|
|
FontWeight="Bold"
|
|
Text="{Binding Resource.SourceObject.Displayname}" />
|
|
</StackPanel>
|
|
</Grid>
|
|
</DataTemplate>
|
|
<DataTemplate x:Key="Options.TimelineView.Ribbon">
|
|
<dxr:RibbonControl>
|
|
<dxr:RibbonPage Style="{StaticResource Options.RibbonPage}">
|
|
<dxr:RibbonPageGroup Caption="Scheduler Settings">
|
|
<dxb:BarSubItem Style="{StaticResource Options.BarSubItem.WorkDays}" />
|
|
<dxb:BarEditItem Style="{StaticResource Options.BarEditItem.StartWorkTime}" />
|
|
<dxb:BarEditItem Style="{StaticResource Options.BarEditItem.EndWorkTime}" />
|
|
<dxb:BarSubItem Style="{StaticResource Options.BarSubItem.FirstDayOfWeek}" />
|
|
</dxr:RibbonPageGroup>
|
|
<dxr:RibbonPageGroup Caption="View Settings">
|
|
<dxb:BarSubItem Style="{StaticResource Options.BarSubItem.HeadersVisibility}" />
|
|
<dxb:BarSubItem Style="{StaticResource Options.BarSubItem.NavigationButtonsVisibility}" />
|
|
<dxb:BarSubItem Style="{StaticResource Options.BarSubItem.MoreButtonsVisibility}" />
|
|
<dxb:BarEditItem Style="{StaticResource Options.BarEditItem.TimelineAppointmentMinHeight}" />
|
|
<dxb:BarEditItem Style="{StaticResource Options.BarEditItem.TimelineResourceMinHeight}" />
|
|
<dxb:BarEditItem Style="{StaticResource Options.BarEditItem.TimelineResourceMaxHeight}" />
|
|
<dxb:BarEditItem Style="{StaticResource Options.BarEditItem.TimelineStretchAppointments}" />
|
|
</dxr:RibbonPageGroup>
|
|
</dxr:RibbonPage>
|
|
</dxr:RibbonControl>
|
|
</DataTemplate>
|
|
<Style x:Key="timelineView.Style" TargetType="dxsch:TimelineView">
|
|
<Setter Property="ShowInCommandBar" Value="False" />
|
|
<Setter Property="AppointmentMinHeight" Value="20" />
|
|
<Setter Property="AppointmentMinWidth" Value="40" />
|
|
<Setter Property="ResourceMinHeight" Value="44" />
|
|
<Setter Property="ResourceMaxHeight" Value="116" />
|
|
<Setter Property="SnapToCellsMode" Value="Never" />
|
|
<Setter Property="MoreButtonsVisibility" Value="Never" />
|
|
<Setter Property="ShowAppointmentStatus" Value="False" />
|
|
<Setter Property="ShowAppointmentInterval" Value="False" />
|
|
<Setter Property="NavigationButtonsVisibility" Value="Never" />
|
|
<Setter Property="ResourceWidth" Value="150" />
|
|
<Setter Property="ResourceHeaderContentTemplate" Value="{StaticResource resourceHeaderContentTemplate}" />
|
|
</Style>
|
|
<Style x:Key="radiobutton" TargetType="{x:Type RadioButton}">
|
|
<Setter Property="Margin" Value="3" />
|
|
</Style>
|
|
</ResourceDictionary>
|
|
</UserControl.Resources>
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<GroupBox
|
|
x:Name="groupbox_buchungsplan"
|
|
Header="{markup:Translate Buchungsplan}"
|
|
Style="{StaticResource ObjectEditGroupBox}"
|
|
Visibility="Visible">
|
|
<Grid Margin="3">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="*" />
|
|
<ColumnDefinition Width="auto" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="auto" />
|
|
<RowDefinition Height="*" />
|
|
<RowDefinition Height="auto" />
|
|
</Grid.RowDefinitions>
|
|
<dxlc:LayoutControl
|
|
Name="PART_Options"
|
|
Grid.RowSpan="3"
|
|
Grid.Column="1"
|
|
Margin="3"
|
|
Padding="0"
|
|
dx:ScrollBarExtensions.ScrollBarMode="TouchOverlap"
|
|
Background="Transparent"
|
|
Orientation="Vertical">
|
|
<dxe:DateNavigator
|
|
x:Name="dateNavigator"
|
|
VerticalAlignment="Top"
|
|
dxlc:LayoutControl.AllowVerticalSizing="True"
|
|
Background="Transparent"
|
|
IsMultiSelect="False"
|
|
RowCount="3"
|
|
ShowTodayButton="False"
|
|
ShowWeekNumbers="False">
|
|
<dxe:DateNavigator.StyleSettings>
|
|
<dxsch:SchedulerDateNavigatorStyleSettings
|
|
x:Name="dateNavigatorSettings"
|
|
AllowChangeSchedulerView="False"
|
|
CustomizeSelectedDates="dateNavigatorSettings_CustomizeSelectedDates"
|
|
Scheduler="{Binding ElementName=scheduler_buchungsplan}" />
|
|
</dxe:DateNavigator.StyleSettings>
|
|
</dxe:DateNavigator>
|
|
<dxsch:ResourceTreeControl
|
|
Margin="3,3,-1,-1"
|
|
AllowResourceCreate="False"
|
|
AllowResourceDelete="False"
|
|
Background="Transparent"
|
|
Scheduler="{Binding ElementName=scheduler_buchungsplan}"
|
|
ShowBorder="False" />
|
|
</dxlc:LayoutControl>
|
|
|
|
<StackPanel HorizontalAlignment="Right" Orientation="Horizontal">
|
|
<!--<RadioButton GroupName="schedular_time" Content="Unbegrenzt" IsEnabled="True" Click="{DXEvent '@e(timelineView).IsActive = true'}" Style="{StaticResource radiobutton}"/>-->
|
|
<RadioButton
|
|
x:Name="radioButtonYear"
|
|
Click="{DXEvent '@e(timelineViewYear).IsActive = true'}"
|
|
Content="Jahr"
|
|
GroupName="schedular_time"
|
|
Style="{StaticResource radiobutton}" />
|
|
<RadioButton
|
|
Click="{DXEvent '@e(timelineViewQuartal).IsActive = true'}"
|
|
Content="Quartal"
|
|
GroupName="schedular_time"
|
|
Style="{StaticResource radiobutton}" />
|
|
<RadioButton
|
|
Click="{DXEvent '@e(timelineViewMonth).IsActive = true'}"
|
|
Content="Monat"
|
|
GroupName="schedular_time"
|
|
Style="{StaticResource radiobutton}" />
|
|
<RadioButton
|
|
Click="{DXEvent '@e(timelineView4Week).IsActive = true'}"
|
|
Content="4 Wochen"
|
|
GroupName="schedular_time"
|
|
Style="{StaticResource radiobutton}" />
|
|
<RadioButton
|
|
Click="{DXEvent '@e(timelineViewWeek).IsActive = true'}"
|
|
Content="Wochen"
|
|
GroupName="schedular_time"
|
|
Style="{StaticResource radiobutton}" />
|
|
<RadioButton
|
|
Click="{DXEvent '@e(listview).IsActive = true'}"
|
|
Content="Liste"
|
|
GroupName="schedular_time"
|
|
Style="{StaticResource radiobutton}" />
|
|
</StackPanel>
|
|
<dxsch:SchedulerControl
|
|
x:Name="scheduler_buchungsplan"
|
|
Grid.Row="1"
|
|
Width="auto"
|
|
Height="auto"
|
|
VerticalAlignment="Stretch"
|
|
dx:ThemeManager.ThemeName="Office2010Black"
|
|
ActiveViewChanged="scheduler_ActiveViewChanged"
|
|
ActiveViewIndex="1"
|
|
AllowAppointmentConflicts="False"
|
|
AllowAppointmentCopy="False"
|
|
AllowAppointmentCreate="{Binding Path=WohneinheitBelegungListVM.PermissionWohneinheitBelegungManage}"
|
|
AllowAppointmentDelete="{Binding Path=WohneinheitBelegungListVM.PermissionWohneinheitBelegungManage}"
|
|
AllowAppointmentDrag="False"
|
|
AllowAppointmentDragBetweenResources="False"
|
|
AllowAppointmentEdit="{Binding Path=WohneinheitBelegungListVM.PermissionWohneinheitBelegungManage}"
|
|
AllowAppointmentMultiSelect="False"
|
|
AllowAppointmentResize="False"
|
|
AllowCellMultiSelect="False"
|
|
AllowInplaceEditor="False"
|
|
AllowReminders="False"
|
|
AppointmentWindowShowing="scheduler_buchungsplan_AppointmentWindowShowing"
|
|
FirstDayOfWeek="Monday"
|
|
GroupType="Resource"
|
|
PopupMenuShowing="scheduler_buchungsplan_PopupMenuShowing"
|
|
ShowBorder="False"
|
|
ShowDateNavigationPanel="False">
|
|
<dxsch:SchedulerControl.OptionsWindows>
|
|
<dxsch:OptionsWindows AppointmentWindowType="{x:Type local:WohneinheitBelegungWindow}" />
|
|
</dxsch:SchedulerControl.OptionsWindows>
|
|
<dxsch:SchedulerControl.OptionsContextMenu>
|
|
<dxsch:OptionsContextMenu>
|
|
<dxsch:OptionsContextMenu.AppointmentContextMenuActions>
|
|
<!-- Remove the "Copy" item -->
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Actions_Copy}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Actions_Cut}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Actions_EditSeries}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Actions_Paste}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Actions_RestoreOccurrence}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Options_ShowTimeAs}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Appointment_Options_LabelAs}" />
|
|
</dxsch:OptionsContextMenu.AppointmentContextMenuActions>
|
|
<dxsch:OptionsContextMenu.CellContextMenuActions>
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Cell_Actions_NewAllDayEvent}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Cell_Actions_NewRecurringAppointment}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Cell_Actions_NewRecurringEvent}" />
|
|
<dxb:RemoveAction ElementName="{x:Static Member=dxsch:DefaultBarItemNames.ContextMenu_Items_Cell_Actions_Paste}" />
|
|
</dxsch:OptionsContextMenu.CellContextMenuActions>
|
|
</dxsch:OptionsContextMenu>
|
|
</dxsch:SchedulerControl.OptionsContextMenu>
|
|
|
|
<!--<dxsch:TimelineView x:Name="timelineView" ViewMode="Standard" Style="{StaticResource timelineView.Style}"/>-->
|
|
<dxsch:TimelineView x:Name="timelineViewYear" Style="{StaticResource timelineView.Style}" />
|
|
<dxsch:TimelineView x:Name="timelineViewQuartal" Style="{StaticResource timelineView.Style}" />
|
|
<dxsch:TimelineView x:Name="timelineView4Week" Style="{StaticResource timelineView.Style}" />
|
|
<dxsch:TimelineView x:Name="timelineViewWeek" Style="{StaticResource timelineView.Style}" />
|
|
<dxsch:TimelineView x:Name="timelineViewMonth" Style="{StaticResource timelineView.Style}" />
|
|
|
|
<dxsch:ListView x:Name="listview" />
|
|
<dxsch:SchedulerControl.DataSource>
|
|
<dxsch:DataSource
|
|
AppointmentLabelsSource="{Binding Customers}"
|
|
AppointmentsSource="{Binding WohneinheitBelegungListVM.VMList}"
|
|
ResourcesSource="{Binding WohneinheitListVM.VMList}">
|
|
|
|
<dxsch:DataSource.ResourceMappings>
|
|
<dxsch:ResourceMappings
|
|
Caption="Caption"
|
|
Group="Group"
|
|
Id="Oid" />
|
|
</dxsch:DataSource.ResourceMappings>
|
|
|
|
<dxsch:DataSource.AppointmentLabelMappings>
|
|
<dxsch:AppointmentLabelMappings Caption="VollerName" Id="CustomerOid" />
|
|
</dxsch:DataSource.AppointmentLabelMappings>
|
|
|
|
<dxsch:DataSource.AppointmentMappings>
|
|
<dxsch:AppointmentMappings
|
|
AllDay="AllDay"
|
|
End="EndDateDisplay"
|
|
LabelId="Customer.CustomerOid"
|
|
ResourceId="Wohneinheit.Oid"
|
|
Start="StartDate"
|
|
Subject="Customer.VollerName" />
|
|
</dxsch:DataSource.AppointmentMappings>
|
|
</dxsch:DataSource>
|
|
</dxsch:SchedulerControl.DataSource>
|
|
</dxsch:SchedulerControl>
|
|
</Grid>
|
|
</GroupBox>
|
|
</Grid>
|
|
</UserControl>
|