mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 06:30:59 +01:00
Fix selection choice default
This commit is contained in:
parent
36e0b275c3
commit
31d717643c
@ -212,6 +212,11 @@ class importexport_export_ui {
|
||||
}
|
||||
else
|
||||
{
|
||||
if($definition->filter)
|
||||
{
|
||||
$content['selection'] = 'filter';
|
||||
}
|
||||
|
||||
// Process relative dates into the current absolute date
|
||||
foreach($content['filter']['fields'] as $field => $settings)
|
||||
{
|
||||
@ -235,15 +240,20 @@ class importexport_export_ui {
|
||||
\$j('div.filters').hide();
|
||||
");
|
||||
}
|
||||
|
||||
$preserv['old_definition'] = $content['definition'];
|
||||
|
||||
// If not set by plugin, pre-set selection to preference, or 'search'
|
||||
if (($prefs = $GLOBALS['egw_info']['user']['preferences']['importexport'][$definition->definition_id]) &&
|
||||
($prefs = unserialize($prefs)) && is_array($content['selection']) && !$content['selection']['plugin_override'])
|
||||
($prefs = unserialize($prefs)) && !$content['selection']['plugin_override'])
|
||||
{
|
||||
$selection = $content['selection'];
|
||||
$content = array_merge_recursive($content,$prefs);
|
||||
$content['selection'] = $prefs['selection'] ? $prefs['selection'] : $selection;
|
||||
}
|
||||
if(!$content['selection'])
|
||||
{
|
||||
$content['selection'] = 'search';
|
||||
}
|
||||
unset ($plugin_object);
|
||||
$apps = importexport_helper_functions::get_apps('export');
|
||||
//error_log(__METHOD__.__LINE__.array2string($apps));
|
||||
|
@ -580,7 +580,11 @@ class importexport_helper_functions {
|
||||
}
|
||||
|
||||
// Get field -> label map and initialize fields using wizard field order
|
||||
$fields = $export_fields = $wizard_plugin->get_export_fields();
|
||||
$fields = $export_fields = array();
|
||||
if(method_exists($wizard_plugin, 'get_export_fields'))
|
||||
{
|
||||
$fields = $export_fields = $wizard_plugin->get_export_fields();
|
||||
}
|
||||
|
||||
foreach($record_classname::$types as $type => $type_fields)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user