lib/seek/preview_handling.rb
def preview_partial
      if lookup_context.find_all("#{controller_name}/_resource_preview").any?
        "#{controller_name}/resource_preview"
      else
        'assets/resource_preview'
      end
    end
# determine if a specific partial exists for the controller, otherwise use the general assets/resource_preview partial
determine if a specific partial exists for the controller, otherwise use the general assets/resource_preview partial
determine if a specific partial exists for the controller otherwise use the general assets / resource_preview partial
def preview_partial
      if lookup_context.find_all("#{controller_name}/_resource_preview").any?
        "#{controller_name}/resource_preview"
      else
        'assets/resource_preview'
      end
    end
def preview_partial if lookup_context . find_all ( "#{controller_name}/_resource_preview" ) . any? "#{controller_name}/resource_preview" else 'assets/resource_preview' end end
determine if a specific partial exists for the controller, otherwise use the general assets/resource_preview partial
determine if a specific partial exists for the controller otherwise use the general assets / resource_preview partial