Mercurial > hg > soundsoftware-site
changeset 470:30b36ab6f15a feature_36
Correctly removing authors.
author | luisf <luis.figueira@eecs.qmul.ac.uk> |
---|---|
date | Fri, 24 Jun 2011 11:41:01 +0100 |
parents | ae87ae455cfb |
children | 49fb7a9ef79c |
files | vendor/plugins/redmine_bibliography/app/views/publications/_author_fields.rhtml vendor/plugins/redmine_bibliography/assets/javascripts/authors.js |
diffstat | 2 files changed, 1 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/vendor/plugins/redmine_bibliography/app/views/publications/_author_fields.rhtml Fri Jun 24 11:23:23 2011 +0100 +++ b/vendor/plugins/redmine_bibliography/app/views/publications/_author_fields.rhtml Fri Jun 24 11:41:01 2011 +0100 @@ -3,6 +3,6 @@ <%= f.label :name, l("name") %> <%= f.text_field :name %> <%= f.hidden_field :_destroy %> - <%= link_to_function "Remove", "remove_author(this)" %> + <%= link_to_remove_fields "remove", f %><br /> </p> </div> \ No newline at end of file
--- a/vendor/plugins/redmine_bibliography/assets/javascripts/authors.js Fri Jun 24 11:23:23 2011 +0100 +++ b/vendor/plugins/redmine_bibliography/assets/javascripts/authors.js Fri Jun 24 11:41:01 2011 +0100 @@ -1,8 +1,3 @@ -function remove_author(link){ - $(link).previous('input[type=hidden]').value = 1; - $(link).up('.author_fields').remove(); -} - function remove_fields(link) { $(link).previous("input[type=hidden]").value = "1"; $(link).up(".fields").hide();