You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Josué Alcalde (JIRA)" <de...@myfaces.apache.org> on 2007/03/09 12:48:24 UTC

[jira] Created: (TOMAHAWK-927) Using t:commandSortHeader without propertyName will always result in a warning

Using t:commandSortHeader without propertyName will always result in a warning
------------------------------------------------------------------------------

                 Key: TOMAHAWK-927
                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-927
             Project: MyFaces Tomahawk
          Issue Type: Bug
    Affects Versions: 1.1.5-SNAPSHOT
            Reporter: Josué Alcalde
            Priority: Trivial


If someone use t:commandSortHeader and wants to implement sorting in his way, then he won't need to use propertyName in commandSortHeader.
Since I move to 1.1.5-SNAPSHOT this will result in a warning because of this code:

 else if (headerFacet instanceof HtmlCommandSortHeader)
                {
                    //command sort headers are already in place, just store the column name and sort property name
                    HtmlCommandSortHeader sortHeader = (HtmlCommandSortHeader) headerFacet;
                    columnName = sortHeader.getColumnName();
                    propertyName = sortHeader.getPropertyName();

                    //if the command sort header component doesn't specify a sort property, determine it
                    if (propertyName == null)
                    {
                        propertyName = getSortPropertyFromEL(aColumn);
                        sortHeader.setPropertyName(propertyName);
                    }

                    if (propertyName == null)
                        log.warn("Couldn't determine sort property for column [" + aColumn.getId() + "].");
                }


I think the log.warn should be a log.debug, because it will warn innecesary when you don't want to use the auto sorting.

Setting the propertyName to a fake value is a workaround.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.