Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to edit Module settings after moving Module to another page #3353

Merged
merged 3 commits into from
Dec 3, 2019
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions DNN Platform/Library/Entities/Modules/ModuleController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1902,6 +1902,21 @@ public void MoveModule(int moduleId, int fromTabId, int toTabId, string toPaneNa
//Move the module to the Tab
dataProvider.MoveTabModule(fromTabId, moduleId, toTabId, toPaneName, UserController.Instance.GetCurrentUserInfo().UserID);

//Update the Tab reference for the module's ContentItems
var contentController = Util.GetContentController();
var contentItems = contentController.GetContentItemsByModuleId(moduleId);
if (contentItems?.Count() > 0)
valadas marked this conversation as resolved.
Show resolved Hide resolved
{
foreach (var item in contentItems)
{
if (item.TabID != toTabId)
{
item.TabID = toTabId;
contentController.UpdateContentItem(item);
}
}
}
aelibyary marked this conversation as resolved.
Show resolved Hide resolved

//Update Module Order for source tab, also updates the tabmodule version guid
UpdateTabModuleOrder(fromTabId);

Expand Down