>>11:13:42:属性获取异常(ATTRIBUTE_INVALID):id 位于21行 资源:/modules/cs/csRepairStockinForm.html
属性访问出错
18| <div class="col-sm-8">
19| <#form:treeselect id="parent" title="${text('上级返修入库表')}"
20| path="parent.id" labelPath="parent.barCode"
21| url="${ctx}/cs/csRepairStockin/treeData?excludeCode=${csRepairStockin.id}"
22| class="" allowClear="true" canSelectRoot="true" canSelectParent="true"/>
23| </div>
24| </div>
] with root cause
java.lang.ClassCastException: com.jeesite.modules.cs.entity.CsRepairStockin cannot be cast to com.jeesite.modules.cs.entity.CsRepairStockin
2019-03-18 11:13:42.183 ERROR 6404 --- [nio-8980-exec-8] error/500 : ATTRIBUTE_INVALID
Caused by: java.lang.RuntimeException: com.jeesite.modules.cs.entity.CsRepairStockin cannot be cast to com.jeesite.modules.cs.entity.CsRepairStockin如果采用优化引擎,会假定传给模板的变量是同一类型,如果不是,请使用directive dynamic 变量;来避免
コアを変更するの下にプロジェクトがbeetl-core.properties
リファレンス:http://ibeetl.com/guide/beetl.html#_spring_boot
5.8.3エラープロンプトにFastRuntimeEngineを使用した "ディレクティブダイナミック" Beetlが含まれていると、この問題が発生する場合がある
ENGINE = org.beetl.core.engine.FastRuntimeEngine
このエンジンは、同じテンプレート内の同じグローバル変数は一意のタイプであると想定します。テンプレートが異なるタイプのパブリックテンプレートである場合は、テンプレートの上部でダイナミックを使用できます<%directive dynamic xxx%>テンプレートに多くのケースがある場合、デフォルトのエンジン構成に変更することをお勧めします
ENGINE = org.beetl.core.engine.DefaultTemplateEngine Spring Bootの下に
表示される状況もあります。次のセクションを参照してください