Kouhei Sutou
null+****@clear*****
Wed Jul 5 15:52:01 JST 2017
Kouhei Sutou 2017-07-05 15:52:01 +0900 (Wed, 05 Jul 2017) New Revision: 63c75d320baaf05608cbd1333069e64420e91246 https://github.com/ranguba/chupa-text-http-server/commit/63c75d320baaf05608cbd1333069e64420e91246 Message: Clean URL Modified files: app/controllers/extractions_controller.rb app/views/extractions/create.html.erb config/routes.rb Renamed files: app/views/extractions/show.html.erb (from app/views/extractions/new.html.erb) Modified: app/controllers/extractions_controller.rb (+2 -2) =================================================================== --- app/controllers/extractions_controller.rb 2017-07-05 15:39:13 +0900 (ee9d85c) +++ app/controllers/extractions_controller.rb 2017-07-05 15:52:01 +0900 (780831a) @@ -1,6 +1,6 @@ class ExtractionsController < ApplicationController - # GET /extractions/new - def new + # GET /extractions/show + def show @extraction = Extraction.new end Modified: app/views/extractions/create.html.erb (+1 -1) =================================================================== --- app/views/extractions/create.html.erb 2017-07-05 15:39:13 +0900 (ec1a8f4) +++ app/views/extractions/create.html.erb 2017-07-05 15:52:01 +0900 (db1cc33) @@ -2,4 +2,4 @@ <%= render 'form', extraction: @extraction %> -<pre><%= JSON.pretty_generate(@extraction.extract) %></pre> +<pre><code><%= JSON.pretty_generate(@extraction.extract) %></code>e</pre> Renamed: app/views/extractions/show.html.erb (+0 -0) 100% =================================================================== Modified: config/routes.rb (+3 -1) =================================================================== --- config/routes.rb 2017-07-05 15:39:13 +0900 (13d8093) +++ config/routes.rb 2017-07-05 15:52:01 +0900 (c954665) @@ -1,5 +1,7 @@ Rails.application.routes.draw do # For details on the DSL available within this file, see http://guides.rubyonrails.org/routing.html - resource :extraction, only: [:new, :create] + resource :extraction, only: [:show, :create] + + root to: redirect("/extractions") end -------------- next part -------------- HTML����������������������������...下载