<%= best_in_place @mega_display[:model_display], :header, tabindex: "1", url: @model_display_path %>

<%= best_in_place @mega_display[:model_display], :instructions, url: @model_display_path, as: :textarea %>
<%= form_tag @mega_display[:form_path] + '/filter' do %> <%=@mf.app_wrapper.html_safe%> <% if @filter_text && might_filter? %> Current Filters: <%= @filter_text.join(', ') %>
<%= submit_tag 'clear_filters' %> <% end %> <% if might_paginate?('top') %> <%= paginate @mega_instance, :param_name => "#{@kontroller_inst}_page", theme: @mega_display[:collection_settings]&.pagination_theme %> <%= render partial: "mega_bar_help_links", :locals => {:links => model_display_collection_help_links} %> <% end %> <% if @mf.separate_header_row == 'true' %> <% @mega_display[:displayable_fields].each do | displayable_field | %> <%= @mf.field_header_wrapper.html_safe%> <%= render partial: "mega_bar_inline_help_links", :locals => {:links => reorder_up(displayable_field, 'left')} %> <%= sortable(displayable_field[:field].field, displayable_field[:field_display].header) %> <%= render partial: "mega_bar_inline_help_links", :locals => {:links => reorder_down(displayable_field, 'right')} %> <%= @mf.field_header_wrapper_end.html_safe%> <% end %>       Position <% end %> <% @mega_instance.each do |mega_record| %> <%= @mf.record_wrapper.html_safe%> <% @mega_display[:displayable_fields].each do | displayable_field | %> <% @field_display_path = MegaBar::Engine.routes.url_for(controller: '/mega_bar/field_displays', action: 'show', id: displayable_field[:field_display].id, :only_path=> true) %> <% if @mf.name == 'ProfileTable' %> <%= render partial: "mega_bar_inline_help_links", :locals => {:links => reorder_up(displayable_field, 'up')} %> <%= best_in_place displayable_field[:field_display], :header, url: @field_display_path %> <%= render partial: "mega_bar_inline_help_links", :locals => {:links => reorder_down(displayable_field, 'down')} %> <% end %> <%= @mf.field_wrapper.html_safe%> <% data = render template: displayable_field[:field_display].format.tableize + "/show", locals: data_format_locals(mega_record, displayable_field) %> <% if displayable_field[:field_display].link_type == 'link_field_value' && displayable_field[:field_display].format == 'textread' %> <% end %> <%= data %> <% if displayable_field[:field_display].link_type == 'link_field_value' && displayable_field[:field_display].format == 'textread' %> <% end %> <%= @mf.field_wrapper_end.html_safe %> <% if @mf.name == 'ProfileTable' %> <% end %> <% end %> <% if @mf.name == 'GridHtml' %> <%= link_to 'Show '.html_safe, link_path('show', mega_record.id) %> <%= link_to 'Edit '.html_safe, link_path('edit', mega_record.id) %> <%= link_to 'Destroy '.html_safe, mega_record, method: :delete, data: { confirm: 'Are you sure?' } %> <% if @mega_model_properties.position_parent.present? && @nested_ids.map{|nid| true if nid.key?((@mega_model_properties.position_parent.split("::").last.underscore.downcase + "_id")) }.first %> <% unless @mega_instance.first.position == mega_record.position %> <%= link_to 'up', link_path('move', mega_record.id).to_s + "?method=move_higher", data: { turbolinks: false } %> <%= link_to 'top', link_path('move', mega_record.id).to_s + "?method=move_to_top", data: { turbolinks: false } %> <% end %> <% unless @mega_instance.last.position == mega_record.position %> <% unless mega_record.position == (@mega_instance.first.position || @mega_instance.last.position) %> | <% end %> <%= link_to 'down', link_path('move', mega_record.id).to_s + "?method=move_lower", data: { turbolinks: false } %> <%= link_to 'bottom', link_path('move', mega_record.id).to_s + "?method=move_to_bottom", data: { turbolinks: false } %> <% end %> <% end %> <% end %> <%= @mf.record_wrapper_end.html_safe%> <% end %> <% if might_filter? %> <% @mega_display[:displayable_fields].each do | displayable_field | %> <% @displayable_field = displayable_field %> <% if displayable_field[:field].filter_type.blank? %>   <% else %> <% meth = "filter_#{displayable_field[:field].filter_type}" %> <%= render partial: "filters", locals: {:filterr => eval(meth)} %> <% end %> <% end %> <%= submit_tag 'Filter' %> <% end %> <%=@mf.app_wrapper_end.html_safe%> <% end %> <% if might_paginate?('bottom') %> <%= paginate @mega_instance, :param_name => "#{@kontroller_inst}_page" %> <%= render partial: "mega_bar_help_links", :locals => {:links => model_display_collection_help_links} %> <% end %>