From 9f209ec243e6bb7bbbbc124b8cd4be77e2cd8d8e Mon Sep 17 00:00:00 2001 From: "nmayne@DRF00403.dr-foster.lan" Date: Thu, 27 Sep 2012 17:19:51 +0100 Subject: [PATCH] #19062: Removing the layerid from the method signiture and use the one posted back form the modal --HG-- branch : 1.x --- .../Modules/Orchard.Widgets/Controllers/AdminController.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Orchard.Web/Modules/Orchard.Widgets/Controllers/AdminController.cs b/src/Orchard.Web/Modules/Orchard.Widgets/Controllers/AdminController.cs index 6912d26d9..b2b146f07 100644 --- a/src/Orchard.Web/Modules/Orchard.Widgets/Controllers/AdminController.cs +++ b/src/Orchard.Web/Modules/Orchard.Widgets/Controllers/AdminController.cs @@ -318,7 +318,7 @@ namespace Orchard.Widgets.Controllers { [HttpPost, ActionName("EditWidget")] [FormValueRequired("submit.Save")] - public ActionResult EditWidgetSavePOST(int id, int layerId, string returnUrl) { + public ActionResult EditWidgetSavePOST(int id, string returnUrl) { if (!IsAuthorizedToManageWidgets()) return new HttpUnauthorizedResult(); @@ -329,7 +329,7 @@ namespace Orchard.Widgets.Controllers { try { var model = Services.ContentManager.UpdateEditor(widgetPart, this); // override the CommonPart's persisting of the current container - widgetPart.LayerPart = _widgetsService.GetLayer(layerId); + widgetPart.LayerPart = _widgetsService.GetLayer(widgetPart.LayerId); if (!ModelState.IsValid) { Services.TransactionManager.Cancel(); // Casting to avoid invalid (under medium trust) reflection over the protected View method and force a static invocation.