title: Groovy table sorting when the column is a sorted set of a class
body: <p>I have a a view that lists several contractor objects. The last column is from addresses which is a  sorted set in the contractor object. I am trying to sort those columns and I get an exception that the property addresses is not defined in class Contractors. Do I need to handle the sorted set differently in the controller?</p>
  
  <pre><code>&lt;table width="100%"&gt;
                  &lt;thead&gt;
                  &lt;tr&gt;
                      &lt;th&gt;&lt;/th&gt;
                      &lt;g:sortableColumn property="status" title="${message(code: 'contractor.status.label', default: 'Status')}" params="[statuses:statuses,name:name,nameOperator:nameOperator ?: 'CONTAINS']"/&gt;
                      &lt;g:sortableColumn property="contractorName" title="${message(code: 'contractor.contractorName.label', default: 'Name')}" params="[statuses:statuses,name:name,nameOperator:nameOperator ?: 'CONTAINS']"/&gt;
  
                      &lt;g:sortableColumn property="addresses.address" title='Address' params="[statuses:statuses,name:name,nameOperator:nameOperator ?: 'CONTAINS']"/&gt;
  
                  &lt;/tr&gt;
                  &lt;/thead&gt;
                  &lt;tbody&gt;
                  &lt;g:each in="${contractorList}" status="i" var="contractor"&gt;
                      &lt;tr class="${(i % 2) == 0 ? 'odd' : 'even'}"&gt;
  
                          &lt;td&gt;
                              &lt;g:link action="show" id="${contractor.id}"&gt;show&lt;/g:link&gt;
                              &amp;nbsp;|&amp;nbsp;
                              &lt;g:link action="edit" id="${contractor.id}"&gt;edit&lt;/g:link&gt;
                          &lt;/td&gt;
                          &lt;td&gt;${contractor.status}&lt;/td&gt;
                          &lt;td&gt;${contractor.contractorName}&lt;/td&gt;
                          &lt;td&gt;${contractor?.addresses?.address}&lt;/td&gt;
  
                      &lt;/tr&gt;
                  &lt;/g:each&gt;
                  &lt;/tbody&gt;
              &lt;/table&gt;
  </code></pre>
  
  <p>The logic in the controller:</p>
  
  <pre><code>order(params.sort, params.order)
  </code></pre>
  
  <p>I am very new to groovy/grails any help would be appreciated, thanks!</p>