@At("/main_info")
@Ok("jsp:jsp.work.designRequire.main_info")
public Map<String, Object> toMainInfo(@Param("nmSqbId")Integer nmSqbId){
Map<String, Object> result = new HashMap<String, Object>();
QfgCompanyInfo companyInfo = dao.fetch(QfgCompanyInfo.class, nmSqbId);
QfgProjectInfo projectInfo = dao.fetch(QfgProjectInfo.class, nmSqbId);
QfgDesignRequire designRequire = dao.fetch(QfgDesignRequire.class, nmSqbId);
Criteria cri = Cnd.cri();
cri.where().andEquals("nmSqbId", nmSqbId);
cri.getOrderBy().asc("nmCompanyId");
List<QfgCompanyInfo> companyInfoList = dao.query(QfgCompanyInfo.class, cri);
result.put("nmSqbId", nmSqbId);
result.put("projectInfo", projectInfo);
result.put("designRequire", designRequire);
result.put("companyInfoList", companyInfoList);
return result;
}
6 回复
DEBUG 13:58:10 UrlMappingImpl.get(101)-->Found mapping for [POST] path=/designRequire/main_info : DesignRequireAt.toMainInfo(DesignRequireAt.java:64)
DEBUG 13:58:10 NutIoc.get(151)-->Get 'designRequireAt'<class com.wonders.ghqfg.work.DesignRequireAt>
WARN 13:58:10 FailProcessor.process(28)-->Error@/designRequire/main_info :
java.lang.NullPointerException
at com.wonders.ghqfg.work.DesignRequireAt.toMainInfo(DesignRequireAt.java:65)
at com.wonders.ghqfg.work.DesignRequireAt$$FASTCLASS._invoke(DesignRequireAt.java:1)
at org.nutz.lang.reflect.AbstractFastClass.invoke(AbstractFastClass.java:143)
at org.nutz.lang.reflect.FastClassFactory.invoke(FastClassFactory.java:67)
at org.nutz.mvc.impl.processor.MethodInvokeProcessor.process(MethodInvokeProcessor.java:27)
at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
at org.nutz.mvc.impl.processor.AdaptorProcessor.process(AdaptorProcessor.java:33)
at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
at org.nutz.mvc.impl.processor.ActionFiltersProcessor.process(ActionFiltersProcessor.java:58)
at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
at org.nutz.mvc.impl.processor.ModuleProcessor.process(ModuleProcessor.java:123)
at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
at org.nutz.mvc.impl.processor.EncodingProcessor.process(EncodingProcessor.java:27)
at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
at org.nutz.mvc.impl.processor.UpdateRequestAttributesProcessor.process(UpdateRequestAttributesProcessor.java:15)
at org.nutz.mvc.impl.NutActionChain.doChain(NutActionChain.java:44)
at org.nutz.mvc.impl.ActionInvoker.invoke(ActionInvoker.java:67)
at org.nutz.mvc.ActionHandler.handle(ActionHandler.java:31)
at org.nutz.mvc.NutFilter.doFilter(NutFilter.java:198)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
at java.lang.Thread.run(Thread.java:619)
@wendal 就是说改成 cri.OrderBy().asc("nmCompanyId");这样么
@wendal 那我之前写的在已有nmSqbId时 进行查询是可以的呀
添加回复
请先登陆