% case object%> <% when PagePart %> <% object_name = 'page_part' %> <% field_name = 'widget_field' %> <% data_count = 'widget_data_count' %> <% when Page %> <% object_name = 'page' %> <% field_name = 'frontend_field' %> <% data_count = 'frontend_data_count' %> <% end %>