From e4884335af2ce7f4e5511aafd418233084c5e063 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 19 Oct 2010 17:27:10 +0000 Subject: [PATCH] Add option to choose to update or replace categories --- .../class.importexport_wizard_basic_import_csv.inc.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/importexport/inc/class.importexport_wizard_basic_import_csv.inc.php b/importexport/inc/class.importexport_wizard_basic_import_csv.inc.php index 1d6508ccbe..4a3e51bae4 100644 --- a/importexport/inc/class.importexport_wizard_basic_import_csv.inc.php +++ b/importexport/inc/class.importexport_wizard_basic_import_csv.inc.php @@ -195,6 +195,14 @@ class importexport_wizard_basic_import_csv $sel_options['charset'] = $GLOBALS['egw']->translation->get_installed_charsets()+ array('utf-8' => 'utf-8 (Unicode)'); $preserv = $content; + if($this->mapping_fields['cat_id']) { + $sel_options['update_cats'] = array( + 'add' => lang('Add'), + 'replace'=> lang('Replace') + ); + } else { + $content['no_cats'] = true; + } unset ($preserv['button']); return $this->step_templates[$content['step']]; }