Sha256: 880736082d4ee95922774267c5bac7af5fc10b28eea75696cde7304384cdeca6

Contents?: true

Size: 460 Bytes

Versions: 4

Compression:

Stored size: 460 Bytes

Contents

module PublishMyData
  class PropertyRenderParams

    def initialize(resource)
      @resource = resource
      @property = resource.as_property
    end

    def render_params(opts={})

      if opts[:is_html]
        @resource.eager_load_predicate_triples!(:labels_only => true)
        @resource.eager_load_object_triples!(:labels_only => true)
      end

      {template: 'publish_my_data/properties/show', locals: {property: @property}}
    end

  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
publish_my_data-0.0.24 lib/publish_my_data/render_params/property_render_params.rb
publish_my_data-0.0.23 lib/publish_my_data/render_params/property_render_params.rb
publish_my_data-0.0.22 lib/publish_my_data/render_params/property_render_params.rb
publish_my_data-0.0.21 lib/publish_my_data/render_params/property_render_params.rb