Merge pull request #9645 from MasonD/datalist-column-bug

Fix #9641 DataList->column mutating underlying DataQuery
This commit is contained in:
Sam Minnée 2020-08-22 17:59:03 +12:00 committed by GitHub
commit 009ae3ee4f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1014,7 +1014,8 @@ class DataList extends ViewableData implements SS_List, Filterable, Sortable, Li
*/ */
public function column($colName = "ID") public function column($colName = "ID")
{ {
return $this->dataQuery->distinct(false)->column($colName); $dataQuery = clone $this->dataQuery;
return $dataQuery->distinct(false)->column($colName);
} }
/** /**