Browse Source

优化注释

tags/v3.0.0
RuoYi 4 years ago
parent
commit
87fcfe0c56
  1. 2
      ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/StringUtils.java
  2. 10
      ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysMenuServiceImpl.java

2
ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/StringUtils.java

@ -259,7 +259,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils @@ -259,7 +259,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils
}
/**
* 下划线转驼峰命名
* 驼峰转下划线命名
*/
public static String toUnderScoreCase(String str)
{

10
ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysMenuServiceImpl.java

@ -158,7 +158,7 @@ public class SysMenuServiceImpl implements ISysMenuService @@ -158,7 +158,7 @@ public class SysMenuServiceImpl implements ISysMenuService
router.setRedirect("noRedirect");
router.setChildren(buildMenus(cMenus));
}
else if (isMeunFrame(menu))
else if (isMenuFrame(menu))
{
List<RouterVo> childrenList = new ArrayList<RouterVo>();
RouterVo children = new RouterVo();
@ -321,7 +321,7 @@ public class SysMenuServiceImpl implements ISysMenuService @@ -321,7 +321,7 @@ public class SysMenuServiceImpl implements ISysMenuService
{
String routerName = StringUtils.capitalize(menu.getPath());
// 非外链并且是一级目录(类型为目录)
if (isMeunFrame(menu))
if (isMenuFrame(menu))
{
routerName = StringUtils.EMPTY;
}
@ -344,7 +344,7 @@ public class SysMenuServiceImpl implements ISysMenuService @@ -344,7 +344,7 @@ public class SysMenuServiceImpl implements ISysMenuService
routerPath = "/" + menu.getPath();
}
// 非外链并且是一级目录(类型为菜单)
else if (isMeunFrame(menu))
else if (isMenuFrame(menu))
{
routerPath = "/";
}
@ -360,7 +360,7 @@ public class SysMenuServiceImpl implements ISysMenuService @@ -360,7 +360,7 @@ public class SysMenuServiceImpl implements ISysMenuService
public String getComponent(SysMenu menu)
{
String component = UserConstants.LAYOUT;
if (StringUtils.isNotEmpty(menu.getComponent()) && !isMeunFrame(menu))
if (StringUtils.isNotEmpty(menu.getComponent()) && !isMenuFrame(menu))
{
component = menu.getComponent();
}
@ -377,7 +377,7 @@ public class SysMenuServiceImpl implements ISysMenuService @@ -377,7 +377,7 @@ public class SysMenuServiceImpl implements ISysMenuService
* @param menu 菜单信息
* @return 结果
*/
public boolean isMeunFrame(SysMenu menu)
public boolean isMenuFrame(SysMenu menu)
{
return menu.getParentId().intValue() == 0 && UserConstants.TYPE_MENU.equals(menu.getMenuType())
&& menu.getIsFrame().equals(UserConstants.NO_FRAME);

Loading…
Cancel
Save