diff --git a/BeWo/DebugConfig.cs b/BeWo/DebugConfig.cs index 86333065f..41a7fc5a5 100644 --- a/BeWo/DebugConfig.cs +++ b/BeWo/DebugConfig.cs @@ -136,9 +136,9 @@ namespace BeWo AutoLogin = true, //SelectView = UIContext.Organisation, //SelectIndex = 8, - DefaultLoginUsername = "admin", - DefaultLoginPassword = "bewobewo", - DefaultProfilename = "5000000000", + //DefaultLoginUsername = "admin", + //DefaultLoginPassword = "bewobewo", + //DefaultProfilename = "5000000000", EnableAutoRemoteDebugging = true }); diff --git a/BeWo/View/Detail/Accounting/GkvAbrechnungOverview.xaml.cs b/BeWo/View/Detail/Accounting/GkvAbrechnungOverview.xaml.cs index e9284dec8..d32cf97f2 100644 --- a/BeWo/View/Detail/Accounting/GkvAbrechnungOverview.xaml.cs +++ b/BeWo/View/Detail/Accounting/GkvAbrechnungOverview.xaml.cs @@ -81,9 +81,17 @@ namespace BeWo.View.Detail.Accounting { _IsRequesting = true; - var gkv = ServiceFacade.DoGkvAccountingServiceSync(x => x.GetAllGkvAbrechnungen()); + var filter = new GkvAbrechnungViewFilterDC(); - UpdateGkvAbrechnungList(gkv); + filter.FilterTime = true; + filter.Start = _Viewmodel.DateTimeSpanFilter.StartDate; + filter.End = _Viewmodel.DateTimeSpanFilter.EndDate; + filter.FilterForCreationDate = true; + + ServiceFacade.DoGkvAccountingServiceAsync( + x => x.GetAllGkvAbrechnungenBy(filter), + cb => UpdateGkvAbrechnungList(cb), + exp => _IsRequesting = false); } catch (Exception e) { diff --git a/Data/Access/FinanceDAO.cs b/Data/Access/FinanceDAO.cs index 1fa0332b5..d631a249e 100644 --- a/Data/Access/FinanceDAO.cs +++ b/Data/Access/FinanceDAO.cs @@ -34,13 +34,13 @@ namespace BeWo.Data.Access return false; } - public IEnumerable GetGkvAbrechnungen(DateTime? startDate, DateTime? endDate, bool useInvoiceDate = true) + public IEnumerable GetGkvAbrechnungen(DateTime? startDate, DateTime? endDate, bool useInvoiceCreationDate = true) { if (endDate.HasValue) endDate = endDate.Value.Date.AddDays(1).AddMilliseconds(-1); var lCriteria = CreateCriteriaIsActive(); - if (useInvoiceDate) + if (useInvoiceCreationDate) { if (startDate.HasValue) lCriteria.Add(Restrictions.Ge(nameof(GkvAbrechnungLight.ErstelltAm), startDate)); diff --git a/Service/ServiceImplementations/GkvAccountingServiceImp.cs b/Service/ServiceImplementations/GkvAccountingServiceImp.cs index 6487d6d7d..fa128b688 100644 --- a/Service/ServiceImplementations/GkvAccountingServiceImp.cs +++ b/Service/ServiceImplementations/GkvAccountingServiceImp.cs @@ -82,7 +82,7 @@ namespace BeWo.Service.ServiceImplementations { var start = gkvAbrechnungViewFilter.Start; var end = gkvAbrechnungViewFilter.End; - var filter = gkvAbrechnungViewFilter.FilterForInvoiceDate; + var filter = gkvAbrechnungViewFilter.FilterForCreationDate; return GetGkvAbrechnungen(() => DAOFactory.FinanceDAO.GetGkvAbrechnungen(start, end, filter)); } diff --git a/Shared/DataContracts/Invoicing/GkvAbrechnung/GkvAbrechnungViewFilterDC.cs b/Shared/DataContracts/Invoicing/GkvAbrechnung/GkvAbrechnungViewFilterDC.cs index 22019eaf2..5510af41a 100644 --- a/Shared/DataContracts/Invoicing/GkvAbrechnung/GkvAbrechnungViewFilterDC.cs +++ b/Shared/DataContracts/Invoicing/GkvAbrechnung/GkvAbrechnungViewFilterDC.cs @@ -15,6 +15,6 @@ namespace BS.Shared.DataContracts.GkvAbrechnung [DataMember] public bool FilterTime { get; set; } [DataMember] public DateTime? Start { get; set; } [DataMember] public DateTime? End { get; set; } - [DataMember] public bool FilterForInvoiceDate { get; set; } + [DataMember] public bool FilterForCreationDate { get; set; } } }