Nutzung der Tabelle currencies
[kivitendo-erp.git] / SL / Controller / CsvImport / Base.pm
index eb46b26..7f4326a 100644 (file)
@@ -153,6 +153,10 @@ sub init_all_vc {
            vendors   => SL::DB::Manager::Vendor->get_all };
 }
 
+sub force_allow_columns {
+  return ();
+}
+
 sub init_vc_by {
   my ($self)    = @_;
 
@@ -222,6 +226,8 @@ sub init_profile {
   eval "require " . $self->class;
 
   my %unwanted = map { ( $_ => 1 ) } (qw(itime mtime), map { $_->name } @{ $self->class->meta->primary_key_columns });
+  delete $unwanted{$_} for ($self->force_allow_columns);
+
   my %profile;
   for my $col ($self->class->meta->columns) {
     next if $unwanted{$col};
@@ -428,7 +434,6 @@ sub clean_fields {
   my @cleaned_fields;
   foreach my $field (grep { $object->can($_) } @fields) {
     my $value = $object->$field;
-    $::lxdebug->message(0, "field $field value $value ill $illegal_chars");
 
     next unless defined($value) && ($value =~ s/$illegal_chars/ /g);