+
+ // Put a new file in storage if we have it.
+ if ($id && $showFiles && $_FILES['newfile']['name']) {
+ $fileHelper = new ttFileHelper($err);
+ $fields = array('entity_type'=>'time',
+ 'entity_id' => $id,
+ 'file_name' => $_FILES['newfile']['name']);
+ $fileHelper->putFile($fields);
+ }
+
+ if ($id && $result && $err->no()) {