*
* - applySort($au, $sortcol, $direction, $array_of_columns, $multisort) -- does not support multisort at present..
* - applyFilters($_REQUEST, $authUser, $roo) -- apply any query filters on data. and hide stuff not to be seen. (RETURN false to prevent default filters.)
- * - postListExtra($_REQUEST) : array(extra_name => data) - add extra column data on the results (like new messages etc.)
+ * - postListExtra($_REQUEST, $roo, $array_data) : array(extra_name => data) - add extra column data on the results (like new messages etc.)
* - postListFilter($data, $authUser, $request) return $data - add extra data to an object
*
* - toRooSingleArray($authUser, $request) // single fetch, add data..
* - onInsert($request,$roo, $event) - after insert
* - onDelete($req, $roo) - after delete
* - onUpload($roo)
- *
-
- *
+ *
* - toEventString (for logging - this is generically prefixed to all database operations.)
*/
* applyFilters($_REQUEST, $authUser, $roo)
* -- apply any query filters on data. and hide stuff not to be seen.
* -- can exit by calling $roo->jerr()
- * postListExtra($_REQUEST) : array(extra_name => data)
- * - add extra column data on the results (like new messages etc.)
+ * postListExtra($_REQUEST, $roo, $array_data) : array(extra_name => data)
+ * - add extra column to the jdata return key/value info.
* postListFilter($data, $authUser, $request) return $data
- * - add extra data to an object
+ * - modify the returned array of data (either add stuff to the data, or remove lines etc)
*
*
* toRooSingleArray($authUser, $request) : array
$extra = false;
if (method_exists($queryObj ,'postListExtra')) {
- $extra = $queryObj->postListExtra($_REQUEST, $this);
+ $extra = $queryObj->postListExtra($_REQUEST, $this, $ret);
}
}
- //die("DONE?");
-
- //if ($x->tableName() == 'Documents_Tracking') {
- // $ret = $this->replaceSubject(&$ret, 'doc_id_subject');
- // }
-
if (!empty($_REQUEST['_requestMeta']) && count($ret)) {
$meta = $this->meta($x, $ret);
if ($meta) {
+ $extra = $extra ? $extra: array();
$extra['metaData'] = $meta;
}
}
// 'fillBlank' => 'gray', // set
);
//die('here');
- if (method_exists($this->do, 'toSimpleExcelColumn')) {
+ if (!empty($this->do) && method_exists($this->do, 'toSimpleExcelColumn')) {
$add = $this->do->toSimpleExcelColumn($add);
}
function insert($x, $req, $with_perm_check = true)
{
-
- if (method_exists($x, 'setFromRoo')) {
+ if (method_exists($x, 'setFromRoo')) {
$res = $x->setFromRoo($req, $this);
if (is_string($res)) {
$this->jerr($res);