def render_json_seed(records, options = {})
      if records.respond_to?(:to_model)
        name = records.to_model.class.model_name.to_s.split('::').last.underscore.downcase
        render_json_partial(['pageflow/editor', name.pluralize, name.singularize] * '/', name.singularize.to_sym => records)
      else
        return '[]'.html_safe if records.empty?
        name = records.first.to_model.class.model_name.to_s.split('::').last.underscore.downcase
        render_json_partial(['pageflow/editor', name.pluralize, name.singularize] * '/', :collection => records, :as => name.singularize.to_sym)
      end
    end
def render_json_seed(records, options = {})
      if records.respond_to?(:to_model)
        name = records.to_model.class.model_name.to_s.split('::').last.underscore.downcase
        render_json_partial(['pageflow/editor', name.pluralize, name.singularize] * '/', name.singularize.to_sym => records)
      else
        return '[]'.html_safe if records.empty?
        name = records.first.to_model.class.model_name.to_s.split('::').last.underscore.downcase
        render_json_partial(['pageflow/editor', name.pluralize, name.singularize] * '/', :collection => records, :as => name.singularize.to_sym)
      end
    end
Renders `image_files/_image_file.json.jbuilder` when given a
 collection of `ImageFile` records.