Blesta Source Documentation

PresenterInterface

Presenter interface

Table of Contents

Methods

collection() Retrieves the collection used by the presenter
discounts() Retrieves the discounts for all items in the collection
items() Retrieves a set of all items in the collection
taxes() Retrieves the taxes for all items in the collection
totals() Retrieves totals for all items in the collection
Methods

collection()

Retrieves the collection used by the presenter

public collection() : ItemPriceCollection
Return values
ItemPriceCollection

The instance of the ItemPriceCollection

discounts()

Retrieves the discounts for all items in the collection

public discounts() : array<string|int, mixed>
Return values
array<string|int, mixed>

An array of stdClass objects representing each discount, including:

  • description The discount description
  • amount The discount amount
  • type The discount type
  • total The total amount actually discounted

items()

Retrieves a set of all items in the collection

public items() : array<string|int, mixed>
Return values
array<string|int, mixed>

An array of stdClass objects representing each item, including:

  • description The item description
  • price The item unit price
  • qty The item quantity
  • subtotal The item subtotal
  • total The item total
  • total_after_tax The item total including tax
  • total_after_discount The item total after discount
  • tax_amount The total item tax
  • discount_amount The total item discount

taxes()

Retrieves the taxes for all items in the collection

public taxes() : array<string|int, mixed>
Return values
array<string|int, mixed>

An array of stdClass objects representing each tax, including:

  • description The tax description
  • amount The tax amount
  • type The tax type
  • total The total amount actually taxed

totals()

Retrieves totals for all items in the collection

public totals() : stdClass
Return values
stdClass

An stdClass of total information:

  • subtotal The collection's subtotal
  • total The collection's total
  • total_after_tax The collection's total after tax
  • total_after_discount The collection's total after discount
  • tax_amount The collection's total tax
  • discount_amount The collection's total discount
Tags
subpackage

core.Pricing.Presenter.Type

copyright

Copyright (c) 2019, Phillips Data, Inc.

license

http://www.blesta.com/license/ The Blesta License Agreement

link

Blesta


        
On this page

Search results