From bfd99236be64c521ede7695461e050862fc697cf Mon Sep 17 00:00:00 2001 From: "mattias.vannergard" Date: Thu, 11 Jun 2015 09:49:00 +0200 Subject: [PATCH] Addressing issue #8 Updated spreadsheet gem dependency to 1.0.3, since 0.9.9 is broken. Added specification to match in routes.rb, to be available both via POST and GET. --- Gemfile | 2 +- config/routes.rb | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Gemfile b/Gemfile index d98e1c4..5f07e3c 100644 --- a/Gemfile +++ b/Gemfile @@ -3,6 +3,6 @@ source 'https://rubygems.org' if RUBY_VERSION >= "1.9" gem 'roo' gem 'iconv' - gem'spreadsheet',"~> 0.9.7" + gem'spreadsheet',"~> 1.0.3" end diff --git a/config/routes.rb b/config/routes.rb index ea3de06..b652c0c 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -3,9 +3,9 @@ get '/projects/:project_id/import_issue', :to => 'excel_sheet#index' get '/import_issue', :to => 'excel_sheet#index' post '/upload_sheet', :to => 'excel_sheet#upload_sheet' -match '/generate_excel_sheet', :to => 'excel_sheet#generate_excel_sheet' -match "/settings/plugin/public/uploads/exports/Redmine_Sample_Issue_Sheet.xls" ,:to=>'excel_sheet#export_excel_sheet' -match "/public/uploads/exports/Redmine_Sample_Issue_Sheet.xls",:to=>'excel_sheet#render_excel_sheet' +match '/generate_excel_sheet', :to => 'excel_sheet#generate_excel_sheet', via: [:get, :post] +match "/settings/plugin/public/uploads/exports/Redmine_Sample_Issue_Sheet.xls" ,:to=>'excel_sheet#export_excel_sheet', via: [:get, :post] +match "/public/uploads/exports/Redmine_Sample_Issue_Sheet.xls",:to=>'excel_sheet#render_excel_sheet', via: [:get, :post] # resources :excel_sheet do # get 'generate_excel_sheet', on: :generate_excel_sheet # end