class Pohoda::Parsers::Typ::ActionTypeStockItem

Public Instance Methods

add() click to toggle source
# File lib/pohoda/parsers/typ/action_type_stock_item.rb, line 7
def add
  at 'typ:add'
end
add_attributes() click to toggle source
# File lib/pohoda/parsers/typ/action_type_stock_item.rb, line 11
def add_attributes
  attributes_at 'typ:add'
end
delete() click to toggle source
# File lib/pohoda/parsers/typ/action_type_stock_item.rb, line 19
def delete
  submodel_at(Ftr::RequestStockType, 'typ:delete')
end
to_h() click to toggle source
# File lib/pohoda/parsers/typ/action_type_stock_item.rb, line 23
def to_h
  hash = {}
  hash[:attributes] = attributes

  hash[:add] = add if has? 'typ:add'
  hash[:add_attributes] = add_attributes if has? 'typ:add'
  hash[:update] = update.to_h if has? 'typ:update'
  hash[:delete] = delete.to_h if has? 'typ:delete'

  hash
end
update() click to toggle source
# File lib/pohoda/parsers/typ/action_type_stock_item.rb, line 15
def update
  submodel_at(Ftr::RequestStockType, 'typ:update')
end