Skip to content
Browse files

add update function using POST

  • Loading branch information...
1 parent ee01e14 commit 0ae98c63d75c9e72124c615d99449c931aa4e556 @yono committed
Showing with 5 additions and 0 deletions.
  1. +5 −0 app.rb
View
5 app.rb
@@ -19,6 +19,11 @@ class KitakuTime
erb :index
end
+post '/' do
+ kitakutime = KitakuTime.create(:minute => params[:minute],
+ :target_date => params[:target_date])
+end
+
get '/index.json' do
content_type :json
kitakutime = KitakuTime.all(:order => [:target_date.desc])

0 comments on commit 0ae98c6

Please sign in to comment.
Something went wrong with that request. Please try again.