Hi there,
I'm trying to create a grouped list with two groupings, im using 3.1 and i have it working lovely with just one grouping but for the life of me i cant figure out how to make it two groupings.
The table has a number of columns one called stage the other called category and i'd like to list all records by stage then within each stage by category.
below is my code from the dataobject and on the template.
hope you can help.
Mick
<div class="checklist">
<% loop groupedChecks.GroupedBy(Stage) %>
<div class="row ">
<div class="large-12 columns field">
<h5>$Stage</h5>
</div>
</div>
<% loop Children %>
<div class="row">
<div class="large-12 columns ">
<div class="large-9 columns field">
<p>$Name</p>
</div>
<% if Checked %>
<div class="large-3 columns field">
<div class="roundedOne">
<input type="checkbox" value="0" id="roundedOne $ID" name="$ID" checked="checked" />
<label for="roundedOne $ID"></label>
</div>
</div>
<% else %>
<div class="large-3 columns field">
<div class="roundedOne">
<input type="checkbox" value="1" id="roundedOne $ID" name="$ID" />
<label for="roundedOne $ID"></label>
</div>
</div>
<% end_if %>
</div>
</div>
<% end_loop %>
<% end_loop %>
</div>
function groupedChecks() {
return GroupedList::create(TheCheck::get()->filter('ProjectID' , $this->ID));
}