myexperiment-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[myexperiment-hackers] [3136] branches/wf4ever/app/controllers/research_


From: noreply
Subject: [myexperiment-hackers] [3136] branches/wf4ever/app/controllers/research_objects_controller.rb: added ability to POST to /research_objects with content type of text/ turtle
Date: Wed, 26 Sep 2012 07:18:42 +0000 (UTC)

Revision
3136
Author
dgc
Date
2012-09-26 07:18:40 +0000 (Wed, 26 Sep 2012)

Log Message

added ability to POST to /research_objects with content type of text/turtle

Modified Paths

Diff

Modified: branches/wf4ever/app/controllers/research_objects_controller.rb (3135 => 3136)


--- branches/wf4ever/app/controllers/research_objects_controller.rb	2012-09-25 17:32:46 UTC (rev 3135)
+++ branches/wf4ever/app/controllers/research_objects_controller.rb	2012-09-26 07:18:40 UTC (rev 3136)
@@ -72,6 +72,9 @@
     # get url (if provided)
     url = "" if ro_params[:url].is_a?(String) && !ro_params[:url].empty?
 
+    # get request body (if provided)
+    file = request.raw_post if request.raw_post != nil && request.env["CONTENT_TYPE"] == "text/turtle"
+
     # get uploaded file (if provided)
     file = ro_params[:data].read if ro_params[:data].respond_to?(:read)
 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]