]> wagnertech.de Git - timetracker.git/blobdiff - week.php
A bit of refactoring of week view related code for clarity.
[timetracker.git] / week.php
index c6c194f30d148627b52b1ca3806857fb36ca6e3b..f7f42f7c7188f24ad6aa15b783c4b311ff1e085a 100644 (file)
--- a/week.php
+++ b/week.php
@@ -116,18 +116,11 @@ $dayTotals = ttTimeHelper::getDayTotals($dataArray, $dayHeaders);
 
 // TODO: refactoring ongoing down from here.
 
-
-
-
-
-
-
 // Actually this is work in progress at this point, even documenting the array, as we still miss control IDs, and
 // editing entries is not yet implemented. When this is done, we will have to re-document the above.
 
 // TODO:
-// 1) escape cf_1 values in record identifiers as this may come from user for text fields.
-// 2) make sure we have IDs for cells, which are now missing.
+// 1) make sure we have IDs for cells, which are now missing.
 
 // Define rendering class for a label field to the left of durations.
 class LabelCellRenderer extends DefaultCellRenderer {
@@ -141,7 +134,7 @@ class LabelCellRenderer extends DefaultCellRenderer {
 // Define rendering class for a single cell for time entry in week view table.
 class TimeCellRenderer extends DefaultCellRenderer {
   function render(&$table, $value, $row, $column, $selected = false) {
-    $field_name = $table->getValueAtName($row,$column)['id']; // Our text field names (and ids) are like x_y (row_column).
+    $field_name = $table->getValueAt($row,$column)['id']; // Our text field names (and ids) are like x_y (row_column).
     $field = new TextField($field_name);
     $field->setFormName($table->getFormName());
     $field->setSize(2);