mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-28 10:53:39 +01:00
Make owner appendix optional for categories
This commit is contained in:
parent
83a61a8766
commit
459941bd84
@ -231,11 +231,14 @@
|
|||||||
|
|
||||||
if ($this->appname && $cat['app_name'] == 'phpgw')
|
if ($this->appname && $cat['app_name'] == 'phpgw')
|
||||||
{
|
{
|
||||||
$appendix = '<' . lang('Global') . '>';
|
$appendix = ' ♦';
|
||||||
}
|
}
|
||||||
elseif ($cat['owner'] != $accountId)
|
elseif ($cat['owner'] != $accountId)
|
||||||
{
|
{
|
||||||
$appendix = '<' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
if ($GLOBALS['egw_info']['user']['preferences']['common']['show_category_owner'])
|
||||||
|
{
|
||||||
|
$appendix = ' <' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -195,7 +195,10 @@
|
|||||||
}
|
}
|
||||||
elseif ($cat['owner'] != $accountId)
|
elseif ($cat['owner'] != $accountId)
|
||||||
{
|
{
|
||||||
$s .= '<' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
if ($GLOBALS['egw_info']['user']['preferences']['common']['show_category_owner'])
|
||||||
|
{
|
||||||
|
$s .= ' <' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
elseif ($cat['access'] == 'private')
|
elseif ($cat['access'] == 'private')
|
||||||
{
|
{
|
||||||
|
@ -95,7 +95,10 @@ class tree_widget
|
|||||||
}
|
}
|
||||||
elseif ($cat['owner'] != $accountId)
|
elseif ($cat['owner'] != $accountId)
|
||||||
{
|
{
|
||||||
$s .= '<' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
if ($GLOBALS['egw_info']['user']['preferences']['common']['show_category_owner'])
|
||||||
|
{
|
||||||
|
$s .= ' <' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
elseif ($cat['access'] == 'private') {
|
elseif ($cat['access'] == 'private') {
|
||||||
$s .= ' ♥';
|
$s .= ' ♥';
|
||||||
|
@ -343,7 +343,10 @@ class infolog_hooks
|
|||||||
}
|
}
|
||||||
elseif ($cat['owner'] != $accountId)
|
elseif ($cat['owner'] != $accountId)
|
||||||
{
|
{
|
||||||
$s .= '<' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
if ($GLOBALS['egw_info']['user']['preferences']['common']['show_category_owner'])
|
||||||
|
{
|
||||||
|
$s .= ' <' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
elseif ($cat['access'] == 'private')
|
elseif ($cat['access'] == 'private')
|
||||||
{
|
{
|
||||||
|
@ -405,7 +405,10 @@ class categories
|
|||||||
}
|
}
|
||||||
elseif ($cat['owner'] != $this->account_id)
|
elseif ($cat['owner'] != $this->account_id)
|
||||||
{
|
{
|
||||||
$s .= '<' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
if ($GLOBALS['egw_info']['user']['preferences']['common']['show_category_owner'])
|
||||||
|
{
|
||||||
|
$s .= ' <' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
elseif ($cat['access'] == 'private')
|
elseif ($cat['access'] == 'private')
|
||||||
{
|
{
|
||||||
|
@ -216,22 +216,22 @@
|
|||||||
$GLOBALS['egw']->template->set_var('color',$gray < 128 ? 'style="color: white;"' : '');
|
$GLOBALS['egw']->template->set_var('color',$gray < 128 ? 'style="color: white;"' : '');
|
||||||
|
|
||||||
$accountId = $GLOBALS['egw_info']['user']['account_id'];
|
$accountId = $GLOBALS['egw_info']['user']['account_id'];
|
||||||
|
$appendix = '';
|
||||||
|
|
||||||
if ($cat['app_name'] == 'phpgw')
|
if ($GLOBALS['egw_info']['user']['preferences']['common']['show_category_owner'])
|
||||||
{
|
{
|
||||||
$appendix = '<' . lang('Global') . '>';
|
if ($cat['app_name'] == 'phpgw')
|
||||||
}
|
{
|
||||||
elseif ($cat['owner'] == '-1')
|
$appendix = ' ♦';
|
||||||
{
|
}
|
||||||
$appendix = '<' . lang('Global') . ' ' . $GLOBALS['egw_info']['apps'][$cats_app]['title'] . '>';
|
elseif ($cat['owner'] == '-1')
|
||||||
}
|
{
|
||||||
elseif ($cat['owner'] != $accountId)
|
$appendix = ' ♦ ' . $GLOBALS['egw_info']['apps'][$cats_app]['title'];
|
||||||
{
|
}
|
||||||
$appendix = '<' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
elseif ($cat['owner'] != $accountId)
|
||||||
}
|
{
|
||||||
else
|
$appendix = ' <' . $GLOBALS['egw']->accounts->id2name($cat['owner'], 'account_fullname') . '>';
|
||||||
{
|
}
|
||||||
$appendix = '';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$level = $cat['level'];
|
$level = $cat['level'];
|
||||||
|
@ -316,6 +316,18 @@
|
|||||||
'xmlrpc' => True,
|
'xmlrpc' => True,
|
||||||
'admin' => false,
|
'admin' => false,
|
||||||
),
|
),
|
||||||
|
'show_category_owner' => array(
|
||||||
|
'type' => 'select',
|
||||||
|
'label' => 'Show the category owner with the category name.',
|
||||||
|
'name' => 'show_category_owner',
|
||||||
|
'values' => array(
|
||||||
|
'1' => lang('Yes'),
|
||||||
|
'0' => lang('No'),
|
||||||
|
),
|
||||||
|
'help' => 'The owner is attached to distinguish between categories with the same name. You can turn this off and will get the names only.',
|
||||||
|
'xmlrpc' => True,
|
||||||
|
'admin' => False
|
||||||
|
),
|
||||||
);
|
);
|
||||||
// disable thumbnails, if no size configured by admin
|
// disable thumbnails, if no size configured by admin
|
||||||
if (!$GLOBALS['egw_info']['server']['link_list_thumbnail']) unset($GLOBALS['settings']['link_list_thumbnail']);
|
if (!$GLOBALS['egw_info']['server']['link_list_thumbnail']) unset($GLOBALS['settings']['link_list_thumbnail']);
|
||||||
|
1
rpc.php
1
rpc.php
@ -17,6 +17,7 @@ require_once 'Horde/RPC.php';
|
|||||||
$GLOBALS['egw_info'] = array(
|
$GLOBALS['egw_info'] = array(
|
||||||
'flags' => array(
|
'flags' => array(
|
||||||
'currentapp' => 'login',
|
'currentapp' => 'login',
|
||||||
|
'login' => True,
|
||||||
'noheader' => True,
|
'noheader' => True,
|
||||||
'nonavbar' => True,
|
'nonavbar' => True,
|
||||||
'disable_Template_class' => True
|
'disable_Template_class' => True
|
||||||
|
Loading…
Reference in New Issue
Block a user