Skip to content
This repository has been archived by the owner on Dec 12, 2021. It is now read-only.

Commit

Permalink
to rails-2-3-stable
Browse files Browse the repository at this point in the history
  • Loading branch information
barda committed Dec 2, 2010
1 parent 4468a7f commit fe80fa8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/helpers/application_helper.rb
@@ -1,7 +1,7 @@
# Methods added to this helper will be available to all templates in the application. # Methods added to this helper will be available to all templates in the application.
module ApplicationHelper module ApplicationHelper
def remove_child_link(name, f) def remove_child_link(name, f)
f.hidden_field(:_delete) + link_to_function(name, "remove_fields(this)") f.hidden_field(:_destroy) + link_to_function(name, "remove_fields(this)")
end end


def add_child_link(name, f, method) def add_child_link(name, f, method)
Expand Down
4 changes: 2 additions & 2 deletions app/views/projects/_task.html.erb
Expand Up @@ -3,6 +3,6 @@
<%= f.text_field :name %> <%= f.text_field :name %>
<%= remove_child_link "remove", f %> <%= remove_child_link "remove", f %>
<%# Alternatively you can use a check box: %> <%# Alternatively you can use a check box: %>
<%# f.check_box :_delete %> <%#= f.check_box :_destroy %>
<%# f.label :_delete, "(remove)" %> <%#= f.label :_destroy, "(remove)" %>
</div> </div>

0 comments on commit fe80fa8

Please sign in to comment.