Lines Matching refs:data
59 $data = array(
76 $data['header'] = $value;
81 $data['short'] = ($value == 'yes');
86 $data['showdate'] = ($value == 'yes');
91 $data['checkbox'] = ($value == 'yes');
96 $data['completed'] = ($value == 'yes');
101 $data['username'] = $value;
106 $data['assigned'] = ($value == 'yes');
110 $data['assigned'] = explode(',', $value);
112 if( in_array( '@@USER@@', $data['assigned'] ) ) {
113 $data['assigned'][] = '@@MAIL@@';
115 … $data['assigned'] = array_map( array($this,"__todolistTrimUser"), $data['assigned'] );
118 $data['completeduserlist'] = explode(',', $value);
120 if(in_array('@@USER@@', $data['completeduserlist'])) {
121 $data['completeduserlist'][] = '@@MAIL@@';
123 …$data['completeduserlist'] = array_map( array($this,"__todolistTrimUser"), $data['completeduserlis…
126 $data['ns'] = $value;
129 list($data['startbefore'], $data['startignore']) = $this->analyseDate($value);
132 list($data['startafter'], $data['startignore']) = $this->analyseDate($value);
135 list($data['startat'], $data['startignore']) = $this->analyseDate($value);
138 list($data['duebefore'], $data['dueignore']) = $this->analyseDate($value);
141 list($data['dueafter'], $data['dueignore']) = $this->analyseDate($value);
144 list($data['dueat'], $data['dueignore']) = $this->analyseDate($value);
147 list($data['completedbefore']) = $this->analyseDate($value);
150 list($data['completedafter']) = $this->analyseDate($value);
153 list($data['completedat']) = $this->analyseDate($value);
157 return $data;
165 * @param array $data The data from the handler() function
168 public function render($mode, Doku_Renderer $renderer, $data) { argument
175 $opts['ns'] = $data['ns'];
181 $todopages = $this->filterpages($todopages, $data);
195 if($data['short']) {
196 $this->htmlShort($renderer, $todopages, $data);
198 $this->htmlTodoTable($renderer, $todopages, $data);
226 public function search_todos(&$data, $base, $file, $type, $lvl, $opts) { argument
249 $data[] = $item;
332 private function filterpages($todopages, $data) { argument
340 …['matches'][2][$todoindex]), 'todoindex' => $todoindex), $this->parseTodoArgs($todomatch), $data);
355 private function htmlShort($R, $todopages, $data) { argument
375 * @param array $data array with rendering options
377 private function htmlTodoTable($R, $todopages, $data) { argument
381 if ($data['header']!='none') {
384 …$R->internallink(':'.$page['id'], ($data['header']=='firstheader' ? p_get_first_heading($page['id'…
395 $R->doc .= $this->createTodoItem($R, $page['id'], array_merge($todo, $data));
411 private function isRequestedTodo($data) { argument
413 $condition1 = $data['completed'] === 'all' //all
414 || $data['completed'] === $data['checked']; //yes or no
418 if(isset($data['assigned']) && is_array($data['assigned'])) {
419 … $requestedassignees = array_map( array($this,"__todolistExpandAssignees"), $data['assigned'] );
422 $condition2 = $data['assigned'] === 'all' //all
423 … || (is_bool($data['assigned']) && $data['assigned'] == $data['todouser']); //yes or no
425 …if (!$condition2 && isset($data['assigned']) && is_array($data['assigned']) && isset($data['todous…
426 foreach($data['todousers'] as $todouser) {
431 if($condition2 && isset($data['completeduserlist']) && is_array($data['completeduserlist']))
432 $condition2 = in_array($data['completeduser'], $data['completeduserlist']);
437 … if(isset($data['startbefore']) || isset($data['startafter']) || isset($data['startat'])) {
438 if(isset($data['start'])) {
439 … if($data['startignore'] != '*') { //date comparison is needed unless we don't care -> '*'
440 …if(isset($data['startbefore'])) { $condition3s = $condition3s && new DateTime($data['startbefore']…
441 …if(isset($data['startafter'])) { $condition3s = $condition3s && new DateTime($data['startafter']) …
442 …if(isset($data['startat'])) { $condition3s = $condition3s && new DateTime($data['startat']) == $da…
444 …} elseif($data['startignore'] != '!') { //start date not set and we're not looking for todos witho…
449 if(isset($data['duebefore']) || isset($data['dueafter']) || isset($data['dueat'])) {
450 if(isset($data['due'])) {
451 … if($data['dueignore'] != '*') { //date comparison is needed unless we don't care -> '*'
452 …if(isset($data['duebefore'])) { $condition3d = $condition3d && new DateTime($data['duebefore']) > …
453 …if(isset($data['dueafter'])) { $condition3d = $condition3d && new DateTime($data['dueafter']) < $d…
454 …if(isset($data['dueat'])) { $condition3d = $condition3d && new DateTime($data['dueat']) == $data['…
456 …} elseif($data['dueignore'] != '!') { //due date not set and we're not looking for todos without d…
465 if(isset($data['completedbefore'])) {
466 … $condition4 = $condition4 && new DateTime($data['completedbefore']) > $data['completeddate'];
468 if(isset($data['completedafter'])) {
469 … $condition4 = $condition4 && new DateTime($data['completedafter']) < $data['completeddate'];
471 if(isset($data['completedat'])) {
472 … $condition4 = $condition4 && new DateTime($data['completedat']) == $data['completeddate'];