<% activity_fields = TimeEntryActivityCustomField.find(:all, :conditions => ['field_format IN (?)', ['list','bool']]) %>
Please enable JavaScript, this page will not function without it.
<%= javascript_tag("$('hide-if-js').hide();") %>

<%= select_tag('settings[custom_field]', '' + options_from_collection_for_select(activity_fields, :id, :name, @settings['custom_field'].to_i)) %>

<%= select_tag('settings[billable_value]', '') %>

<%= select_tag('settings[overhead_value]', '') %>

<%# TODO: optimize JavaScript below to not use multiple requests. %> <%= observe_field(:settings_custom_field, :url => { :controller => 'overhead_time_entry_activity', :action => 'index'}, :with => 'custom_field', :update => :settings_billable_value) %> <%= observe_field(:settings_custom_field, :url => { :controller => 'overhead_time_entry_activity', :action => 'index'}, :with => 'custom_field', :update => :settings_overhead_value) %>