kengking 发表于 2014-2-21 22:04:29

新建一级菜单,NullPointerException

新建一个菜单,一级菜单,直接连接到一个页面,赋给某角色后用此角色登录,菜单挂了,错误如下:

org.apache.jasper.JasperException: java.lang.NullPointerException
        org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:538)
        org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:430)
        org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
        org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
        org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:238)
        org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:262)
        org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1180)
        org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:950)
        org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:852)
        org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882)
        org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:789)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:643)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
        com.alibaba.druid.support.http.WebStatFilter.doFilter(WebStatFilter.java:140)
        org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
        org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:119)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)



root cause
java.lang.NullPointerException
        org.jeecgframework.core.util.ListtoMenu.getChildOfTree(ListtoMenu.java:270)
        org.jeecgframework.core.util.ListtoMenu.getEasyuiMultistageTree(ListtoMenu.java:225)
        org.jeecgframework.tag.core.easyui.MenuTag.end(MenuTag.java:59)
        org.jeecgframework.tag.core.easyui.MenuTag.doEndTag(MenuTag.java:47)
        org.apache.jsp.webpage.main.shortcut_005ftop_jsp._jspx_meth_t_005fmenu_005f0(shortcut_005ftop_jsp.java:123)
        org.apache.jsp.webpage.main.shortcut_005ftop_jsp._jspService(shortcut_005ftop_jsp.java:94)
        org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
        org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:388)
        org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
        org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
        org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:238)
        org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:262)
        org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1180)
        org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:950)
        org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:852)
        org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882)
        org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:789)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:643)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
        com.alibaba.druid.support.http.WebStatFilter.doFilter(WebStatFilter.java:140)
        org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
        org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:119)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)



note The full stack trace of the root cause is available in the Apache Tomcat/6.0.39 logs.

ssht968 发表于 2014-2-24 14:26:32

我也碰到过这个问题。我重新导入表后就没这个问题了。不知道怎么回事

Kaibb 发表于 2014-5-31 17:23:50

我也出现过这个问题. 这应该是他设计本身存在的问题. 菜单有一个重要的属性parentfunctionid 父菜单ID.
   而在菜单注解里就没这个属性..那这个菜单要在页面上怎么展示...
理论上说这个bug一测就有,不知为何.....

Arcko 发表于 2014-8-14 15:48:21

谁提交个Patch?
页: [1]
查看完整版本: 新建一级菜单,NullPointerException