Im Kalender für die Bestätigungen die LabelId-Eigenschaft (int) in die LabelKey-Eigenschaft (long?) geändert.
This commit is contained in:
@@ -11,8 +11,6 @@ namespace BeWo.Scheduler
|
||||
|
||||
DateTime End { get; set;}
|
||||
|
||||
int LabelId { get; set;}
|
||||
|
||||
string Subject { get; set;}
|
||||
|
||||
string Description { get; set; }
|
||||
@@ -26,5 +24,7 @@ namespace BeWo.Scheduler
|
||||
string RecurrenceInfo { get; set; }
|
||||
|
||||
Dictionary<string, object> CustomFields { get; }
|
||||
|
||||
long? LabelKey { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -977,7 +977,7 @@
|
||||
End="End"
|
||||
Subject="Subject"
|
||||
Description="Description"
|
||||
Label="LabelId"
|
||||
Label="LabelKey"
|
||||
AllDay="AllDay"
|
||||
ResourceId="ResourceId"
|
||||
RecurrenceInfo="RecurrenceInfo"
|
||||
|
||||
@@ -2246,7 +2246,7 @@ namespace BeWo.Scheduler.View
|
||||
|
||||
foreach (var app in kollektionOhneAusnahmen.Where(w => !ausnahmen.Select(s => s.RecurrenceIndex).Contains(w.RecurrenceIndex)))
|
||||
{
|
||||
var recurrenceId = app.RecurrenceInfo.Id.ToString();//BeWo.Scheduler.Utils.Utils.ExtractIdFromRecurrenceInfo(app.RecurrenceInfo.ToString());
|
||||
var recurrenceId = app.RecurrenceInfo.Id.ToString();
|
||||
|
||||
if (app.IsOccurrence && deletedOccurrences.Any(a => a.RecurrenceId == recurrenceId && a.RecurrenceIndex == app.RecurrenceIndex))
|
||||
{
|
||||
@@ -2260,12 +2260,9 @@ namespace BeWo.Scheduler.View
|
||||
{
|
||||
kollektionOhneAusnahmen = kollektionOhneAusnahmen.Where(w => !ausnahmen.Select(s => s.RecurrenceIndex).Contains(w.RecurrenceIndex)).ToList();
|
||||
}
|
||||
// TODO: DeletedOccurrences nicht aufnahmen bzw. herausnehmen
|
||||
|
||||
foreach(var appointment in kollektionOhneAusnahmen)
|
||||
{
|
||||
var subject = appointment.Subject;
|
||||
|
||||
var recurrenceId = appointment.RecurrenceInfo.Id.ToString();
|
||||
var recurrenceIndex = appointment.RecurrenceIndex;
|
||||
|
||||
@@ -2283,7 +2280,7 @@ namespace BeWo.Scheduler.View
|
||||
IsPrivate = basistermin.IsPrivate,
|
||||
Location = appointment.Location,
|
||||
Subject = appointment.Subject,
|
||||
LabelId = appointment.LabelId,
|
||||
LabelKey = (long?) appointment.LabelKey,
|
||||
Type = (int)appointment.Type,
|
||||
Originator = basistermin.Originator,
|
||||
RecurrenceInfo = appointment.RecurrenceInfo.ToXml()
|
||||
@@ -2332,7 +2329,7 @@ namespace BeWo.Scheduler.View
|
||||
EndDate = new DateTime(termin.StartDate.Value.AddDays(i + 1).Year, termin.StartDate.Value.AddDays(i + 1).Month, termin.StartDate.Value.AddDays(i + 1).Day),
|
||||
FormerBookingSequenceOid = termin.FormerBookingSequenceOid,
|
||||
IsPrivate = termin.IsPrivate,
|
||||
LabelId = termin.LabelId,
|
||||
LabelKey = termin.LabelKey,
|
||||
Location = termin.Location,
|
||||
Originator = termin.Originator,
|
||||
RecurrenceInfo = termin.RecurrenceInfo,
|
||||
@@ -2360,7 +2357,7 @@ namespace BeWo.Scheduler.View
|
||||
EndDate = new DateTime(termin.StartDate.Value.AddDays(1).Year, termin.StartDate.Value.AddDays(1).Month, termin.StartDate.Value.AddDays(1).Day),
|
||||
FormerBookingSequenceOid = termin.FormerBookingSequenceOid,
|
||||
IsPrivate = termin.IsPrivate,
|
||||
LabelId = termin.LabelId,
|
||||
LabelKey = termin.LabelKey,
|
||||
Location = termin.Location,
|
||||
Originator = termin.Originator,
|
||||
RecurrenceInfo = termin.RecurrenceInfo,
|
||||
@@ -2383,7 +2380,7 @@ namespace BeWo.Scheduler.View
|
||||
EndDate = termin.EndDate,
|
||||
FormerBookingSequenceOid = termin.FormerBookingSequenceOid,
|
||||
IsPrivate = termin.IsPrivate,
|
||||
LabelId = termin.LabelId,
|
||||
LabelKey = termin.LabelKey,
|
||||
Location = termin.Location,
|
||||
Originator = termin.Originator,
|
||||
RecurrenceInfo = termin.RecurrenceInfo,
|
||||
@@ -2406,7 +2403,7 @@ namespace BeWo.Scheduler.View
|
||||
EndDate = new DateTime(termin.StartDate.Value.AddDays(i + 1).Year, termin.StartDate.Value.AddDays(i + 1).Month, termin.StartDate.Value.AddDays(i + 1).Day),
|
||||
FormerBookingSequenceOid = termin.FormerBookingSequenceOid,
|
||||
IsPrivate = termin.IsPrivate,
|
||||
LabelId = termin.LabelId,
|
||||
LabelKey = termin.LabelKey,
|
||||
Location = termin.Location,
|
||||
Originator = termin.Originator,
|
||||
RecurrenceInfo = termin.RecurrenceInfo,
|
||||
|
||||
@@ -69,7 +69,7 @@ namespace BeWo.Scheduler.View
|
||||
var item = (SchedulerAppointmentVM) beWoAppointment;
|
||||
foreach(var relation in item.EmployeeList.Where(emp => emp.IsPChanged && emp.ParticipationAnswer != ParticipationAnswer.Offen && emp.ParticipationAnswer != ParticipationAnswer.Verstrichen && !emp.Employee.EmployeeOid.Equals(BeWoApp.LoggedOnEmployee.EmployeeOid)))
|
||||
{
|
||||
if(statusUpdatesAsAppointments.All(a => a.LabelId != relation.Employee2SchedulerAppointmentOid))
|
||||
if(statusUpdatesAsAppointments.All(a => a.LabelKey != relation.Employee2SchedulerAppointmentOid))
|
||||
{
|
||||
if(relation.Employee2SchedulerAppointmentOid != null)
|
||||
{
|
||||
@@ -113,7 +113,7 @@ namespace BeWo.Scheduler.View
|
||||
ActivationType = dc.ActivationType
|
||||
})
|
||||
{
|
||||
CustomFields = item.CustomFields, LabelId = Convert.ToInt32(emp2AppOid)
|
||||
CustomFields = item.CustomFields, LabelKey = emp2AppOid
|
||||
};
|
||||
}
|
||||
|
||||
@@ -180,7 +180,7 @@ namespace BeWo.Scheduler.View
|
||||
|
||||
vm.UpdateCustomFields();
|
||||
|
||||
if (vm.LabelId == 0)
|
||||
if (vm.LabelKey is null)
|
||||
{
|
||||
this.Dispatch(() =>
|
||||
{
|
||||
@@ -196,7 +196,7 @@ namespace BeWo.Scheduler.View
|
||||
}
|
||||
else
|
||||
{
|
||||
var test = (SchedulerAppointmentVM) OffeneTermine.FirstOrDefault(f => dc.EmployeeList.Any(a => a.Employee2SchedulerAppointmentOid.HasValue && a.Employee2SchedulerAppointmentOid.Value == f.LabelId));
|
||||
var test = (SchedulerAppointmentVM) OffeneTermine.FirstOrDefault(f => dc.EmployeeList.Any(a => a.Employee2SchedulerAppointmentOid.HasValue && a.Employee2SchedulerAppointmentOid.Value == f.LabelKey));
|
||||
this.Dispatch(() =>
|
||||
{
|
||||
OffeneTermine = OffeneTermine.Where(w => !w.Equals(test)).ToObservableCollection();
|
||||
@@ -245,7 +245,7 @@ namespace BeWo.Scheduler.View
|
||||
{
|
||||
var customFieldStorage = (CustomFieldStorage) SelektierterTermin.CustomFields[nameof(CustomFieldStorage)];
|
||||
|
||||
var emp2App = customFieldStorage.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == SelektierterTermin.LabelId) ??
|
||||
var emp2App = customFieldStorage.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == SelektierterTermin.LabelKey) ??
|
||||
customFieldStorage.EmployeeList.ToList().Find(f => f.Employee.EmployeeOid == BeWoApp.LoggedOnEmployee.EmployeeOid.Value);
|
||||
|
||||
if(emp2App.Employee.EmployeeOid == BeWoApp.LoggedOnEmployee.EmployeeOid.Value)
|
||||
@@ -264,15 +264,15 @@ namespace BeWo.Scheduler.View
|
||||
return;
|
||||
}
|
||||
|
||||
if(SelektierterTermin == null || SelektierterTermin.LabelId <= 0)
|
||||
if(SelektierterTermin?.LabelKey is null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
var customFieldStorage2 = (CustomFieldStorage)SelektierterTermin.CustomFields[nameof(CustomFieldStorage)];
|
||||
|
||||
customFieldStorage2.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == SelektierterTermin.LabelId).IsPC_CheckedTs = DateTime.Now;
|
||||
customFieldStorage2.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == SelektierterTermin.LabelId).IsPChanged = false;
|
||||
customFieldStorage2.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == SelektierterTermin.LabelKey).IsPC_CheckedTs = DateTime.Now;
|
||||
customFieldStorage2.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == SelektierterTermin.LabelKey).IsPChanged = false;
|
||||
|
||||
ToggleControls();
|
||||
raiseChangeEvent = true;
|
||||
@@ -366,7 +366,7 @@ namespace BeWo.Scheduler.View
|
||||
return string.Empty;
|
||||
}
|
||||
|
||||
if(app.LabelId <= 0)
|
||||
if(app.LabelKey is null)
|
||||
{
|
||||
return $"{app.Start.ToShortDateString()}: {app.Subject}";
|
||||
}
|
||||
@@ -375,7 +375,7 @@ namespace BeWo.Scheduler.View
|
||||
|
||||
var customFieldStorage = (CustomFieldStorage) app.CustomFields[nameof(CustomFieldStorage)];
|
||||
|
||||
var l = customFieldStorage.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == app.LabelId);
|
||||
var l = customFieldStorage.EmployeeList.ToList().Find(f => f.Employee2SchedulerAppointmentOid == app.LabelKey);
|
||||
|
||||
switch(l.ParticipationAnswer)
|
||||
{
|
||||
|
||||
@@ -254,7 +254,7 @@ namespace BeWo.Scheduler.ViewModel
|
||||
StartDate = item.Start,
|
||||
EndDate = item.End,
|
||||
Originator = item.CF_Originator(),
|
||||
LabelId = item.LabelId,
|
||||
LabelKey = (long?) item.LabelKey,
|
||||
AllDay = item.AllDay,
|
||||
Status = item.StatusId,
|
||||
Type = (int) item.Type,
|
||||
@@ -390,8 +390,8 @@ namespace BeWo.Scheduler.ViewModel
|
||||
}
|
||||
}
|
||||
|
||||
app.LabelId = vm.LabelId;
|
||||
}
|
||||
app.LabelKey = vm.LabelKey;
|
||||
}
|
||||
|
||||
AbstractAppointmentEditForm ISchedulerViewModel.GetEditAppointmentForm(SchedulerControl control, Appointment appointment)
|
||||
{
|
||||
|
||||
@@ -95,7 +95,7 @@ namespace BeWo.Scheduler.ViewModel
|
||||
public DateTime? AbsenceTimeEnd { get; set; }
|
||||
|
||||
public object Id { get; set; }
|
||||
public int LabelId { get; set; }
|
||||
|
||||
public Dictionary<string, object> CustomFields
|
||||
{
|
||||
get => _CustomFields ?? (_CustomFields = new Dictionary<string, object>());
|
||||
@@ -689,7 +689,7 @@ namespace BeWo.Scheduler.ViewModel
|
||||
|
||||
var areEqual =
|
||||
Equals(Subject, obj.Subject) &&
|
||||
LabelId == obj.LabelId &&
|
||||
LabelKey == obj.LabelKey &&
|
||||
AllDay == obj.AllDay &&
|
||||
IsPrivate == obj.IsPrivate &&
|
||||
IsDirty == obj.IsDirty &&
|
||||
@@ -729,5 +729,7 @@ namespace BeWo.Scheduler.ViewModel
|
||||
|
||||
set => base.IsNew = value;
|
||||
}
|
||||
}
|
||||
|
||||
public long? LabelKey { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1587,7 +1587,7 @@ namespace BeWo.View
|
||||
Subject = patternAppointment.Subject,
|
||||
Location = patternAppointment.Location,
|
||||
Status = patternAppointment.Status,
|
||||
LabelId = patternAppointment.LabelId,
|
||||
LabelKey = patternAppointment.LabelKey,
|
||||
RecurrenceIndex = devExpressAppointment.RecurrenceIndex,
|
||||
RecurrenceId = appointment.RecurrenceId
|
||||
};
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<IISExpressWindowsAuthentication />
|
||||
<IISExpressUseClassicPipelineMode />
|
||||
<UseGlobalApplicationHostFile />
|
||||
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
|
||||
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
|
||||
<ProjectView>ShowAllFiles</ProjectView>
|
||||
<WebStackScaffolding_ViewDialogWidth>600</WebStackScaffolding_ViewDialogWidth>
|
||||
<Controller_SelectedScaffolderID>MvcControllerEmptyScaffolder</Controller_SelectedScaffolderID>
|
||||
|
||||
@@ -208,7 +208,7 @@ namespace BeWoPlanerMobil.Controllers
|
||||
EndDate = app.Start.AddMinutes(duration),
|
||||
FormerBookingSequenceOid = appointment.FormerBookingSequenceOid,
|
||||
IsPrivate = appointment.IsPrivate,
|
||||
LabelId = appointment.LabelId,
|
||||
LabelKey = appointment.LabelKey,
|
||||
Location = appointment.Location,
|
||||
Originator = appointment.Originator,
|
||||
RecurrenceInfo = app.RecurrenceInfo.ToXml(),
|
||||
|
||||
@@ -5,6 +5,7 @@ using DevExpress.Web.Mvc;
|
||||
using DevExpress.XtraScheduler;
|
||||
using DayView = DevExpress.Web.ASPxScheduler.DayView;
|
||||
|
||||
// TODO: Ist veraltet!
|
||||
namespace BeWoPlanerMobil.Views.DevExpressScheduler
|
||||
{
|
||||
public static class SchedulerHelper
|
||||
|
||||
@@ -38,9 +38,6 @@ namespace BS.Shared.DataContracts
|
||||
[DataMember]
|
||||
public CompactEmployeeDC Originator { get; set; }
|
||||
|
||||
[DataMember]
|
||||
public int LabelId { get; set; }
|
||||
|
||||
[DataMember]
|
||||
public bool AllDay { get; set; }
|
||||
|
||||
@@ -92,7 +89,10 @@ namespace BS.Shared.DataContracts
|
||||
[DataMember]
|
||||
public List<CompactSupportConceptDC> SupportConceptList { get; set; }
|
||||
|
||||
public int RecurrenceIndex { get; set; }
|
||||
[DataMember]
|
||||
public long? LabelKey { get; set; }
|
||||
|
||||
public int RecurrenceIndex { get; set; }
|
||||
|
||||
public string RecurrenceId { get; set; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user