From e3216614a97c969e65266a449b697c556c3b6b23 Mon Sep 17 00:00:00 2001 From: alekseybobkov Date: Sun, 4 Jan 2015 20:32:34 -0800 Subject: [PATCH] Added code comments --- modules/backend/formwidgets/DataTable.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/modules/backend/formwidgets/DataTable.php b/modules/backend/formwidgets/DataTable.php index c41b0f03a..441a60670 100644 --- a/modules/backend/formwidgets/DataTable.php +++ b/modules/backend/formwidgets/DataTable.php @@ -71,6 +71,10 @@ class DataTable extends FormWidgetBase */ public function getSaveData($value) { + // TODO: provide a streaming implementation of saving + // data to the model. The current implementation returns + // all records at once. -ab + $dataSource = $this->table->getDataSource(); $result = []; @@ -87,6 +91,11 @@ class DataTable extends FormWidgetBase protected function populateTableWidget() { $dataSource = $this->table->getDataSource(); + + // TODO: provide a streaming implementation of loading + // data from the model. The current implementation loads + // all records at once. -ab + $records = $this->getLoadData() ?: []; $dataSource->initRecords((array) $records); }