diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 3a40fd2..6476fba 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -1119,6 +1119,12 @@ module ApplicationHelper link_to_function(l(:button_uncheck_all), "checkAll('#{form_name}', false)") end + def toggle_checkboxes_link(selector) + link_to_function image_tag('toggle_check.png'), + "toggleCheckboxesBySelector('#{selector}')", + :title => "#{l(:button_check_all)} / #{l(:button_uncheck_all)}" + end + def progress_bar(pcts, options={}) pcts = [pcts, pcts] unless pcts.is_a?(Array) pcts = pcts.collect(&:round) diff --git a/app/views/principal_memberships/_new_form.html.erb b/app/views/principal_memberships/_new_form.html.erb index bdd7df6..2a0d50d 100644 --- a/app/views/principal_memberships/_new_form.html.erb +++ b/app/views/principal_memberships/_new_form.html.erb @@ -1,5 +1,5 @@