Skip to content

Commit

Permalink
Article details was created
Browse files Browse the repository at this point in the history
  • Loading branch information
tayfunoziserikan committed Aug 17, 2014
1 parent 7bb54e5 commit ce62f4f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/controllers/articles_controller.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
class ArticlesController < ApplicationController

def show
@article = Article.find(params[:id])
end

def new
end

Expand Down
11 changes: 11 additions & 0 deletions app/views/articles/show.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<h1>Article Details</h1>

<p>
<strong>Title:</strong>
<%= @article.title %>
</p>

<p>
<strong>Text:</strong>
<%= @article.text %>
</p>

0 comments on commit ce62f4f

Please sign in to comment.