forked from extern/egroupware
Calendar: Include current user as explicit select option for import target
This commit is contained in:
parent
95a4b319bb
commit
eb416c3d91
@ -474,7 +474,15 @@ class calendar_import_csv extends importexport_basic_import_csv {
|
||||
$options = array(
|
||||
'name' => 'calendar.import_csv',
|
||||
'content' => array(
|
||||
'owner' => $owner ? $owner : null
|
||||
'owner' => $owner ? [$owner] : null
|
||||
),
|
||||
'sel_options' => array(
|
||||
'cal_owner' => [
|
||||
[
|
||||
'value' => $GLOBALS['egw_info']['user']['account_id'],
|
||||
'label' => calendar_owner_etemplate_widget::get_owner_label($GLOBALS['egw_info']['user']['account_id'])
|
||||
]
|
||||
]
|
||||
)
|
||||
);
|
||||
return $options;
|
||||
|
@ -303,10 +303,16 @@ class calendar_import_ical implements importexport_iface_import_plugin {
|
||||
'content' => array(
|
||||
'file_type' => 'ical',
|
||||
'charset' => $GLOBALS['egw_info']['user']['preferences']['common']['csv_charset'],
|
||||
'cal_owner' => $definition->plugin_options['cal_owner'] ?: $GLOBALS['egw_info']['user']['account_id']
|
||||
'cal_owner' => [$definition->plugin_options['cal_owner'] ?: $GLOBALS['egw_info']['user']['account_id']]
|
||||
),
|
||||
'sel_options' => array(
|
||||
'charset' => Api\Translation::get_installed_charsets()
|
||||
'charset' => Api\Translation::get_installed_charsets(),
|
||||
'cal_owner' => [
|
||||
[
|
||||
'value' => $GLOBALS['egw_info']['user']['account_id'],
|
||||
'label' => calendar_owner_etemplate_widget::get_owner_label($GLOBALS['egw_info']['user']['account_id'])
|
||||
]
|
||||
]
|
||||
),
|
||||
'preserv' => array()
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user