Sha256: cbef80d6c4c05b823a6cf959020a3000043f9c0fcb2d211380d32cc85c4fb284

Contents?: true

Size: 498 Bytes

Versions: 9

Compression:

Stored size: 498 Bytes

Contents

# Provides a method for grabbing sublists
module NSConnector::SubList
	# Grab sublist_id from NetSuite
	# Returns:: An array of SubListItems
	def self.fetch parent, sublist_id, fields
		NSConnector::Restlet.execute!(
			:action => 'fetch_sublist',
			:type_id => parent.type_id,
			:parent_id => parent.id,
			:fields => fields,
			:sublist_id => sublist_id
		).map do |upstream_store|
			NSConnector::SubListItem.new(
				sublist_id,
				fields,
				parent,
				upstream_store
			)
		end
	end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
ns_connector-0.0.14 lib/ns_connector/sublist.rb
ns_connector-0.0.13 lib/ns_connector/sublist.rb
ns_connector-0.0.12 lib/ns_connector/sublist.rb
ns_connector-0.0.11 lib/ns_connector/sublist.rb
ns_connector-0.0.10 lib/ns_connector/sublist.rb
ns_connector-0.0.9 lib/ns_connector/sublist.rb
ns_connector-0.0.8 lib/ns_connector/sublist.rb
ns_connector-0.0.7 lib/ns_connector/sublist.rb
ns_connector-0.0.6 lib/ns_connector/sublist.rb