NetBeans Forums
| View previous topic :: View next topic |
| Author |
Message |
hatspencer
Joined: 11 Nov 2010 Posts: 4
|
Posted: Mon Nov 22, 2010 6:39 pm Post subject: NetBeans JSF Pages from Entity Classes relationshipMany issue |
|
|
Hey there,
I've been customizing the JSF Pages from Entity Classes templates in NetBeans 6.8-6.9.1, and found that the template engine doesn't ever execute the <#elseif entityDescriptor.relationshipMany> clause of this code block:
| Code: | <#list entityDescriptors as entityDescriptor>
<h:outputLabel value="${r"#{"}bundle.Create${entityName}Label_${entityDescriptor.id?replace(".","_")}${r"}"}" for="${entityDescriptor.id?replace(".","_")}" />
<#if entityDescriptor.dateTimeFormat?? && entityDescriptor.dateTimeFormat != "">
<h:inputText id="${entityDescriptor.id?replace(".","_")}" value="${r"#{"}${entityDescriptor.name}${r"}"}" title="${r"#{"}bundle.Create${entityName}Title_${entityDescriptor.id?replace(".","_")}${r"}"}" <#if entityDescriptor.required>required="true" requiredMessage="${r"#{"}bundle.Create${entityName}RequiredMessage_${entityDescriptor.id?replace(".","_")}${r"}"}"</#if>>
<f:convertDateTime pattern="${entityDescriptor.dateTimeFormat}" />
</h:inputText>
<#elseif entityDescriptor.blob>
<h:inputTextarea rows="4" cols="30" id="${entityDescriptor.id?replace(".","_")}" value="${r"#{"}${entityDescriptor.name}${r"}"}" title="${r"#{"}bundle.Create${entityName}Title_${entityDescriptor.id?replace(".","_")}${r"}"}" <#if entityDescriptor.required>required="true" requiredMessage="${r"#{"}bundle.Create${entityName}RequiredMessage_${entityDescriptor.id?replace(".","_")}${r"}"}"</#if>/>
<#elseif entityDescriptor.relationshipOne>
<h:selectOneMenu id="${entityDescriptor.id?replace(".","_")}" value="${r"#{"}${entityDescriptor.name}${r"}"}" title="${r"#{"}bundle.Create${entityName}Title_${entityDescriptor.id?replace(".","_")}${r"}"}" <#if entityDescriptor.required>required="true" requiredMessage="${r"#{"}bundle.Create${entityName}RequiredMessage_${entityDescriptor.id?replace(".","_")}${r"}"}"</#if>>
<f:selectItems value="${r"#{"}${entityDescriptor.valuesGetter}${r"}"}"/>
</h:selectOneMenu>
<#elseif entityDescriptor.relationshipMany>
<h:selectManyMenu id="${entityDescriptor.id?replace(".","_")}" value="${r"#{"}${entityDescriptor.name}${r"}"}" title="${r"#{"}bundle.Create${entityName}Title_${entityDescriptor.id?replace(".","_")}${r"}"}" <#if entityDescriptor.required>required="true" requiredMessage="${r"#{"}bundle.Create${entityName}RequiredMessage_${entityDescriptor.id?replace(".","_")}${r"}"}"</#if>>
<f:selectItems value="${r"#{"}${entityDescriptor.valuesGetter}${r"}"}"/>
</h:selectManyMenu>
<#else>
<h:inputText id="${entityDescriptor.id?replace(".","_")}" value="${r"#{"}${entityDescriptor.name}${r"}"}" title="${r"#{"}bundle.Create${entityName}Title_${entityDescriptor.id?replace(".","_")}${r"}"}" <#if entityDescriptor.required>required="true" requiredMessage="${r"#{"}bundle.Create${entityName}RequiredMessage_${entityDescriptor.id?replace(".","_")}${r"}"}"</#if>/>
</#if> |
Therefore, nothing is generated for Entities @ManyToMany or @ManyToOne attributes. Does anybody know anything about this?
The above is the Create.ftl template of JSF Pages from Entity Classes. Code generation finishes without errors.
Thanks in advance, Daniel |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|