设为首页收藏本站

JEECG官方网站-企业级JAVA快速开发平台

 找回密码
 立即注册

关注JEECG发展历程 关注最新动态和版本, 记录JEECG成长点滴 最新动态 - 技术支持 - 师徒架构班

JEECG最新版本下载 JEECG智能开发平台 - 显著提高开发效率 常见问题 - 入门视频 - 参与开源团队

商务 QQ: 3102411850、418799587 商务热线: 18611788525 客服电话: 010-64808099 官方邮箱: jeecgos@163.com

查看: 214|回复: 15

2.0一对多代码生成报错,而1.1没报错

[复制链接]

2

主题

0

好友

42

积分

新手上路

Rank: 2

发表于 2019-5-24 14:56:11 |显示全部楼层
同一个数据库 同样三张表。是框架原生的
jeecg-boot-main order_customer order_ticket
在1.1没有报错,也可以两张表实现关联生成
但是在2.o就会有一下报错
虽然有报错,但是模型可以照常生成,但会导致后端启动不了

五月 24, 2019 12:07:03 下午 freemarker.log._JULLoggerFactory$JULLogger error
严重: Error executing FreeMarker template
FreeMarker template error:
The following has evaluated to null or missing:
==> subTab.originalForeignKeys  [in template "java/${bussiPackage}/${entityPackage}/mapper/xml/[1-n]Mapper.xml" at line 2, column 32]

----
Tip: It's the step after the last dot that caused this error, not those before it.
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----

----
FTL stack trace ("~" means nesting-related):
        - Failed at: #assign originalForeignKeys = subTab...  [in template "java/${bussiPackage}/${entityPackage}/mapper/xml/[1-n]Mapper.xml" at line 2, column 1]
----

Java stack trace (for programmers):
----
freemarker.core.InvalidReferenceException: [... Exception message was already printed; see it above ...]
        at freemarker.core.InvalidReferenceException.getInstance(InvalidReferenceException.java:134)
        at freemarker.core.Assignment.accept(Assignment.java:139)
        at freemarker.core.Environment.visit(Environment.java:366)
        at freemarker.core.IteratorBlock$IterationContext.executedNestedContentForCollOrSeqListing(IteratorBlock.java:317)
        at freemarker.core.IteratorBlock$IterationContext.executeNestedContent(IteratorBlock.java:271)
        at freemarker.core.IteratorBlock$IterationContext.accept(IteratorBlock.java:242)
        at freemarker.core.Environment.visitIteratorBlock(Environment.java:642)
        at freemarker.core.IteratorBlock.acceptWithResult(IteratorBlock.java:107)
        at freemarker.core.IteratorBlock.accept(IteratorBlock.java:93)
        at freemarker.core.Environment.visit(Environment.java:330)
        at freemarker.core.Environment.process(Environment.java:309)
        at freemarker.template.Template.process(Template.java:384)
        at org.jeecgframework.codegenerate.generate.util.b.a(FreemarkerHelper.java:85)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:105)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:75)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:55)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:39)
        at org.jeecgframework.codegenerate.generate.impl.CodeGenerateOneToMany.generateCodeFile(CodeGenerateOneToMany.java:174)
        at org.jeecg.JeecgOneToMainUtil.main(JeecgOneToMainUtil.java:63)

FreeMarker template error:
The following has evaluated to null or missing:
==> subTab.originalForeignKeys  [in template "java/${bussiPackage}/${entityPackage}/mapper/xml/[1-n]Mapper.xml" at line 2, column 32]

----
Tip: It's the step after the last dot that caused this error, not those before it.
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----

----
FTL stack trace ("~" means nesting-related):
        - Failed at: #assign originalForeignKeys = subTab...  [in template "java/${bussiPackage}/${entityPackage}/mapper/xml/[1-n]Mapper.xml" at line 2, column 1]
----

Java stack trace (for programmers):
----
freemarker.core.InvalidReferenceException: [... Exception message was already printed; see it above ...]
        at freemarker.core.InvalidReferenceException.getInstance(InvalidReferenceException.java:134)
        at freemarker.core.Assignment.accept(Assignment.java:139)
        at freemarker.core.Environment.visit(Environment.java:366)
        at freemarker.core.IteratorBlock$IterationContext.executedNestedContentForCollOrSeqListing(IteratorBlock.java:317)
        at freemarker.core.IteratorBlock$IterationContext.executeNestedContent(IteratorBlock.java:271)
        at freemarker.core.IteratorBlock$IterationContext.accept(IteratorBlock.java:242)
        at freemarker.core.Environment.visitIteratorBlock(Environment.java:642)
        at freemarker.core.IteratorBlock.acceptWithResult(IteratorBlock.java:107)
        at freemarker.core.IteratorBlock.accept(IteratorBlock.java:93)
        at freemarker.core.Environment.visit(Environment.java:330)
        at freemarker.core.Environment.process(Environment.java:309)
        at freemarker.template.Template.process(Template.java:384)
        at org.jeecgframework.codegenerate.generate.util.b.a(FreemarkerHelper.java:85)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:105)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:75)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:55)
        at org.jeecgframework.codegenerate.generate.impl.a.a.a(BaseCodeGenerate.java:39)
        at org.jeecgframework.codegenerate.generate.impl.CodeGenerateOneToMany.generateCodeFile(CodeGenerateOneToMany.java:174)
        at org.jeecg.JeecgOneToMainUtil.main(JeecgOneToMainUtil.java:63)
无效楼层,该帖已经被删除
无效楼层,该帖已经被删除
无效楼层,该帖已经被删除
5#
无效楼层,该帖已经被删除
6#
无效楼层,该帖已经被删除
7#
无效楼层,该帖已经被删除
8#
无效楼层,该帖已经被删除
9#
无效楼层,该帖已经被删除
10#
无效楼层,该帖已经被删除
您需要登录后才可以回帖 登录 | 立即注册

Archiver|手机版|JEECG快速开发平台 - 官方论坛 ( 京ICP备12013567号-3 )  

GMT+8, 2019-6-25 06:29 , Processed in 2.293204 second(s), 21 queries , Gzip On, Memcache On.

JEECG Open Source

© 2001-2012 Comsenz Inc.

回顶部