draw filename frompth
This commit is contained in:
parent
afc14ba244
commit
69b9cb54c7
1 changed files with 1 additions and 1 deletions
|
@ -70,7 +70,7 @@ module FoodsoftArticleImport
|
||||||
opts[:csv_options][:encoding] = encoding if encoding
|
opts[:csv_options][:encoding] = encoding if encoding
|
||||||
opts[:csv_options][:col_sep] = col_sep if col_sep
|
opts[:csv_options][:col_sep] = col_sep if col_sep
|
||||||
opts[:csv_options][:liberal_parsing] = true if liberal_parsing
|
opts[:csv_options][:liberal_parsing] = true if liberal_parsing
|
||||||
opts[:extension] = File.extname(filename) if filename
|
opts[:extension] = File.extname.File.basename(filename) if filename
|
||||||
begin
|
begin
|
||||||
Roo::Spreadsheet.open(file, **opts)
|
Roo::Spreadsheet.open(file, **opts)
|
||||||
rescue StandardError => e
|
rescue StandardError => e
|
||||||
|
|
Loading…
Reference in a new issue