comparison app/helpers/.svn/text-base/settings_helper.rb.svn-base @ 37:94944d00e43c

* Update to SVN trunk rev 4411
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Fri, 19 Nov 2010 13:24:41 +0000
parents 513646585e45
children cbce1fd3b1b7
comparison
equal deleted inserted replaced
22:40f7cfd4df19 37:94944d00e43c
69 69
70 def setting_label(setting, options={}) 70 def setting_label(setting, options={})
71 label = options.delete(:label) 71 label = options.delete(:label)
72 label != false ? content_tag("label", l(label || "setting_#{setting}")) : '' 72 label != false ? content_tag("label", l(label || "setting_#{setting}")) : ''
73 end 73 end
74
75 # Renders a notification field for a Redmine::Notifiable option
76 def notification_field(notifiable)
77 return content_tag(:label,
78 check_box_tag('settings[notified_events][]',
79 notifiable.name,
80 Setting.notified_events.include?(notifiable.name)) +
81 l_or_humanize(notifiable.name, :prefix => 'label_'),
82 :class => notifiable.parent.present? ? "parent" : '')
83 end
74 end 84 end