function template_preprocess_filedepot_header in filedepot 6
Same name and namespace in other branches
- 7 lib-theme.php \template_preprocess_filedepot_header()
File
- ./
lib-theme.php, line 21 - lib-theme.php Theme support functions for the module
Code
function template_preprocess_filedepot_header(&$variables) {
$filedepot = filedepot_filedepot();
$variables['show_mainheader'] = '';
$variables['show_incomingheader'] = 'none';
$variables['LANG_filename'] = t('Filename');
$variables['LANG_showfiledetails'] = t('Show File Details');
$variables['LANG_expandfolders'] = t('Expand Folders');
$variables['LANG_date'] = t('Date');
$variables['LANG_folder'] = t('Folder');
$variables['LANG_submitted'] = t('Submitted');
$variables['LANG_owner'] = t('Owner');
$variables['rightpadding'] = '35';
// Need to tweek the right most padding of the far right heading column for the approvals report view.
if ($filedepot->activeview == 'incoming') {
$variables['show_incomingheader'] = '';
$variables['show_mainheader'] = 'none';
}
if ($filedepot->cid > 0) {
$variables['rightpadding'] = '10';
$variables['show_folder'] = 'none';
$variables['show_folderexpandlink'] = '';
}
elseif ($filedepot->activeview == 'approvals') {
$variables['rightpadding'] = '10';
$variables['show_folder'] = '';
$variables['show_folderexpandlink'] = 'none';
}
else {
$variables['show_folder'] = '';
$variables['show_folderexpandlink'] = 'none';
}
if ($filedepot->activeview == 'approvals') {
$variables['LANG_action'] = t('Submitter');
}
else {
$variables['LANG_action'] = t('Action');
}
if ($reportmode == 'incoming' and user_access('administer filedepot', $user)) {
$variables['show_owner'] = '';
}
else {
$variables['show_owner'] = 'none';
}
}