function spaces_views_handler_crayon_name in Spaces 5.2
Same name and namespace in other branches
- 5 spaces_views.inc \spaces_views_handler_crayon_name()
Custom view handler for coloration projects
6 string references to 'spaces_views_handler_crayon_name'
- _spaces_casetracker_views_base in spaces_casetracker/
spaces_casetracker.module - _spaces_casetracker_views_cases_filter in spaces_casetracker/
spaces_casetracker.module - _spaces_casetracker_views_cases_recent in spaces_casetracker/
spaces_casetracker.module - _spaces_core_views_changes in spaces_core/
spaces_core.module - _spaces_core_views_comments in spaces_core/
spaces_core.module
File
- ./
spaces_views.inc, line 104
Code
function spaces_views_handler_crayon_name($fieldinfo, $fielddata, $value, $data) {
switch ($fielddata['options']) {
case 'og':
$og = db_fetch_object(og_get_node_groups_result($data->nid));
$og->nid = $og->group_nid;
return theme('crayon_popup', $og);
break;
case 'casetracker':
static $nodes = array();
$pid = $data->casetracker_case_pid;
if (!$nodes[$pid]) {
$nodes[$pid] = db_fetch_object(db_query(db_rewrite_sql("SELECT n.nid, n.title FROM {node} n WHERE n.nid = %d"), $pid));
}
return theme('crayon_popup', $nodes[$pid]);
break;
}
}