function _signup_user_no_views in Signup 5.2
Same name and namespace in other branches
- 6.2 includes/no_views.inc \_signup_user_no_views()
Private helper as a partial implementation of hook_user().
See also
1 call to _signup_user_no_views()
- signup_user in ./
signup.module - Implementation of hook_user().
File
- includes/
views.none.inc, line 55 - Provides all the code for required UI elements for sites that do not have views.module enabled. If views is enabled, there are default views for all of these things (which are therefore customizable and more powerful) in signup/views/views.inc.
Code
function _signup_user_no_views($op, &$edit, &$user, $category = NULL) {
switch ($op) {
case 'view':
// grab list of nodes the user signed up for.
$signups = signup_list_user_signups($user->uid);
if (count($signups) && variable_get('signup_no_views_user_info', TRUE)) {
$output = '<h4>' . t('Current signups') . ' -- ' . l(t('view signup schedule'), "user/{$user->uid}/signups") . '</h4>' . theme_item_list($signups);
}
if (isset($output)) {
return array(
t('Signup information') => array(
array(
'value' => $output,
'class' => 'user',
),
),
);
}
break;
}
}