[Admin Tools | log4j2]: MenuService.java: [Bug fix] Method "updatePid()" needs to update portalPid in menu and menu items.
This commit is contained in:
parent
43a4c1a5a4
commit
58f6612945
|
@ -382,5 +382,14 @@ public class MenuService {
|
|||
menuDAO.save(menu);
|
||||
log.debug("menu saved!");
|
||||
}
|
||||
|
||||
List<MenuItem> menuItems = menuItemDAO.findByPortalPid(old_pid);
|
||||
if(menuItems != null) {
|
||||
menuItems.forEach(menuItem -> {
|
||||
menuItem.setPortalPid(new_pid);
|
||||
menuItemDAO.save(menuItem);
|
||||
log.debug("menuItem saved!");
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue