Exemplo n.º 1
0
        public ActionResult Update(MandantDetailsModel mandantDetailsModel)
        {
            if (ModelState.IsValid)
            {
                mandantDetailsService.UpdateEntity(mandantDetailsModel);
                return(View("MandantDetailsSpeichernSuccesfull", mandantDetailsModel));
            }

            PrepareViewBag(mandantDetailsModel);
            return(View("Index", mandantDetailsModel));
        }
Exemplo n.º 2
0
 private void PrepareViewBag(MandantDetailsModel mandantDetailsModel)
 {
     ViewBag.GemeindetypDropDownItems = gemeindeKatalogService.GetGemeindeKatalogModels().ToDropDownItemList(m => localizationService.GetLocalizedBelastungskategorieTyp(m.Typ), m => m.Id, mandantDetailsModel.Gemeindetyp, mandantDetailsModel.Gemeindetyp == null ? string.Empty : null);
     ViewBag.OeffentlicheVerkehrsmittelDropDownItems = oeffentlicheVerkehrsmittelKatalogService.GetOeffentlicheVerkehrsmittelKatalogModels().ToDropDownItemList(m => localizationService.GetLocalizedBelastungskategorieTyp(m.Typ), m => m.Id, mandantDetailsModel.OeffentlicheVerkehrsmittel, mandantDetailsModel.OeffentlicheVerkehrsmittel == null ? string.Empty : null);
 }