Mandator Soziotherapie Ansprechpartner + ComboBoxEmployeeSearch + ComboBoxGenericSearch + Formate

This commit is contained in:
2024-11-26 13:57:50 +01:00
parent f9e1c0c995
commit 730555932e
19 changed files with 584 additions and 283 deletions

View File

@@ -391,6 +391,10 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Controls\ComboBoxes\ComboBoxEmployeeSearch.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Controls\CustomerVermittlungArbeitControl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -1301,6 +1305,10 @@
<Compile Include="ViewModel\OrganisationPersonRelationVM.cs" />
<Compile Include="ViewModel\TextModuleVM.cs" />
<Compile Include="ViewModel\VerordnungslistenVM.cs" />
<Compile Include="View\Controls\ComboBoxes\ComboBoxEmployeeSearch.xaml.cs">
<DependentUpon>ComboBoxEmployeeSearch.xaml</DependentUpon>
</Compile>
<Compile Include="View\Controls\ComboBoxes\ComboBoxGenericSearch.cs" />
<Compile Include="View\Controls\CustomerVermittlungArbeitControl.xaml.cs">
<DependentUpon>CustomerVermittlungArbeitControl.xaml</DependentUpon>
</Compile>
@@ -2890,392 +2898,392 @@
<ItemGroup>
<PublishFile Include="Blacklight.Wpf.Controls">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Charts.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Data.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Data.v23.2.Linq">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Office.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.PivotGrid.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Printing.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.RichEdit.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.RichEdit.v23.2.Export">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Sparkline.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Utils.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Accordion.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Charts.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Core.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Docking.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Grid.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Grid.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Layout.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Mvvm.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Printing.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Printing.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Ribbon.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Scheduler.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Themes.LightGray.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Themes.Office2007Black.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Themes.Office2010Black.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Themes.Office2013.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.Xpf.Themes.Office2016White.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraBars.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraCharts.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraEditors.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraNavBar.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraPivotGrid.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraPrinting.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraReports.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraScheduler.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraScheduler.v23.2.Core">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraScheduler.v23.2.Reporting">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
<PublishFile Include="DevExpress.XtraTreeList.v23.2">
<Visible>False</Visible>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<Group>
</Group>
<TargetPath>
</TargetPath>
<PublishState>Include</PublishState>
<IncludeHash>True</IncludeHash>
<FileType>Assembly</FileType>
</PublishFile>
</ItemGroup>

View File

@@ -12,7 +12,7 @@ namespace BeWo.Converter
if (value is null)
return null;
return "Test";
return value;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)

View File

@@ -117,7 +117,7 @@ namespace BeWo
{
DebugConfigMode = DebugConfigMode.FeatureDakota,
AutoLogin = true,
SelectView = UIContext.Finance,
SelectView = UIContext.Administration,
SelectIndex = 8,
//Username = "m1",
//Password = "bewobewo",

View File

@@ -51,7 +51,8 @@ namespace BeWo
Vertretungen,
CustomerTeam,
Scheduling,
Finance
Finance,
Administration
}
public partial class MainControl
@@ -246,6 +247,9 @@ namespace BeWo
private BeWoView GetViewForUIContext(UIContext uiContext)
{
if (uiContext == UIContext.Administration)
return new AdministrationView();
if (!_Views.ContainsKey(uiContext))
{
BeWoView view = null;
@@ -913,7 +917,7 @@ namespace BeWo
{
if (DoSaveCheck())
{
NavigateTo(new AdministrationView());
NavigateTo(GetViewForUIContext(UIContext.Administration));
}
}

View File

@@ -2515,7 +2515,7 @@
x:Name="PART_NewButton"
Grid.Column="2"
Width="{Binding Path=ActualHeight, RelativeSource={RelativeSource Self}}"
Height="20"
Height="18"
Margin="1,0,1,0"
Padding="0"
VerticalAlignment="Stretch"
@@ -2537,7 +2537,7 @@
x:Name="PART_DeleteButton"
Grid.Column="3"
Width="{Binding Path=ActualHeight, RelativeSource={RelativeSource Self}}"
Height="20"
Height="18"
Margin="1,0,1,0"
Padding="0"
VerticalAlignment="Stretch"

View File

@@ -0,0 +1,31 @@
<local:ComboBoxGenericSearch
x:Class="BeWo.View.Controls.ComboBoxes.ComboBoxEmployeeSearch"
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:local="clr-namespace:BeWo.View.Controls.ComboBoxes"
xmlns:localSearchView="clr-namespace:BeWo.View.Search"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:uc="clr-namespace:BeWo.Controls;assembly=BeWo.Controls"
x:Name="root"
d:DesignWidth="200"
mc:Ignorable="d">
<Grid>
<uc:PopUpEdit
x:Name="popupedit"
MinHeight="23"
DeleteButtonVisibility="Visible"
IsReadOnly="True"
PopUpClick="popupedit_PopUpClick"
DeleteClick="popupedit_DeleteClick"/>
<Popup
x:Name="popup"
Width="370"
Height="250"
Margin="10"
Placement="MousePoint"
StaysOpen="False">
<localSearchView:EmployeeSearchView x:Name="searchview" />
</Popup>
</Grid>
</local:ComboBoxGenericSearch>

View File

@@ -0,0 +1,85 @@
using BeWo.View.Search;
using BS.Shared.Core;
using BS.Shared.DataContracts.Compact;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace BeWo.View.Controls.ComboBoxes
{
/// <summary>
/// Interaktionslogik für ComboBoxEmployeeSearch.xaml
/// </summary>
public partial class ComboBoxEmployeeSearch : ComboBoxGenericSearch
{
// Using a DependencyProperty as the backing store for SelectedCompactEmployeeDC. This enables animation, styling, binding, etc...
public static readonly DependencyProperty SelectedCompactEmployeeDCProperty =
DependencyProperty.Register("SelectedCompactEmployeeDC",
typeof(CompactEmployeeDC),
typeof(ComboBoxEmployeeSearch),
new UIPropertyMetadata(null,
selectCompactEmployee2));
public CompactEmployeeDC SelectedCompactEmployeeDC
{
get { return (CompactEmployeeDC)GetValue(SelectedCompactEmployeeDCProperty); }
set { SetValue(SelectedCompactEmployeeDCProperty, value); }
}
static ComboBoxEmployeeSearch()
{
SearchModeProperty.OverrideMetadata(typeof(ComboBoxEmployeeSearch), new UIPropertyMetadata(SearchMode.All, updateSearchMode));
}
public ComboBoxEmployeeSearch()
{
InitializeComponent();
}
private void popupedit_PopUpClick(object sender, EventArgs e)
{
searchview.ItemSelected += searchview_Selected;
popup.IsOpen = true;
}
private void searchview_Selected(object sender, EventArgs<CompactEmployeeDC> e)
{
popup.IsOpen = false;
searchview.ItemSelected -= searchview_Selected;
SelectedCompactEmployeeDC = e.Data;
popupedit.Focus();
}
private static void selectCompactEmployee2(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
var control = d as ComboBoxEmployeeSearch;
control.popupedit.Text = e.NewValue?.ToString();
}
private static void updateSearchMode(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
var control = d as ComboBoxEmployeeSearch;
control.searchview.SearchMode = (SearchMode)e.NewValue;
}
private void popupedit_DeleteClick(object sender, RoutedEventArgs e)
{
SelectedCompactEmployeeDC = null;
}
}
}

View File

@@ -0,0 +1,34 @@
using BeWo.View.Search;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
namespace BeWo.View.Controls.ComboBoxes
{
public class ComboBoxGenericSearch : UserControl
{
// Using a DependencyProperty as the backing store for DeleteButtonVisibility. This enables animation, styling, binding, etc...
public static readonly DependencyProperty DeleteButtonVisibilityProperty =
DependencyProperty.Register("DeleteButtonVisibility", typeof(Visibility), typeof(ComboBoxGenericSearch), new PropertyMetadata(null));
// Using a DependencyProperty as the backing store for MyProperty. This enables animation, styling, binding, etc...
public static readonly DependencyProperty SearchModeProperty =
DependencyProperty.Register("SearchMode", typeof(SearchMode), typeof(ComboBoxGenericSearch), new UIPropertyMetadata(SearchMode.All));
public Visibility DeleteButtonVisibility
{
get { return (Visibility)GetValue(DeleteButtonVisibilityProperty); }
set { SetValue(DeleteButtonVisibilityProperty, value); }
}
public SearchMode SearchMode
{
get { return (SearchMode)GetValue(SearchModeProperty); }
set { SetValue(SearchModeProperty, value); }
}
}
}

View File

@@ -1,26 +1,46 @@
<UserControl x:Class="BeWo.View.Controls.ListboxSelectControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:validation="clr-namespace:BeWo.Validation"
xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
mc:Ignorable="d"
d:DesignHeight="230" d:DesignWidth="300">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<ListBox x:Name="Listbox" Grid.ColumnSpan="3" Margin="3, 3, 3, 0" SelectionMode="Single" FontSize="14" MouseDoubleClick="Listbox_OnMouseDoubleClick"/>
<Button x:Name="SelectButton" Grid.Row="1" Grid.Column="1" Content=" Auswählen " Margin="3" Click="SelectButton_Click"/>
<Button x:Name="CancelButton" Grid.Row="1" Grid.Column="2" Content=" Abbrechen " Margin="3" Click="CancelButton_Click"/>
</Grid>
<UserControl
x:Class="BeWo.View.Controls.ListboxSelectControl"
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:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:validation="clr-namespace:BeWo.Validation"
d:DesignHeight="230"
d:DesignWidth="300"
mc:Ignorable="d">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<ListBox
x:Name="Listbox"
Grid.ColumnSpan="3"
Margin="3,3,3,0"
FontSize="14"
MouseDoubleClick="Listbox_OnMouseDoubleClick"
SelectionMode="Single" />
<Button
x:Name="SelectButton"
Grid.Row="1"
Grid.Column="1"
Margin="3"
Click="SelectButton_Click"
Content=" Auswählen " />
<Button
x:Name="CancelButton"
Grid.Row="1"
Grid.Column="2"
Margin="3"
Click="CancelButton_Click"
Content=" Abbrechen " />
</Grid>
</UserControl>

View File

@@ -2,6 +2,7 @@
x:Class="BeWo.View.Detail.MandatorView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:comboboxes="clr-namespace:BeWo.View.Controls.ComboBoxes"
xmlns:core="clr-namespace:BS.Shared.Core;assembly=BS.Shared"
xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
@@ -217,10 +218,45 @@
Text="{Binding Path=IBAN, UpdateSourceTrigger=PropertyChanged}" />
</Grid>
</GroupBox>
<GroupBox
x:Name="groupBoxSozio"
Grid.Row="3"
Grid.ColumnSpan="2"
Margin="3,20,3,3"
Header="Soziotherapie"
Style="{StaticResource ObjectEditGroupBox}"
Visibility="{Binding Path=Itself, Converter={StaticResource UserPermission2BoolConverter}, ConverterParameter={x:Static core:SettingsKeys.AllowGkvAbrechnung}}">
<!-- Kann frei genutzt werden -->
<Grid ToolTip="Wenn kein Ansprechpartner hinterlegt ist, so wird der aktuelle Benutzer als Ansprechpartner verwendet.">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" SharedSizeGroup="g1" />
<ColumnDefinition Width="200" />
</Grid.ColumnDefinitions>
<Label
Grid.Row="0"
Grid.Column="0"
Margin="3"
VerticalAlignment="Center">
Ansprechpartner
</Label>
<comboboxes:ComboBoxEmployeeSearch
Grid.Row="0"
Grid.Column="1"
Margin="3"
Height="24"
SelectedCompactEmployeeDC="{Binding SoziotherapieAnsprechpartner, Mode=TwoWay}" />
</Grid>
</GroupBox>
<GroupBox
Grid.Row="4"
Grid.ColumnSpan="2"
Margin="3,20,3,3"
Header="Anwendungseinstellungen"
Style="{StaticResource ObjectEditGroupBox}">
<Grid x:Name="EinstellungenGrid">
@@ -312,7 +348,7 @@
</GroupBox>
<GroupBox
Grid.Row="4"
Grid.Row="5"
Grid.ColumnSpan="2"
Margin="3,20,3,3"
Header="{markup:Translate Zeiterfassung}"
@@ -474,7 +510,7 @@
</GroupBox>
<GroupBox
Grid.Row="5"
Grid.Row="6"
Grid.ColumnSpan="2"
Margin="3,20,3,3"
Header="Rechnungsnummer"
@@ -576,26 +612,6 @@
</Grid>
</GroupBox>
<GroupBox
x:Name="groupBoxSozio"
Grid.Row="6"
Grid.ColumnSpan="2"
Margin="3,20,3,3"
Header="Soziotherapie"
Style="{StaticResource ObjectEditGroupBox}"
Visibility="Collapsed">
<!-- Kann frei genutzt werden -->
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
</Grid>
</GroupBox>
<GroupBox
x:Name="GroupOwnChatSettings"
Grid.Row="7"

View File

@@ -9,7 +9,11 @@ namespace BeWo.View.Detail.Report
{
public partial class SupportConceptAnalysisListViewItem : UserControl
{
public static readonly DependencyProperty OverviewItemProperty = DependencyProperty.Register("OverviewItem", typeof(KeyValuePair<string, List<SupportConceptOverviewDC>>), typeof(SupportConceptAnalysisListViewItem), new UIPropertyMetadata(new KeyValuePair<string, List<SupportConceptOverviewDC>>(), (s, e) => ((SupportConceptAnalysisListViewItem)s).DataContext = e.NewValue));
public static readonly DependencyProperty OverviewItemProperty = DependencyProperty.Register("OverviewItem",
typeof(KeyValuePair<string, List<SupportConceptOverviewDC>>),
typeof(SupportConceptAnalysisListViewItem),
new UIPropertyMetadata(new KeyValuePair<string, List<SupportConceptOverviewDC>>(),
(s, e) => ((SupportConceptAnalysisListViewItem)s).DataContext = e.NewValue));
public SupportConceptAnalysisListViewItem()
{

View File

@@ -17,7 +17,6 @@ namespace BeWo.View.Search
{
public class GenericSearchView<T> : UserControl where T : class, IFilterableDC
{
private readonly ListBox _ResultListBox;
private readonly Grid _Root;

View File

@@ -1,95 +1,166 @@
<UserControl x:Class="BeWo.View.Search.MultiEmployeeSearch"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:converter="clr-namespace:BeWo.Scheduler.Converter"
mc:Ignorable="d" d:DesignHeight="300" d:DesignWidth="300">
<UserControl.Resources>
<converter:CheckBoxConverter x:Key="CheckBoxConverter" />
</UserControl.Resources>
<UserControl
x:Class="BeWo.View.Search.MultiEmployeeSearch"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:converter="clr-namespace:BeWo.Scheduler.Converter"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
d:DesignHeight="300"
d:DesignWidth="300"
mc:Ignorable="d">
<UserControl.Resources>
<converter:CheckBoxConverter x:Key="CheckBoxConverter" />
</UserControl.Resources>
<Grid Background="Black">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Label Content="Suche:" Grid.Column="0" Grid.Row="0" Margin="3" Foreground="#FFD2D2D2" VerticalAlignment="Center" />
<TextBox x:Name="SuchTextBox" Grid.Column="1" Grid.Row="0" Margin="0,3,3,3" TextChanged="SuchTextBox_OnPreviewKeyDown" />
<ListBox Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="1" x:Name="listbox_result" ItemsSource="{Binding Path=AngezeigteMitarbeiter, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}" HorizontalContentAlignment="Stretch" BorderThickness="0" Margin="2">
<ListBox.ItemTemplate>
<DataTemplate>
<Grid>
<Border CornerRadius="5" MinHeight="23" Background="{StaticResource EmployeeContentBrush}" Margin="0,1,3,1" />
<Border x:Name="ItemBorder" CornerRadius="5" MinHeight="23" Background="#FF000000" Margin="0,1,3,1">
<Border.OpacityMask>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#19000000" Offset="0" />
<GradientStop Color="#26000000" Offset="1" />
</LinearGradientBrush>
</Border.OpacityMask>
</Border>
<Border BorderBrush="{x:Null}" Height="23" CornerRadius="5">
<CheckBox Margin="6,0,0,0" VerticalAlignment="Center" Foreground="#FFD2D2D2" FontFamily="Microsoft Sans Serif" Tag="{Binding}" Content="{Binding Path=DetailDescription}" Checked="EmployeeCheckedEvent" Unchecked="EmployeeCheckedEvent" PreviewMouseDown="EmployeeLB_OnClick">
<CheckBox.IsChecked>
<MultiBinding Converter="{StaticResource CheckBoxConverter}" ConverterParameter="Mitarbeiter" UpdateSourceTrigger="PropertyChanged" NotifyOnSourceUpdated="True">
<Binding Path="EmployeeOid" Mode="OneWay" />
<Binding Path="AusgewaehlteMitarbeiter" Mode="TwoWay" UpdateSourceTrigger="PropertyChanged" RelativeSource="{RelativeSource FindAncestor, AncestorType={x:Type UserControl}}" />
</MultiBinding>
</CheckBox.IsChecked>
</CheckBox>
</Border>
</Grid>
<DataTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="OpacityMask" TargetName="ItemBorder">
<Setter.Value>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#33000000" Offset="0" />
<GradientStop Color="#66000000" Offset="1" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Trigger>
<Trigger Property="ListBoxItem.IsSelected" Value="True">
<Setter Property="OpacityMask" TargetName="ItemBorder">
<Setter.Value>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#99000000" Offset="0" />
<GradientStop Color="#CC000000" Offset="1" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Trigger>
<MultiTrigger>
<MultiTrigger.Conditions>
<Condition Property="ListBoxItem.IsSelected" Value="True" />
<Condition Property="Selector.IsSelectionActive" Value="False" />
</MultiTrigger.Conditions>
<Setter Property="OpacityMask" TargetName="ItemBorder">
<Setter.Value>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#99000000" Offset="0" />
<GradientStop Color="#B2000000" Offset="1" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</MultiTrigger>
</DataTemplate.Triggers>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
<Grid Grid.Row="2" Grid.Column="0" Grid.ColumnSpan="2">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<CheckBox HorizontalAlignment="Left" VerticalAlignment="Center" Margin="12,3,3,3" Foreground="#FFD2D2D2" Grid.Column="0" Content="Alle auswählen" Checked="AlleSelektierenCBUnChecked" Unchecked="AlleSelektierenCBUnChecked" IsThreeState="False" />
<Button HorizontalAlignment="Right" Grid.Column="1" Margin="3" Content="Schließen" Width="70" Height="25" Command="ApplicationCommands.Close" />
</Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Label
Grid.Row="0"
Grid.Column="0"
Margin="3"
VerticalAlignment="Center"
Content="Suche:"
Foreground="#FFD2D2D2" />
<TextBox
x:Name="SuchTextBox"
Grid.Row="0"
Grid.Column="1"
Margin="0,3,3,3"
TextChanged="SuchTextBox_OnPreviewKeyDown" />
<ListBox
x:Name="listbox_result"
Grid.Row="1"
Grid.Column="0"
Grid.ColumnSpan="2"
Margin="2"
HorizontalContentAlignment="Stretch"
BorderThickness="0"
ItemsSource="{Binding Path=AngezeigteMitarbeiter, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}">
<ListBox.ItemTemplate>
<DataTemplate>
<Grid>
<Border
MinHeight="23"
Margin="0,1,3,1"
Background="{StaticResource EmployeeContentBrush}"
CornerRadius="5" />
<Border
x:Name="ItemBorder"
MinHeight="23"
Margin="0,1,3,1"
Background="#FF000000"
CornerRadius="5">
<Border.OpacityMask>
<LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
<GradientStop Offset="0" Color="#19000000" />
<GradientStop Offset="1" Color="#26000000" />
</LinearGradientBrush>
</Border.OpacityMask>
</Border>
<Border
Height="23"
BorderBrush="{x:Null}"
CornerRadius="5">
<CheckBox
Margin="6,0,0,0"
VerticalAlignment="Center"
Checked="EmployeeCheckedEvent"
Content="{Binding Path=DetailDescription}"
FontFamily="Microsoft Sans Serif"
Foreground="#FFD2D2D2"
PreviewMouseDown="EmployeeLB_OnClick"
Tag="{Binding}"
Unchecked="EmployeeCheckedEvent">
<CheckBox.IsChecked>
<MultiBinding
Converter="{StaticResource CheckBoxConverter}"
ConverterParameter="Mitarbeiter"
NotifyOnSourceUpdated="True"
UpdateSourceTrigger="PropertyChanged">
<Binding Mode="OneWay" Path="EmployeeOid" />
<Binding
Mode="TwoWay"
Path="AusgewaehlteMitarbeiter"
RelativeSource="{RelativeSource FindAncestor,
AncestorType={x:Type UserControl}}"
UpdateSourceTrigger="PropertyChanged" />
</MultiBinding>
</CheckBox.IsChecked>
</CheckBox>
</Border>
</Grid>
<DataTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="ItemBorder" Property="OpacityMask">
<Setter.Value>
<LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
<GradientStop Offset="0" Color="#33000000" />
<GradientStop Offset="1" Color="#66000000" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Trigger>
<Trigger Property="ListBoxItem.IsSelected" Value="True">
<Setter TargetName="ItemBorder" Property="OpacityMask">
<Setter.Value>
<LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
<GradientStop Offset="0" Color="#99000000" />
<GradientStop Offset="1" Color="#CC000000" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Trigger>
<MultiTrigger>
<MultiTrigger.Conditions>
<Condition Property="ListBoxItem.IsSelected" Value="True" />
<Condition Property="Selector.IsSelectionActive" Value="False" />
</MultiTrigger.Conditions>
<Setter TargetName="ItemBorder" Property="OpacityMask">
<Setter.Value>
<LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
<GradientStop Offset="0" Color="#99000000" />
<GradientStop Offset="1" Color="#B2000000" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</MultiTrigger>
</DataTemplate.Triggers>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
<Grid
Grid.Row="2"
Grid.Column="0"
Grid.ColumnSpan="2">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<CheckBox
Grid.Column="0"
Margin="12,3,3,3"
HorizontalAlignment="Left"
VerticalAlignment="Center"
Checked="AlleSelektierenCBUnChecked"
Content="Alle auswählen"
Foreground="#FFD2D2D2"
IsThreeState="False"
Unchecked="AlleSelektierenCBUnChecked" />
<Button
Grid.Column="1"
Width="70"
Height="25"
Margin="3"
HorizontalAlignment="Right"
Command="ApplicationCommands.Close"
Content="Schließen" />
</Grid>
</Grid>
</UserControl>

View File

@@ -6,6 +6,7 @@ using BS.Shared.DataContracts;
using BS.Shared.Extensions;
using BeWo.Core;
using BS.Shared.Core;
using BS.Shared.DataContracts.Compact;
namespace BeWo.ViewModel
{
@@ -49,6 +50,7 @@ namespace BeWo.ViewModel
private string _BankCode;
private string _Bic;
private string _IBAN;
private CompactEmployeeDC _SoziotherapieAnsprechpartner;
public MandatorVM(IList<InvoiceNumberVM> invoiceNumberList, MandatorDC pDC) : base(pDC, true)
{
@@ -545,6 +547,21 @@ namespace BeWo.ViewModel
}
}
public CompactEmployeeDC SoziotherapieAnsprechpartner
{
get { return _SoziotherapieAnsprechpartner; }
set
{
if (!AreDifferent(SoziotherapieAnsprechpartner, value))
return;
_SoziotherapieAnsprechpartner = value;
StoreDirtyInformation(AreDifferent(DataContract.SoziotherapieAnsprechpartner, value), nameof(SoziotherapieAnsprechpartner));
FirePropertyChanged(nameof(SoziotherapieAnsprechpartner));
}
}
public bool CanEditIKLeistungserbringer { get; set; }
public string CanEditIKLeistungserbringerTooltip { get; set; }
@@ -568,6 +585,7 @@ namespace BeWo.ViewModel
_IBAN = pDataContract.BankAccount.IBAN;
CanEditIKLeistungserbringer = pDataContract.CanEditIKLeistungserbringer;
CanEditIKLeistungserbringerTooltip = pDataContract.CanEditIKLeistungserbringerTooltip;
_SoziotherapieAnsprechpartner = pDataContract.SoziotherapieAnsprechpartner;
if (_Settings == null)
{
@@ -628,6 +646,7 @@ namespace BeWo.ViewModel
pDataContract.BankAccount.BankName = BankName;
pDataContract.BankAccount.Bic = Bic;
pDataContract.BankAccount.IBAN = IBAN;
pDataContract.SoziotherapieAnsprechpartner = SoziotherapieAnsprechpartner;
return pDataContract;
}

View File

@@ -365,6 +365,7 @@ namespace BeWo.Data.Entities
}
}
public virtual BankAccount BankAccount { get; set; }
public virtual Employee SoziotherapieAnsprechpartner { get; set; }
protected virtual string GetSettingValue(string key)
{

View File

@@ -29,5 +29,6 @@
<property column="ApiKey" type="String" name="Apikey" length="256" />
<property column="IKLeistungserbringer" type="String" name="IKLeistungserbringer" length="16" />
<many-to-one name="BankAccount" column="BankAccountOid" class="BeWo.Data.Entities.BankAccount,BeWo.Data" cascade="all-delete-orphan" fetch="join"/>
<many-to-one name="SoziotherapieAnsprechpartner" column="SoziotherapieAnsprechpartnerOid" class="BeWo.Data.Entities.Employee,BeWo.Data" cascade="all-delete-orphan" fetch="join"/>
</class>
</hibernate-mapping>

View File

@@ -0,0 +1,2 @@
ALTER TABLE `mandator`
ADD COLUMN `SoziotherapieAnsprechpartnerOid` BIGINT NULL DEFAULT NULL AFTER `BankAccountOid`;

View File

@@ -6,93 +6,97 @@ using System;
namespace BeWo.Service.DCEntityMapper
{
public class MandatorDC_Mandator : AbstractIDCEntityMapper<Mandator, MandatorDC>
{
public override MandatorDC MergeWithDC(Mandator pEntity, MandatorDC pDataContract)
{
pDataContract.MandatorOid = pEntity.Oid;
pDataContract.MandatorVersion = pEntity.Version;
pDataContract.Name = pEntity.Name;
pDataContract.ClientId = pEntity.ClientId;
pDataContract.BeWoClientType = pEntity.BeWoClientType;
pDataContract.Country = pEntity.Country;
pDataContract.State = pEntity.State;
pDataContract.Town = pEntity.Town;
pDataContract.PostalCode = pEntity.PostalCode;
pDataContract.Street = pEntity.Street;
pDataContract.Settings = pEntity.Settings;
public class MandatorDC_Mandator : AbstractIDCEntityMapper<Mandator, MandatorDC>
{
public override MandatorDC MergeWithDC(Mandator pEntity, MandatorDC pDataContract)
{
pDataContract.MandatorOid = pEntity.Oid;
pDataContract.MandatorVersion = pEntity.Version;
pDataContract.Name = pEntity.Name;
pDataContract.ClientId = pEntity.ClientId;
pDataContract.BeWoClientType = pEntity.BeWoClientType;
pDataContract.Country = pEntity.Country;
pDataContract.State = pEntity.State;
pDataContract.Town = pEntity.Town;
pDataContract.PostalCode = pEntity.PostalCode;
pDataContract.Street = pEntity.Street;
pDataContract.Settings = pEntity.Settings;
pDataContract.RssFeedUrl = pEntity.RssFeedUrl;
pDataContract.IsSchedulerAllowed = pEntity.IsSchedulerAllowed;
pDataContract.IsMedicationAllowed = pEntity.IsMedicationAllowed;
pDataContract.BankAccount = MapperFactory.BankAccountDC_BankAccount.MapToNewDC(pEntity.BankAccount, false);
pDataContract.BankAccount = MapperFactory.BankAccountDC_BankAccount.MapToNewDC(pEntity.BankAccount, false);
pDataContract.AllowSbd = !string.IsNullOrEmpty(pDataContract.ClientId) && pDataContract.ClientId == "SBD";
pDataContract.AllowSbd = !string.IsNullOrEmpty(pDataContract.ClientId) && pDataContract.ClientId == "SBD";
#if DEBUG
//pDataContract.AllowSbd = true;
//pDataContract.AllowSbd = true;
#endif
pDataContract.Apikey = pEntity.Apikey;
pDataContract.IKLeistungserbringer = pEntity.IKLeistungserbringer;
var can_edit = GetCanEditIKLeistungserbringer();
pDataContract.Apikey = pEntity.Apikey;
pDataContract.IKLeistungserbringer = pEntity.IKLeistungserbringer;
var can_edit = GetCanEditIKLeistungserbringer();
pDataContract.CanEditIKLeistungserbringer = can_edit;
pDataContract.CanEditIKLeistungserbringerTooltip = can_edit ? null :
"Mit dem Senden mind. einer GKV Abrechnung haben Sie sich bereits\n" +
"mit dieser IK bei uns registiert. Bei Änderungswunsch wenden Sie\n" +
"sich bitte an unseren Support.";
pDataContract.CanEditIKLeistungserbringer = can_edit;
pDataContract.CanEditIKLeistungserbringerTooltip = can_edit ? null :
"Mit dem Senden mind. einer GKV Abrechnung haben Sie sich bereits\n" +
"mit dieser IK bei uns registiert. Bei Änderungswunsch wenden Sie\n" +
"sich bitte an unseren Support.";
return pDataContract;
}
if (pEntity.SoziotherapieAnsprechpartner is object)
pDataContract.SoziotherapieAnsprechpartner = MapperFactory.CompactEmployeeDC_Employee.MapToNewDC(pEntity.SoziotherapieAnsprechpartner);
public override Mandator MergeWithEntity(MandatorDC pDataContract, Mandator pEntity)
{
this.ConcurrencyCheck(pDataContract.MandatorVersion, pEntity);
return pDataContract;
}
pEntity.Name = pDataContract.Name;
pEntity.ClientId = pDataContract.ClientId;
pEntity.BeWoClientType = pDataContract.BeWoClientType;
pEntity.Country = pDataContract.Country;
pEntity.State = pDataContract.State;
pEntity.Town = pDataContract.Town;
pEntity.PostalCode = pDataContract.PostalCode;
pEntity.Street = pDataContract.Street;
pEntity.Settings = pDataContract.Settings;
public override Mandator MergeWithEntity(MandatorDC pDataContract, Mandator pEntity)
{
this.ConcurrencyCheck(pDataContract.MandatorVersion, pEntity);
pEntity.Name = pDataContract.Name;
pEntity.ClientId = pDataContract.ClientId;
pEntity.BeWoClientType = pDataContract.BeWoClientType;
pEntity.Country = pDataContract.Country;
pEntity.State = pDataContract.State;
pEntity.Town = pDataContract.Town;
pEntity.PostalCode = pDataContract.PostalCode;
pEntity.Street = pDataContract.Street;
pEntity.Settings = pDataContract.Settings;
pEntity.RssFeedUrl = pDataContract.RssFeedUrl;
pEntity.IsSchedulerAllowed = pDataContract.IsSchedulerAllowed;
pEntity.IsMedicationAllowed = pDataContract.IsMedicationAllowed;
pEntity.Apikey = pDataContract.Apikey;
pEntity.IKLeistungserbringer = pDataContract.IKLeistungserbringer;
pEntity.Apikey = pDataContract.Apikey;
pEntity.IKLeistungserbringer = pDataContract.IKLeistungserbringer;
pEntity.BankAccount = MapperFactory.BankAccountDC_BankAccount.MergeWithEntity(pDataContract.BankAccount, pEntity.BankAccount, false);
pEntity.BankAccount = MapperFactory.BankAccountDC_BankAccount.MergeWithEntity(pDataContract.BankAccount, pEntity.BankAccount, false);
pEntity.SoziotherapieAnsprechpartner = MapperFactory.CompactEmployeeDC_Employee.MergeWithEntity(pDataContract.SoziotherapieAnsprechpartner, pEntity.SoziotherapieAnsprechpartner, false);
return pEntity;
}
return pEntity;
}
protected override bool AreDCAndEntityEqual(MandatorDC pDC, Mandator pEntity)
{
if (pDC.MandatorOid == null)
{
return false;
}
protected override bool AreDCAndEntityEqual(MandatorDC pDC, Mandator pEntity)
{
if (pDC.MandatorOid == null)
{
return false;
}
return pDC.MandatorOid == pEntity.Oid;
}
return pDC.MandatorOid == pEntity.Oid;
}
private bool GetCanEditIKLeistungserbringer()
private bool GetCanEditIKLeistungserbringer()
{
try
{
var row_count = DAOFactory.GenericDAO.GetRowCount<GkvTransferProtokoll>();
var row_count = DAOFactory.GenericDAO.GetRowCount<GkvTransferProtokoll>();
return row_count == 0;
return row_count == 0;
}
catch (Exception)
{
}
return true;
return true;
}
}
}
}

View File

@@ -1,3 +1,4 @@
using BS.Shared.DataContracts.Compact;
using BS.Shared.DataContracts.Invoicing;
using System.Runtime.Serialization;
@@ -27,5 +28,6 @@ namespace BS.Shared.DataContracts
[DataMember] public string IKLeistungserbringer { get; set; }
[DataMember] public bool CanEditIKLeistungserbringer { get; set; }
[DataMember] public string CanEditIKLeistungserbringerTooltip { get; set; }
[DataMember] public CompactEmployeeDC SoziotherapieAnsprechpartner { get; set; }
}
}