Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <h1 class="title">
- <%= @movie.title %>
- </h1>
- <% if user_signed_in? %>
- <% classification = @movie.classifications.where(user_id: current_user.id).first %>
- <% if classification %>
- <h4>
- Your Score: <%= classification.score %>
- </h4>
- <% else %>
- <%= form_for Classification.new, url: "/movies/#{@movie.id}/classifications" do |f| %>
- <div class="field">
- <%= f.label :score %>
- <%= f.text_field :score %>
- </div>
- <%= submit_tag "Set score", :id => "submit" %>
- <% end %>
- <% end %>
- <% end %>
- <p>
- <strong>Release date:</strong>
- <%= @movie.release_date %>
- </p>
- <p>
- <strong>Description:</strong>
- <%= @movie.description %>
- </p>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement