Class: Workarea::Storefront::CartItemViewModel
- Inherits:
-
OrderItemViewModel
- Object
- ApplicationViewModel
- OrderItemViewModel
- Workarea::Storefront::CartItemViewModel
- Defined in:
- app/view_models/workarea/storefront/cart_item_view_model.rb
Instance Method Summary collapse
Methods inherited from OrderItemViewModel
#catalog_product, #customizations_unit_price, #default_category_name, #details, #fulfillment_sku, #has_options?, #image, #multiple?, #original_price, #product, #product_name, #sku_name, #token, #total_adjustments, #variant
Instance Method Details
#inventory_status ⇒ Object
4 5 6 7 8 |
# File 'app/view_models/workarea/storefront/cart_item_view_model.rb', line 4 def inventory_status InventoryStatusViewModel.new( [:inventory] || Inventory::Sku.find_or_create_by(id: sku) ). end |