Click
  1. Click
  2. CLK-241

Table Headers use incorrect title attribute (table-last-title) when sortable=true

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.3.0-M1
    • Component/s: core
    • Labels:
      None
    • Environment:
      Click 1.4RC1

      Description

      In the renderTableHeader() method of the Column class, the actionLink is retrieved from getTable().getControlLink().
      This method sends back the ActionLink used for paging, but...

      The problem is that the title of this ActionLinks is already set to getMessage("table-last-title") in the renderPagingControls() method of the Table class if the banner position is TOP or BOTH, and it is not set again in the renderTableHeader() method.

      Proposed solution : at least set the title of the retrieved ActionLink to somehting meaningful in the renderTableHeader() method, like controlLink.setAttribute("title", getMessage("table-sort-links")), where the entry would resolve to "Sort by" in the click-control.properties file ("Trié par" in French).

      Easy to fix for the 1.4 release, I think.

        Activity

        Patrick Talbot created issue -
        Hide
        Malcolm Edgar added a comment -

        Hi Patrick,

        could you please upload a patch for this.

        regards Malcolm Edgar

        Show
        Malcolm Edgar added a comment - Hi Patrick, could you please upload a patch for this. regards Malcolm Edgar
        Hide
        Patrick Talbot added a comment -

        Malcolm,

        The problem is that if I add:
        + controlLink.setTitle(getMessage("table-sort-links"));
        there will be a need for a new entry in the "click-control_xx.properties"

        But I am not sure that theses files (their names especially) should stay as they are right now (see <a href="/jira/browse/CLK-238">CLK-238</a> for discussion on the problem).

        So in the mean time, I patched:
        + controlLink.setTitle(getMessage("table-sort-links"));

        Hope this helps.

        Show
        Patrick Talbot added a comment - Malcolm, The problem is that if I add: + controlLink.setTitle(getMessage("table-sort-links")); there will be a need for a new entry in the "click-control_xx.properties" But I am not sure that theses files (their names especially) should stay as they are right now (see <a href="/jira/browse/ CLK-238 "> CLK-238 </a> for discussion on the problem). So in the mean time, I patched: + controlLink.setTitle(getMessage("table-sort-links")); Hope this helps.
        Patrick Talbot made changes -
        Field Original Value New Value
        Attachment Column.java.patch [ 10288 ]
        Henri Yandell made changes -
        Project Import Fri Mar 20 14:11:32 PDT 2009 [ 1237583492744 ]
        Bob Schellink made changes -
        Fix Version/s 2.3.0-M1 [ 12314845 ]
        Hide
        Bob Schellink added a comment -

        fixed

        Show
        Bob Schellink added a comment - fixed
        Bob Schellink made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Malcolm Edgar [ medgar ] Bob Schellink [ sabob ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Bob Schellink
            Reporter:
            Patrick Talbot
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development