mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-25 01:13:25 +01:00
Disable kanban column if user does not have access to kanban
This commit is contained in:
parent
e6f142c7a4
commit
a61323f98c
@ -280,7 +280,17 @@ class addressbook_ui extends addressbook_bo
|
|||||||
if ($_GET['search']) {
|
if ($_GET['search']) {
|
||||||
$content['nm']['search'] = $_GET['search'];
|
$content['nm']['search'] = $_GET['search'];
|
||||||
}
|
}
|
||||||
if (isset($typeselection)) $content['nm']['col_filter']['tid'] = $typeselection;
|
if(isset($typeselection))
|
||||||
|
{
|
||||||
|
$content['nm']['col_filter']['tid'] = $typeselection;
|
||||||
|
}
|
||||||
|
|
||||||
|
// disable kanban column if we have no kanban
|
||||||
|
if(empty($GLOBALS['egw_info']['user']['apps']['kanban']))
|
||||||
|
{
|
||||||
|
$content['nm']['no_kanban'] = true;
|
||||||
|
}
|
||||||
|
|
||||||
// save the tid for use in creating new addressbook entrys via UI. Current tid is to be used as type of new entrys
|
// save the tid for use in creating new addressbook entrys via UI. Current tid is to be used as type of new entrys
|
||||||
//error_log(__METHOD__.__LINE__.' '.$content['nm']['col_filter']['tid']);
|
//error_log(__METHOD__.__LINE__.' '.$content['nm']['col_filter']['tid']);
|
||||||
Api\Cache::setSession('addressbook','active_tid',$content['nm']['col_filter']['tid']);
|
Api\Cache::setSession('addressbook','active_tid',$content['nm']['col_filter']['tid']);
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
<column width="180"/>
|
<column width="180"/>
|
||||||
<column width="40"/>
|
<column width="40"/>
|
||||||
<column width="80" disabled="@no_customfields"/>
|
<column width="80" disabled="@no_customfields"/>
|
||||||
<column width="120"/>
|
<column width="120" disabled="@no_kanban"/>
|
||||||
<column width="60%" minWidth="100"/>
|
<column width="60%" minWidth="100"/>
|
||||||
<column width="80" disabled="@no_distribution_list"/>
|
<column width="80" disabled="@no_distribution_list"/>
|
||||||
<column width="80"/>
|
<column width="80"/>
|
||||||
|
@ -410,9 +410,19 @@ class filemanager_ui
|
|||||||
$content['nm']['actions'] = static::get_actions();
|
$content['nm']['actions'] = static::get_actions();
|
||||||
$content['nm']['home_dir'] = static::get_home_dir();
|
$content['nm']['home_dir'] = static::get_home_dir();
|
||||||
$content['nm']['view'] = $GLOBALS['egw_info']['user']['preferences']['filemanager']['nm_view'];
|
$content['nm']['view'] = $GLOBALS['egw_info']['user']['preferences']['filemanager']['nm_view'];
|
||||||
$content['nm']['placeholder_actions'] = array('mkdir','paste','share','file_drop_mail','file_drop_move','file_drop_copy','file_drop_symlink');
|
$content['nm']['placeholder_actions'] = array('mkdir', 'paste', 'share', 'file_drop_mail', 'file_drop_move',
|
||||||
|
'file_drop_copy', 'file_drop_symlink');
|
||||||
|
|
||||||
if (isset($_GET['msg'])) $msg = $_GET['msg'];
|
// disable kanban column if we have no kanban
|
||||||
|
if(empty($GLOBALS['egw_info']['user']['apps']['kanban']))
|
||||||
|
{
|
||||||
|
$content['nm']['no_kanban'] = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(isset($_GET['msg']))
|
||||||
|
{
|
||||||
|
$msg = $_GET['msg'];
|
||||||
|
}
|
||||||
|
|
||||||
// Blank favorite set via GET needs special handling for path
|
// Blank favorite set via GET needs special handling for path
|
||||||
if(isset($_GET['favorite']) && $_GET['favorite'] == 'blank')
|
if(isset($_GET['favorite']) && $_GET['favorite'] == 'blank')
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
<column width="100"/>
|
<column width="100"/>
|
||||||
<column width="30%"/>
|
<column width="30%"/>
|
||||||
<column width="20%"/>
|
<column width="20%"/>
|
||||||
<column width="120"/>
|
<column width="120" disabled="@no_kanban"/>
|
||||||
</columns>
|
</columns>
|
||||||
<rows>
|
<rows>
|
||||||
<row class="th">
|
<row class="th">
|
||||||
|
@ -999,10 +999,18 @@ class infolog_ui
|
|||||||
|
|
||||||
$this->tmpl->read('infolog.index');
|
$this->tmpl->read('infolog.index');
|
||||||
$values['nm']['disable_autorefresh'] = true; // we have push
|
$values['nm']['disable_autorefresh'] = true; // we have push
|
||||||
|
|
||||||
|
// disable kanban column if we have no kanban
|
||||||
|
if(empty($GLOBALS['egw_info']['user']['apps']['kanban']))
|
||||||
|
{
|
||||||
|
$values['nm']['no_kanban'] = true;
|
||||||
|
}
|
||||||
|
|
||||||
$values['nm']['options-filter'] = $this->filters;
|
$values['nm']['options-filter'] = $this->filters;
|
||||||
$values['nm']['get_rows'] = 'infolog.infolog_ui.get_rows';
|
$values['nm']['get_rows'] = 'infolog.infolog_ui.get_rows';
|
||||||
$values['nm']['add_on_top_sort_field'] = 'info_datemodified';
|
$values['nm']['add_on_top_sort_field'] = 'info_datemodified';
|
||||||
$values['nm']['options-filter2'] = (in_array($this->prefs['show_links'],array('all','no_describtion')) ? array() : array(
|
$values['nm']['options-filter2'] = (in_array($this->prefs['show_links'], array('all',
|
||||||
|
'no_describtion')) ? array() : array(
|
||||||
'' => 'default',
|
'' => 'default',
|
||||||
)) + array(
|
)) + array(
|
||||||
'no_describtion' => 'no details',
|
'no_describtion' => 'no details',
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
<column width="120"/>
|
<column width="120"/>
|
||||||
<column width="45%"/>
|
<column width="45%"/>
|
||||||
<column width="15%" disabled="@no_customfields"/>
|
<column width="15%" disabled="@no_customfields"/>
|
||||||
<column width="120"/>
|
<column width="120" disabled="@no_kanban"/>
|
||||||
<column/>
|
<column/>
|
||||||
<column width="120"/>
|
<column width="120"/>
|
||||||
<column/>
|
<column/>
|
||||||
|
@ -140,7 +140,8 @@ class resources_ui
|
|||||||
$content['nm']['options-filter2'][resources_bo::DELETED] = lang('Deleted');
|
$content['nm']['options-filter2'][resources_bo::DELETED] = lang('Deleted');
|
||||||
}
|
}
|
||||||
|
|
||||||
if($_GET['search']) {
|
if($_GET['search'])
|
||||||
|
{
|
||||||
$content['nm']['search'] = $_GET['search'];
|
$content['nm']['search'] = $_GET['search'];
|
||||||
}
|
}
|
||||||
if($_GET['view_accs_of'])
|
if($_GET['view_accs_of'])
|
||||||
@ -150,6 +151,12 @@ class resources_ui
|
|||||||
$content['nm']['actions'] = $this->get_actions();
|
$content['nm']['actions'] = $this->get_actions();
|
||||||
$content['nm']['placeholder_actions'] = array('add');
|
$content['nm']['placeholder_actions'] = array('add');
|
||||||
|
|
||||||
|
// disable kanban column if we have no kanban
|
||||||
|
if(empty($GLOBALS['egw_info']['user']['apps']['kanban']))
|
||||||
|
{
|
||||||
|
$content['nm']['no_kanban'] = true;
|
||||||
|
}
|
||||||
|
|
||||||
// check if user is permitted to add resources
|
// check if user is permitted to add resources
|
||||||
// If they can't read any categories, they won't be able to save it
|
// If they can't read any categories, they won't be able to save it
|
||||||
if(!$this->bo->acl->get_cats(Acl::ADD) || !$this->bo->acl->get_cats(Acl::READ))
|
if(!$this->bo->acl->get_cats(Acl::ADD) || !$this->bo->acl->get_cats(Acl::READ))
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
<column width="15%"/>
|
<column width="15%"/>
|
||||||
<column width="15%"/>
|
<column width="15%"/>
|
||||||
<column width="15%" disabled="@no_customfields"/>
|
<column width="15%" disabled="@no_customfields"/>
|
||||||
<column width="120"/>
|
<column width="120" disabled="@no_kanban"/>
|
||||||
</columns>
|
</columns>
|
||||||
<rows>
|
<rows>
|
||||||
<row class="th">
|
<row class="th">
|
||||||
|
@ -1018,13 +1018,22 @@ class timesheet_ui extends timesheet_bo
|
|||||||
'id' => $_GET['link_id']
|
'id' => $_GET['link_id']
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
// disable kanban column if we have no kanban
|
||||||
|
if(empty($GLOBALS['egw_info']['user']['apps']['kanban']))
|
||||||
|
{
|
||||||
|
$content['nm']['no_kanban'] = true;
|
||||||
|
}
|
||||||
$read_grants = $this->grant_list(Acl::READ);
|
$read_grants = $this->grant_list(Acl::READ);
|
||||||
$content['nm']['no_owner_col'] = count($read_grants) == 1;
|
$content['nm']['no_owner_col'] = count($read_grants) == 1;
|
||||||
if ($GLOBALS['egw_info']['user']['preferences']['timesheet']['nextmatch-timesheet.index.rows']) $content['nm']['selectcols'] = $GLOBALS['egw_info']['user']['preferences']['timesheet']['nextmatch-timesheet.index.rows'];
|
if($GLOBALS['egw_info']['user']['preferences']['timesheet']['nextmatch-timesheet.index.rows'])
|
||||||
|
{
|
||||||
|
$content['nm']['selectcols'] = $GLOBALS['egw_info']['user']['preferences']['timesheet']['nextmatch-timesheet.index.rows'];
|
||||||
|
}
|
||||||
$sel_options = array(
|
$sel_options = array(
|
||||||
'ts_owner' => $read_grants,
|
'ts_owner' => $read_grants,
|
||||||
'pm_id' => array(lang('No project')),
|
'pm_id' => array(lang('No project')),
|
||||||
'cat_id' => array(array('value' => '', 'label' => lang('all categories')), array('value' => 0, 'label'=>lang('None'))),
|
'cat_id' => array(array('value' => '', 'label' => lang('all categories')),
|
||||||
|
array('value' => 0, 'label' => lang('None'))),
|
||||||
'ts_status' => $this->status_labels + array(lang('No status')),
|
'ts_status' => $this->status_labels + array(lang('No status')),
|
||||||
);
|
);
|
||||||
if($this->config_data['history'])
|
if($this->config_data['history'])
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
<column width="50"/>
|
<column width="50"/>
|
||||||
<column width="10%" disabled="@no_ts_status"/>
|
<column width="10%" disabled="@no_ts_status"/>
|
||||||
<column width="15%"/>
|
<column width="15%"/>
|
||||||
<column width="120"/>
|
<column width="120" disabled="@no_kanban"/>
|
||||||
</columns>
|
</columns>
|
||||||
<rows>
|
<rows>
|
||||||
<row class="th">
|
<row class="th">
|
||||||
|
Loading…
Reference in New Issue
Block a user