Sha256: fce7bbae61b9948ff3ceb039d782ccf2810f2036a5a55700b269eeceed1efe01

Contents?: true

Size: 1.6 KB

Versions: 16

Compression:

Stored size: 1.6 KB

Contents

# typed: false
# frozen_string_literal: true

module ShopifyAPI
  class LocationsForMove < ShopifyAPI::Rest::Base
    extend T::Sig

    @prev_page_info = T.let(Concurrent::ThreadLocalVar.new { nil }, Concurrent::ThreadLocalVar)
    @next_page_info = T.let(Concurrent::ThreadLocalVar.new { nil }, Concurrent::ThreadLocalVar)

    sig { params(session: T.nilable(ShopifyAPI::Auth::Session)).void }
    def initialize(session: ShopifyAPI::Context.active_session)
      super(session: session)

      @locations_for_move = T.let(nil, T.nilable(T::Array[T.untyped]))
    end

    @has_one = T.let({}, T::Hash[Symbol, Class])
    @has_many = T.let({}, T::Hash[Symbol, Class])
    @paths = T.let([
      {http_method: :get, operation: :get, ids: [:fulfillment_order_id], path: "fulfillment_orders/<fulfillment_order_id>/locations_for_move.json"}
    ], T::Array[T::Hash[String, T.any(T::Array[Symbol], String, Symbol)]])

    sig { returns(T.nilable(T::Array[T::Hash[T.untyped, T.untyped]])) }
    attr_reader :locations_for_move

    class << self
      sig do
        params(
          fulfillment_order_id: T.nilable(T.any(Integer, String)),
          session: Auth::Session,
          kwargs: T.untyped
        ).returns(T::Array[LocationsForMove])
      end
      def all(
        fulfillment_order_id: nil,
        session: ShopifyAPI::Context.active_session,
        **kwargs
      )
        response = base_find(
          session: session,
          ids: {fulfillment_order_id: fulfillment_order_id},
          params: {}.merge(kwargs).compact,
        )

        T.cast(response, T::Array[LocationsForMove])
      end

    end

  end
end

Version data entries

16 entries across 4 versions & 1 rubygems

Version Path
shopify_api-10.0.3 lib/shopify_api/rest/resources/2021_07/locations_for_move.rb
shopify_api-10.0.3 lib/shopify_api/rest/resources/2022_01/locations_for_move.rb
shopify_api-10.0.3 lib/shopify_api/rest/resources/2021_10/locations_for_move.rb
shopify_api-10.0.3 lib/shopify_api/rest/resources/2022_04/locations_for_move.rb
shopify_api-10.0.2 lib/shopify_api/rest/resources/2021_10/locations_for_move.rb
shopify_api-10.0.2 lib/shopify_api/rest/resources/2021_07/locations_for_move.rb
shopify_api-10.0.2 lib/shopify_api/rest/resources/2022_01/locations_for_move.rb
shopify_api-10.0.2 lib/shopify_api/rest/resources/2022_04/locations_for_move.rb
shopify_api-10.0.1 lib/shopify_api/rest/resources/2022_04/locations_for_move.rb
shopify_api-10.0.1 lib/shopify_api/rest/resources/2021_10/locations_for_move.rb
shopify_api-10.0.1 lib/shopify_api/rest/resources/2021_07/locations_for_move.rb
shopify_api-10.0.1 lib/shopify_api/rest/resources/2022_01/locations_for_move.rb
shopify_api-10.0.0 lib/shopify_api/rest/resources/2021_07/locations_for_move.rb
shopify_api-10.0.0 lib/shopify_api/rest/resources/2022_01/locations_for_move.rb
shopify_api-10.0.0 lib/shopify_api/rest/resources/2022_04/locations_for_move.rb
shopify_api-10.0.0 lib/shopify_api/rest/resources/2021_10/locations_for_move.rb