[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-4273) edit.xhtml.ftl template cause duplicate id changeParent and selectParent

Julien Kronegg (JIRA) jira-events at lists.jboss.org
Fri Jun 26 06:09:57 EDT 2009


edit.xhtml.ftl template cause duplicate id changeParent and selectParent
------------------------------------------------------------------------

                 Key: JBSEAM-4273
                 URL: https://jira.jboss.org/jira/browse/JBSEAM-4273
             Project: Seam
          Issue Type: Bug
          Components: Tools
    Affects Versions: 2.1.2.GA
         Environment: SEAM_HOME/seam-gen/view/edit.xhtml.ftl
            Reporter: Julien Kronegg


When a MyEntityEdit.xhtml page with more than one foreign key is generated, the "Select" / "Change" button is generated with an id "changeParent" or "selectParent" for each foreign key.
This causes "duplicate id" errors when displaying the page.

The button id must be changed to be unique, e.g. by suffixing with the property name.

The line 136:

            <s:button id="${'#'}{${homeName}.instance.${property.name} != null ? 'changeParent' : 'selectParent'}" value="${'#'}{${homeName}.instance.${property.name} != null ? 'Change' : 'Select'} ${property.name}"

must be replaced by:

            <s:button id="${'#'}{${homeName}.instance.${property.name} != null ? 'changeParent${property.name?cap_first} ' : 'selectParent${property.name?cap_first}'}" value="${'#'}{${homeName}.instance.${property.name} != null ? 'Change' : 'Select'} ${property.name}"

I did not find references to the button id elsewhere, so it seems that no side effect will appear.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list