diff --git a/BeWoPlanerMobil/Controllers/MainController.cs b/BeWoPlanerMobil/Controllers/MainController.cs index 1f3761df6..303bbeb93 100644 --- a/BeWoPlanerMobil/Controllers/MainController.cs +++ b/BeWoPlanerMobil/Controllers/MainController.cs @@ -195,9 +195,9 @@ namespace BeWoPlanerMobil.Controllers { NameAndDateOfBirth = "Ohne Hilfeplan" }}; - if (Model.IsInEditingMode) + if (Model.IsInEditingMode && Model.SelectedCostBearerSupportConceptOid.HasValue && Model.SelectedCostBearerSupportConceptOid.Value > 0) { - allCostBearerRelationsSingleBooking.RemoveAt(allCostBearerRelationsSingleBooking.Count - 1); + allCostBearerRelationsSingleBooking.RemoveAt(allCostBearerRelationsSingleBooking.Count - 1); // Verhindert, dass man Klienten Buchungen ausversehen zu Buchungen ohne Hilfeplan machen kann. } var allCostBearerRelationsMultiBooking = new List(); diff --git a/BeWoPlanerMobil/Views/Shared/_Layout.cshtml b/BeWoPlanerMobil/Views/Shared/_Layout.cshtml index 49fe8f13c..b7f65f47d 100644 --- a/BeWoPlanerMobil/Views/Shared/_Layout.cshtml +++ b/BeWoPlanerMobil/Views/Shared/_Layout.cshtml @@ -514,7 +514,7 @@ }