changeset 1387:765e83814c28 luisf

Removes logic from view.
author luisf <luis.figueira@eecs.qmul.ac.uk>
date Tue, 24 Sep 2013 18:20:21 +0100
parents e4c393cebb1a
children cfa9122bb584
files plugins/redmine_bibliography/app/views/publications/_authorship_fields.html.erb
diffstat 1 files changed, 11 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/redmine_bibliography/app/views/publications/_authorship_fields.html.erb	Tue Sep 24 16:25:05 2013 +0100
+++ b/plugins/redmine_bibliography/app/views/publications/_authorship_fields.html.erb	Tue Sep 24 18:20:21 2013 +0100
@@ -6,7 +6,7 @@
 <%- end -%>
 
 <div id="authors" class="fields">
-  <div id="<%= form_tag_id( f.object_name, :search_author ) %>" style=<%= "display:none;" unless params[:action] == "new" %> >
+  <div id="<%= form_tag_id( f.object_name, :search_author ) %>" >
     <p>
       <%= f.text_field :search_name, :size => 25, :class => "author_search" %>
     </p>
@@ -16,23 +16,23 @@
     <p class="author_identify">
       <label class='inline'><%= radio_button_tag(:identify_author, "yes", false, :name => form_tag_name(f.object_name,:identify_author ), :id => form_tag_id( f.object_name, :identify_author_yes )) %> <%= l(:identify_author_yes) %> </label><br />
 
-    <label class='inline'><%= radio_button_tag(:identify_author, "correct", false, :name => form_tag_name(f.object_name,:identify_author ), :id => form_tag_id( f.object_name, :identify_author_corrections )) %> <%= l(:identify_author_correct) %> </label><br />
+      <label class='inline'><%= radio_button_tag(:identify_author, "correct", false, :name => form_tag_name(f.object_name,:identify_author ), :id => form_tag_id( f.object_name, :identify_author_corrections )) %> <%= l(:identify_author_correct) %> </label><br />
 
-    <label class='inline'><%= radio_button_tag(:identify_author, "no", true, :name => form_tag_name(f.object_name,:identify_author ), :id => form_tag_id( f.object_name, :identify_author_no )) %> <%= l(:identify_author_no) %> </label><br />
+      <label class='inline'><%= radio_button_tag(:identify_author, "no", true, :name => form_tag_name(f.object_name,:identify_author ), :id => form_tag_id( f.object_name, :identify_author_no )) %> <%= l(:identify_author_no) %> </label><br />
     </p>
-    </div>
+  </div>
 
   <div class='author_edit' id="<%= form_tag_id( f.object_name, :edit_author_info ) %>">
-    <p><%= f.text_field :name_on_paper, {:class => ("readonly" unless params[:action] == "new") } %></p>
-    <p class='description' style=<%= "display:none;" unless params[:action] == "new" %>><%= h l("text_author_name_on_paper") %></p>
+    <p><%= f.text_field :name_on_paper -%></p>
+    <p class="description"><%= h l("text_author_name_on_paper") -%></p>
 
-    <p><%= f.text_field :institution, {:class => ("readonly" unless params[:action] == "new") }  %></p>
-    <p class='description' style=<%= "display:none;" unless params[:action] == "new" %>><%= h l("text_author_institution") %></p>
-    <p><%= f.text_field :email, {:class => ("readonly" unless params[:action] == "new") }  %></p>
-    <p class='description' style=<%= "display:none;" unless params[:action] == "new" %>><%= h l("text_author_email") %></p>
+    <p><%= f.text_field :institution -%></p>
+    <p class="description"><%= h l("text_author_institution") %></p>
+
+    <p><%= f.text_field :email -%></p>
+    <p class="description"><%= h l("text_author_email") %></p>
 
     <%= hidden_field_tag(:search_author_class, '', :name => form_tag_name(f.object_name,:search_author_class ), :id => form_tag_id( f.object_name, :search_author_class )) -%>
-
     <%= hidden_field_tag(:search_author_id, '', :name => form_tag_name(f.object_name,:search_author_id ), :id => form_tag_id( f.object_name, :search_author_id )) -%>
   </div>