預設情況下可以對 DataObjects 進行排序
class SortDataObject extends DataObject {
private static $db = array(
'Name' => 'Varchar',
'SortOrder' => 'Int'
);
private static $default_sort = 'SortOrder DESC';
}
class SortDataObject extends DataObject {
private static $db = array(
'Name' => 'Varchar',
'SortOrder' => 'Int'
);
private static $default_sort = 'SortOrder DESC';
}