diff --git a/BeWo/BeWo.csproj b/BeWo/BeWo.csproj
index 3f072212f..cfa8545f2 100644
--- a/BeWo/BeWo.csproj
+++ b/BeWo/BeWo.csproj
@@ -2346,6 +2346,7 @@
Designer
+
SettingsSingleFileGenerator
Settings.Designer.cs
@@ -2481,392 +2482,392 @@
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
False
- Include
- True
+ Include
+ True
Assembly
diff --git a/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml b/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml
index 2313a9665..758fa4250 100644
--- a/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml
+++ b/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml
@@ -291,7 +291,8 @@
+ Height="23" MinWidth="80" Margin="3" EditValue="{Binding Controller.DisplayStartDate}" x:Name="StartDateDateEdit"
+ EditValueChanged="StartDate_OnChange" />
@@ -301,7 +302,8 @@
+ Margin="3" EditValue="{Binding Controller.DisplayEndDate}" x:Name="EndDate"
+ EditValueChanged="EndDate_OnChange" />
diff --git a/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml.cs b/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml.cs
index 6b8ac8aaf..7e02b8c4c 100644
--- a/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml.cs
+++ b/BeWo/Scheduler/View/SchedulerAppointmentEditForm.xaml.cs
@@ -3,7 +3,6 @@ using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Collections.Specialized;
using System.ComponentModel;
-using System.Diagnostics;
using System.Globalization;
using System.Linq;
using System.Windows;
@@ -23,7 +22,6 @@ using BS.Shared.Core;
using BS.Shared.DataContracts;
using BS.Shared.DataContracts.Compact;
using BS.Shared.Extensions;
-using DevExpress.Mvvm.Native;
using DevExpress.Xpf.Editors;
using DevExpress.Xpf.Scheduler.UI;
using DevExpress.XtraScheduler;
@@ -474,7 +472,6 @@ namespace BeWo.Scheduler.View
var employeeOids = new List();
var customerOids = new List();
- var overlaps = false;
foreach (var emp in employees)
{
@@ -488,22 +485,23 @@ namespace BeWo.Scheduler.View
var item = (SchedulerAppointmentVM) Appointment.GetSourceObject(Control.GetCoreStorage());
- //if(!IsInTaskViewMode){
- // ServiceFacade.DoResourceServiceSync(definedBelow => overlaps = definedBelow.OverlappingAppointmentsExist(Appointment.Start, Appointment.End, employeeOids, customerOids, resources.Select(res => res.ResourceOid.Value).ToList(), ViewModel.NewVM.Originator.EmployeeOid, item?.CommitToDataContract().SchedulerAppointmentOid, string.Empty, Appointment.RecurrenceIndex));
+ //var overlaps = false;
+ //if(!IsInTaskViewMode){
+ // ServiceFacade.DoResourceServiceSync(definedBelow => overlaps = definedBelow.OverlappingAppointmentsExist(Appointment.Start, Appointment.End, employeeOids, customerOids, resources.Select(res => res.ResourceOid.Value).ToList(), ViewModel.NewVM.Originator.EmployeeOid, item?.CommitToDataContract().SchedulerAppointmentOid, string.Empty, Appointment.RecurrenceIndex));
- // if (overlaps)
- // {
- // var erg = MessageBox.Show("Dieser Termin überschneidet sich mit einem anderen bereits existierenden Termin.\n Möchten Sie ihn wirklich speichern?", "Überschneidung", MessageBoxButton.YesNo, MessageBoxImage.Exclamation);
+ // if (overlaps)
+ // {
+ // var erg = MessageBox.Show("Dieser Termin überschneidet sich mit einem anderen bereits existierenden Termin.\n Möchten Sie ihn wirklich speichern?", "Überschneidung", MessageBoxButton.YesNo, MessageBoxImage.Exclamation);
- // if (erg.Equals(MessageBoxResult.No))
- // {
- // Controller.Storage.EndUpdate();
- // return;
- // }
- // }
- //}
+ // if (erg.Equals(MessageBoxResult.No))
+ // {
+ // Controller.Storage.EndUpdate();
+ // return;
+ // }
+ // }
+ //}
- ViewModel.ShouldLockOverlappingAppointmentCheck = Appointment.Type == AppointmentType.ChangedOccurrence;
+ ViewModel.ShouldLockOverlappingAppointmentCheck = Appointment.Type == AppointmentType.ChangedOccurrence;
if (Appointment.RecurrenceInfo != null)
{
@@ -680,39 +678,40 @@ namespace BeWo.Scheduler.View
private void AllDay_OnCheckedChange(object sender, RoutedEventArgs e)
{
- var source = (CheckEdit) e.Source;
- var value = source.IsChecked ?? false;
+ //var source = (CheckEdit)e.Source;
+ //var value = source.IsChecked ?? false;
- if(value == false && _HasBeenUnchecked == false)
- {
- var displayStart = NewSchedulerAppointmentFormController.DisplayStart;
- var start = NewSchedulerAppointmentFormController.Start;
- var end = NewSchedulerAppointmentFormController.End;
+ //if(value == false && _HasBeenUnchecked == false)
+ //{
+ // var displayStart = NewSchedulerAppointmentFormController.DisplayStart;
+ // var start = NewSchedulerAppointmentFormController.Start;
+ // var end = NewSchedulerAppointmentFormController.End;
- if(!end.Equals(start))
- {
- _HasBeenUnchecked = true;
+ // if(!end.Equals(start))
+ // {
+ // _HasBeenUnchecked = true;
- var day = displayStart.Day;
- var month = displayStart.Month;
- var year = displayStart.Year;
+ // var day = displayStart.Day;
+ // var month = displayStart.Month;
+ // var year = displayStart.Year;
- var newEndDay = (end.AddDays(-1) >= start ? end.AddDays(-1) : start).Day;
+ // var newEndDay = (end.AddDays(-1) >= start ? end.AddDays(-1) : start).Day;
- var newStart = new DateTime(year, month, day, 0, 0, 0);
- var newEnd = new DateTime(year, month, newEndDay, 1, 0, 0);
+ // var newStart = new DateTime(year, month, day, 0, 0, 0);
+ // var newEnd = new DateTime(year, month, newEndDay, 1, 0, 0);
- NewSchedulerAppointmentFormController.Start = newStart;
- NewSchedulerAppointmentFormController.End = newEnd;
+ // NewSchedulerAppointmentFormController.Start = newStart;
+ // NewSchedulerAppointmentFormController.End = newEnd;
- NewSchedulerAppointmentFormController.DisplayStart = newStart;
- NewSchedulerAppointmentFormController.DisplayEnd = newEnd;
+ // NewSchedulerAppointmentFormController.DisplayStart = newStart;
+ // NewSchedulerAppointmentFormController.DisplayEnd = newEnd;
- NewSchedulerAppointmentFormController.DisplayStartTime = new TimeSpan(0, 0, 0, 0);
- NewSchedulerAppointmentFormController.DisplayEndTime = new TimeSpan(0, 1, 0, 0);
- _HasBeenUnchecked = true;
- }
- }
+ // NewSchedulerAppointmentFormController.DisplayStartTime = new TimeSpan(0, 0, 0, 0);
+ // NewSchedulerAppointmentFormController.DisplayEndTime = new TimeSpan(0, 1, 0, 0);
+
+ // _HasBeenUnchecked = true;
+ // }
+ //}
}
private void DueDate_OnEditValueChanged(object sender, EditValueChangedEventArgs e)
@@ -726,6 +725,34 @@ namespace BeWo.Scheduler.View
NewSchedulerAppointmentFormController.DisplayEndDate = newEnd;
}
}
+
+ /*
+ * Appointment.End:
+ * ======================================================================================================
+ * The End property is usually specified by the Appointment.Start and Appointment.
+ * Duration properties, and is always calculated as End = Start + Duration.
+ * When setting the End property, the Appointment. Start property retains its value, and the Appointment.
+ * Duration is changed according to the new value of the End property.
+ * If the new Appointment. End property's value is less than the Appointment.
+ * Start property's value, an exception is raised.
+ *
+ */
+
+ private void StartDate_OnChange(object sender, EditValueChangedEventArgs e)
+ {
+ var newStartDate = (DateTime?) e.NewValue;
+ var oldStartDate = (DateTime?) e.OldValue;
+
+ //BeWoApp.LogMessage($"EndDates: {newStartDate:dd.MM.yyyy HH:mm} vs. {oldStartDate:dd.MM.yyyy HH:mm}", DebugWindowMessageColor.Red);
+ }
+
+ private void EndDate_OnChange(object sender, EditValueChangedEventArgs e)
+ {
+ var newEndDate = (DateTime?) e.NewValue;
+ var oldEndDate = (DateTime?) e.OldValue;
+
+ //BeWoApp.LogMessage($"EndDates: {newEndDate:dd.MM.yyyy HH:mm} vs. {oldEndDate:dd.MM.yyyy HH:mm}", DebugWindowMessageColor.Red);
+ }
}
public class NewSchedulerAppointmentFormController : AppointmentFormController
diff --git a/BeWo/Scheduler/ViewModel/SchedulerAppointmentListVM.cs b/BeWo/Scheduler/ViewModel/SchedulerAppointmentListVM.cs
index 999da2cc1..55b06ac65 100644
--- a/BeWo/Scheduler/ViewModel/SchedulerAppointmentListVM.cs
+++ b/BeWo/Scheduler/ViewModel/SchedulerAppointmentListVM.cs
@@ -331,17 +331,17 @@ namespace BeWo.Scheduler.ViewModel
private void UpdateSchedulerAppointment(Appointment app, SchedulerAppointmentVM vm)
{
- vm.EmployeeList = app.CF_EmployeeList();
- vm.CustomerList = app.CF_CustomerList();
- vm.ResourceList = app.CF_ResourceList();
- vm.Originator = app.CF_Originator();
- vm.IsPrivate = app.CF_IsPrivate();
- vm.IsTask = app.CF_IsTask();
- vm.DueDate = app.CF_DueDate();
- vm.CompletedDate = app.CF_CompletedDate();
- vm.CompletedNotice = app.CF_CompletedNotice();
- vm.TaskDescription = app.CF_TaskDescription();
- vm.SupportConceptList = app.CF_SupportConceptList();
+ vm.EmployeeList = app.CF_EmployeeList();
+ vm.CustomerList = app.CF_CustomerList();
+ vm.ResourceList = app.CF_ResourceList();
+ vm.Originator = app.CF_Originator();
+ vm.IsPrivate = app.CF_IsPrivate();
+ vm.IsTask = app.CF_IsTask();
+ vm.DueDate = app.CF_DueDate();
+ vm.CompletedDate = app.CF_CompletedDate();
+ vm.CompletedNotice = app.CF_CompletedNotice();
+ vm.TaskDescription = app.CF_TaskDescription();
+ vm.SupportConceptList = app.CF_SupportConceptList();
vm.HasServiceRecordEntry = app.CF_HasServiceRecordEntry();
if(vm.IsTask)
diff --git a/Controls/Controls.csproj b/Controls/Controls.csproj
index 3319dd7ed..dda29103c 100644
--- a/Controls/Controls.csproj
+++ b/Controls/Controls.csproj
@@ -143,6 +143,7 @@
Resources.Designer.cs
Designer
+
SettingsSingleFileGenerator
Settings.Designer.cs
diff --git a/Data/Data.csproj b/Data/Data.csproj
index 2dc684406..26141bfd4 100644
--- a/Data/Data.csproj
+++ b/Data/Data.csproj
@@ -1,5 +1,6 @@

+
Debug
AnyCPU
@@ -32,6 +33,8 @@
false
true
+
+
true
@@ -83,6 +86,24 @@
False
..\Lib\log4net.dll
+
+ ..\packages\Microsoft.CodeAnalysis.Common.3.4.0\lib\netstandard2.0\Microsoft.CodeAnalysis.dll
+
+
+ ..\packages\Microsoft.CodeAnalysis.CSharp.3.4.0\lib\netstandard2.0\Microsoft.CodeAnalysis.CSharp.dll
+
+
+ ..\packages\Microsoft.CodeAnalysis.CSharp.Workspaces.3.4.0\lib\netstandard2.0\Microsoft.CodeAnalysis.CSharp.Workspaces.dll
+
+
+ ..\packages\Microsoft.CodeAnalysis.VisualBasic.3.4.0\lib\netstandard2.0\Microsoft.CodeAnalysis.VisualBasic.dll
+
+
+ ..\packages\Microsoft.CodeAnalysis.VisualBasic.Workspaces.3.4.0\lib\netstandard2.0\Microsoft.CodeAnalysis.VisualBasic.Workspaces.dll
+
+
+ ..\packages\Microsoft.CodeAnalysis.Workspaces.Common.3.4.0\lib\netstandard2.0\Microsoft.CodeAnalysis.Workspaces.dll
+
False
@@ -96,8 +117,29 @@
..\Lib\NHibernate.ByteCode.Castle.dll
+
+ ..\packages\System.Buffers.4.4.0\lib\netstandard2.0\System.Buffers.dll
+
+
+ ..\packages\System.Collections.Immutable.1.5.0\lib\netstandard2.0\System.Collections.Immutable.dll
+
+
+ ..\packages\System.Composition.AttributedModel.1.0.31\lib\portable-net45+win8+wp8+wpa81\System.Composition.AttributedModel.dll
+
+
+ ..\packages\System.Composition.Convention.1.0.31\lib\portable-net45+win8+wp8+wpa81\System.Composition.Convention.dll
+
+
+ ..\packages\System.Composition.Hosting.1.0.31\lib\portable-net45+win8+wp8+wpa81\System.Composition.Hosting.dll
+
+
+ ..\packages\System.Composition.Runtime.1.0.31\lib\portable-net45+win8+wp8+wpa81\System.Composition.Runtime.dll
+
+
+ ..\packages\System.Composition.TypedParts.1.0.31\lib\portable-net45+win8+wp8+wpa81\System.Composition.TypedParts.dll
+
@@ -106,13 +148,31 @@
+
+ ..\packages\System.Memory.4.5.3\lib\netstandard2.0\System.Memory.dll
+
+
+ ..\packages\System.Numerics.Vectors.4.4.0\lib\net46\System.Numerics.Vectors.dll
+
+
+ ..\packages\System.Reflection.Metadata.1.6.0\lib\netstandard2.0\System.Reflection.Metadata.dll
+
+
+ ..\packages\System.Runtime.CompilerServices.Unsafe.4.5.2\lib\netstandard2.0\System.Runtime.CompilerServices.Unsafe.dll
+
3.0
3.0
+
+ ..\packages\System.Text.Encoding.CodePages.4.5.1\lib\net461\System.Text.Encoding.CodePages.dll
+
+
+ ..\packages\System.Threading.Tasks.Extensions.4.5.3\lib\netstandard2.0\System.Threading.Tasks.Extensions.dll
+
@@ -800,7 +860,20 @@
Shared
+
+
+
+
+
+
+
+
+
+ This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.
+
+
+