Evaluating Facelets Component Expression in Richfaces Sorting

I have some problem evaluating an expression in a Facelets component defined in .taglib.xml

SortField2.getExpression() 

gives me the value "# {sortBy}" instead of evaluating the value.

My component (simple column) is defined as:

  <ui:composition>
      <rich:column sortBy="#{sortBy}" width="#{width}" styleClass="#{styleClass}">
          <f:facet name="header">#{header}</f:facet>
          <ui:insert />
      </rich:column>
  </ui:composition>

I see that TagValueExpression has a “source” field that contains my value, but unfortunately it is private.

Any idea on how to extract it?

Also posted to the Richfaces Forum

Thank you for your help.

+3
source share
1 answer

You may be able to make sortExpression work, rather than using sortBy.

, #{sortBy} ${sortBy} - ? ( )

0

Source: https://habr.com/ru/post/1765601/


All Articles