@@ -152,4 +152,13 @@ public class SysMenuController extends BaseController
List<SysMenu> menus = menuService.getMenuList();
return success(menus);
}
+
+ /**
+ * 根据路由地址获取详细信息
+ */
+ @GetMapping("/particular/{path}")
+ public AjaxResult particular(@PathVariable String path)
+ {
+ return success(menuService.selectMenuByPath(path));
+ }
@@ -141,4 +141,12 @@ public interface SysMenuMapper
* 动态表格获取菜单
*/
List<SysMenu> getMenuList();
+ * 根据路由地址查询信息
+ *
+ * @param path 路由地址
+ * @return 菜单信息
+ SysMenu selectMenuByPath(String path);
@@ -146,4 +146,12 @@ public interface ISysMenuService
* 动态表格菜单列表
public List<SysMenu> getMenuList();
@@ -366,6 +366,11 @@ public class SysMenuServiceImpl implements ISysMenuService
return menuMapper.getMenuList();
+ @Override
+ public SysMenu selectMenuByPath(String path) {
+ return menuMapper.selectMenuByPath(path);
/**
* 获取路由名称
*
@@ -249,4 +249,9 @@
where menu_type != 'F'
</select>
+ <select id="selectMenuByPath" parameterType="string" resultMap="SysMenuResult">
+ <include refid="selectMenuVo"/>
+ where path = #{path}
+ </select>
</mapper>