Class: Google::Apis::ContentV2_1::PosCustomBatchRequestEntry

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/content_v2_1/classes.rb,
generated/google/apis/content_v2_1/representations.rb,
generated/google/apis/content_v2_1/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ PosCustomBatchRequestEntry

Returns a new instance of PosCustomBatchRequestEntry.



7454
7455
7456
# File 'generated/google/apis/content_v2_1/classes.rb', line 7454

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#batch_idFixnum

An entry ID, unique within the batch request. Corresponds to the JSON property batchId

Returns:

  • (Fixnum)


7411
7412
7413
# File 'generated/google/apis/content_v2_1/classes.rb', line 7411

def batch_id
  @batch_id
end

#inventoryGoogle::Apis::ContentV2_1::PosInventory

The absolute quantity of an item available at the given store. Corresponds to the JSON property inventory



7416
7417
7418
# File 'generated/google/apis/content_v2_1/classes.rb', line 7416

def inventory
  @inventory
end

#merchant_idFixnum

The ID of the POS data provider. Corresponds to the JSON property merchantId

Returns:

  • (Fixnum)


7421
7422
7423
# File 'generated/google/apis/content_v2_1/classes.rb', line 7421

def merchant_id
  @merchant_id
end

#method_propString

The method of the batch entry. Acceptable values are:

  • "delete"
  • "get"
  • "insert"
  • "inventory"
  • "sale" Corresponds to the JSON property method

Returns:

  • (String)


7432
7433
7434
# File 'generated/google/apis/content_v2_1/classes.rb', line 7432

def method_prop
  @method_prop
end

#saleGoogle::Apis::ContentV2_1::PosSale

The change of the available quantity of an item at the given store. Corresponds to the JSON property sale



7437
7438
7439
# File 'generated/google/apis/content_v2_1/classes.rb', line 7437

def sale
  @sale
end

#storeGoogle::Apis::ContentV2_1::PosStore

Store resource. Corresponds to the JSON property store



7442
7443
7444
# File 'generated/google/apis/content_v2_1/classes.rb', line 7442

def store
  @store
end

#store_codeString

The store code. Set this only if the method is delete or get. Corresponds to the JSON property storeCode

Returns:

  • (String)


7447
7448
7449
# File 'generated/google/apis/content_v2_1/classes.rb', line 7447

def store_code
  @store_code
end

#target_merchant_idFixnum

The ID of the account for which to get/submit data. Corresponds to the JSON property targetMerchantId

Returns:

  • (Fixnum)


7452
7453
7454
# File 'generated/google/apis/content_v2_1/classes.rb', line 7452

def target_merchant_id
  @target_merchant_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



7459
7460
7461
7462
7463
7464
7465
7466
7467
7468
# File 'generated/google/apis/content_v2_1/classes.rb', line 7459

def update!(**args)
  @batch_id = args[:batch_id] if args.key?(:batch_id)
  @inventory = args[:inventory] if args.key?(:inventory)
  @merchant_id = args[:merchant_id] if args.key?(:merchant_id)
  @method_prop = args[:method_prop] if args.key?(:method_prop)
  @sale = args[:sale] if args.key?(:sale)
  @store = args[:store] if args.key?(:store)
  @store_code = args[:store_code] if args.key?(:store_code)
  @target_merchant_id = args[:target_merchant_id] if args.key?(:target_merchant_id)
end