batch_api icon indicating copy to clipboard operation
batch_api copied to clipboard

Rails 4 and Ruby 2.1 issue.

Open misteral opened this issue 11 years ago • 1 comments

What about Rails 4 and Ruby 2.1. When i'am implement batch_api and rails 4 app. PUT method in ops[] response 404, GET and POST method - ok. my query:

{"ops": [ {"method": "PUT", "url": "/api/stock_locations/1/stock_items/1", "params":{"stock_item":{"count_on_hand":"2"}} }, {"method": "get","url": "/api/stock_locations/1/stock_items/1"} ], "sequential": "true"}

UPDATED: params on rails controller after batch_api {"stock_item"=>{"count_on_hand"=>"2"}}

params on rails controller after direct request {"stock_item"=>{"count_on_hand"=>"2"}, "format"=>"json", "action"=>"update", "controller"=>"spree/api/stock_items", "stock_location_id"=>"1", "id"=>"2"}

misteral avatar Jan 11 '14 09:01 misteral

i started working on some issues and updated it to ruby 2.0.0 and rails 4.1.1

you can check it out here:

https://github.com/easyPEP/batch_api/tree/feature_ruby_2

fluxsaas avatar May 28 '14 16:05 fluxsaas