From efb48636914ed5b5d74417091887ab7314f47bea Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Thu, 24 Feb 2011 10:14:43 +0100 Subject: [PATCH] Kosmetik, Typos --- SL/Helper/Csv.pm | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/SL/Helper/Csv.pm b/SL/Helper/Csv.pm index 092ba37e8..2b059bbd9 100644 --- a/SL/Helper/Csv.pm +++ b/SL/Helper/Csv.pm @@ -203,11 +203,12 @@ SL::Helper::Csv - take care of csv file uploads file => \$::form->{upload_file}, encoding => 'utf-8', # undef means utf8 sep_char => ',', # default ';' - quote_char => ''', # default '"' - header => [qw(id text sellprice word)] # see later - profile => { sellprice => 'sellprice_as_number' } + quote_char => '\'', # default '"' + escape_char => '"', # default '"' + header => [qw(id text sellprice word)], # see later + profile => { sellprice => 'sellprice_as_number' }, class => 'SL::DB::CsvLine', # if present, map lines to this - ) + ); my $status = $csv->parse; my $hrefs = $csv->get_data; @@ -265,7 +266,7 @@ scalar ref for memory data. =item C Encoding of the CSV file. Note that this module does not do any encoding -guessing. Know what your data ist. Defaults to utf-8. +guessing. Know what your data is. Defaults to utf-8. =item C @@ -292,7 +293,7 @@ C column. In case of a One-To-One relationsship these can also be set over relationsships by sparating the steps with a dot (C<.>). This will work: - { customer => customer.name } + { customer => 'customer.name' } And will result in something like this: @@ -325,7 +326,7 @@ Each entry is an arrayref with the following structure: [ 0 offending raw input, - 1 Text::CSV error code if T:C error, 0 else, + 1 Text::CSV error code if Text:CSV signalled an error, 0 else, 2 error diagnostics, 3 position in line, 4 estimated line in file, -- 2.20.1