Uploaded image for project: 'MyFaces Trinidad'
  1. MyFaces Trinidad
  2. TRINIDAD-613

inputDate should not render icon if 'chooseId' specified

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.0.0-incubating-core
    • 1.0.0-incubating-core
    • None
    • None

    Description

      The current <tr:inputDate> implementation always renders an icon immediately following the input field. However, if you specify a <tr:chooseDate> to render the calendar in-page, it shouldn't render the icon. A simple patch to SimpleInputDateRenderer fixes this (below).

      PATCH to org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.SimpleInputDateRenderer

      @Override
      protected void renderAfterTextField(
      FacesContext context,
      RenderingContext arc,
      UIComponent component,
      FacesBean bean) throws IOException

      { // Only render the icon if chooseId is not specified. if (_getChooseId(arc) == null) super.renderAfterTextField(context, arc, component, bean); }

      By the way, this fix will cause CoreRenderKitTest to fail, so will require an update to the expected/golden output for this component. Sorry - I'm not yet familiar enough to do this.

      Thanks,

      Danny

      Attachments

        Activity

          People

            Unassigned Unassigned
            dannyjrobinson Danny Robinson
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: