ICEfaces
  1. ICEfaces
  2. ICE-6222

ice:commandButton should support f:param similar to h:commandButton

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 3.0.1, EE-3.0.0.GA
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      jsf2.0, ICEfaces-2.0, compat

      Description

      ice:commandButton currently does not support any <f:param> so if you do the following in compat showcase:-
            <ice:outputLabel for="BLCmdBtn"
                               value="#{msgs['page.buttonsAndLinks.submitButtonLabel']}"/>
              <ice:commandButton id="BLCmdBtn"
                                 value="Submit"
                                 actionListener="#{buttonsAndLinks.submitButtonListener}">
                           <f:param name="fileId" value="21"/>
              </ice:commandButton>

      you get the following markup:-
      <input class="iceCmdBtn" id="iceform:BLCmdBtn" name="iceform:BLCmdBtn" onblur="setFocus('');" onclick="iceSubmit(form,this,event);return false;" onfocus="setFocus(this.id);" type="submit" value="Submit">

      if you do the same thing with <h:commandButton> you get the following:-

      <input id="fileform:fileTable:0:delFileBtn" name="fileform:fileTable:0:delFileBtn" onclick="mojarra.jsfcljs(document.getElementById('fileform'),{'fileform:fileTable:0:delFileBtn':'fileform:fileTable:0:delFileBtn','fileId':'1'},'');return false" type="submit" value="Delete">

      Note with <ice:commandButton> there is no encoding of the parameter name or value so it never gets submitted to the server.

        Activity

        Hide
        yip.ng added a comment - - edited

        Done. See screenshot-1.png.

        Modified: C:\svn\ossrepo\icefaces3\trunk\icefaces\compat\components\src\main\java\com\icesoft\faces\component\ext\renderkit\ButtonRenderer.java
        Modified: C:\svn\ossrepo\icefaces3\trunk\icefaces\compat\core\src\main\java\com\icesoft\faces\renderkit\dom_html_basic\ButtonRenderer.java
        Completed: At revision: 28191

        Modified: C:\svn\ossrepo\icefaces3\branches\icefaces-3.0.x-maintenance\icefaces\compat\components\src\main\java\com\icesoft\faces\component\ext\renderkit\ButtonRenderer.java
        Modified: C:\svn\ossrepo\icefaces3\branches\icefaces-3.0.x-maintenance\icefaces\compat\core\src\main\java\com\icesoft\faces\renderkit\dom_html_basic\ButtonRenderer.java
        Completed: At revision: 28193

        Show
        yip.ng added a comment - - edited Done. See screenshot-1.png. Modified: C:\svn\ossrepo\icefaces3\trunk\icefaces\compat\components\src\main\java\com\icesoft\faces\component\ext\renderkit\ButtonRenderer.java Modified: C:\svn\ossrepo\icefaces3\trunk\icefaces\compat\core\src\main\java\com\icesoft\faces\renderkit\dom_html_basic\ButtonRenderer.java Completed: At revision: 28191 Modified: C:\svn\ossrepo\icefaces3\branches\icefaces-3.0.x-maintenance\icefaces\compat\components\src\main\java\com\icesoft\faces\component\ext\renderkit\ButtonRenderer.java Modified: C:\svn\ossrepo\icefaces3\branches\icefaces-3.0.x-maintenance\icefaces\compat\core\src\main\java\com\icesoft\faces\renderkit\dom_html_basic\ButtonRenderer.java Completed: At revision: 28193

          People

          • Assignee:
            yip.ng
            Reporter:
            Judy Guglielmin
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: