Sha256: 9b06a033f0ba16a5bf05cdfbfcce0bce6aeb149683f2074b82fce20b40ae12b5

Contents?: true

Size: 394 Bytes

Versions: 1

Compression:

Stored size: 394 Bytes

Contents

require "transformator/transformation/step"
require_relative "../request_transformation"

class Skala::PrimoAdapter::Search::RequestTransformation::
  SetOnCampus < Transformator::Transformation::Step

  def call
    transformation.inner_search_request.locate("onCampus").first.tap do |_node|
      _node << (transformation.on_campus.try(:to_s) == "true" ? "true" : "false")
    end
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
skala-1.1.0 lib/skala/primo_adapter/search/request_transformation/set_on_campus.rb