available_values are now loaded on user request (ajax) - fixes #3490
git-svn-id: https://dev.finn.de/svn/cockpit/branches/reporting_merge@1813 7926756e-e54e-46e6-9721-ed318f58905epull/6827/head
parent
74863dd77e
commit
b2e571738c
@ -0,0 +1,5 @@ |
||||
<% @available_values.each do |name, id, *args| %> |
||||
<%= render :partial => 'cost_reports/filters/available_value', |
||||
:locals => { :name => name, :id => id, :level => args.first }, |
||||
:layout => !request.xhr? %> |
||||
<% end %> |
@ -0,0 +1,11 @@ |
||||
<%# |
||||
This partial requires the following locals: |
||||
name String: The displayed name of the option |
||||
id Integer: The id the option refers to |
||||
level Integer: The indendation level of this option |
||||
%> |
||||
|
||||
<% name_prefix = ((level && level > 0) ? (' ' * 2 * level + '» ') : '') %> |
||||
<option value="<%= id %>"> |
||||
<%= name_prefix + h(name) %> |
||||
</option> |
Loading…
Reference in new issue