CORE POS - IS4C
The CORE POS front end
Public Member Functions | Static Public Attributes | Protected Attributes | List of all members
PriceMethod Class Reference
Inheritance diagram for PriceMethod:
ABGroupPM BasicPM BigGroupPM GroupPM MoreThanQttyPM NoDiscOnSalesPM QttyEnforcedGroupPM SplitABGroupPM

Public Member Functions

 addItem ($row, $quantity, $priceObj)
 
 errorInfo ()
 

Static Public Attributes

static $MAP
 

Protected Attributes

 $savedRow
 
 $savedInfo
 

Detailed Description

Base class for handling different price methods

These modules add an item to the transaction

The default case is to add an item with the specified price (BasicPM) but other methods with group deals, buy-one-get-one, etc can get really convoluted. UPC parsing is easier to follow with that code relegated to a module.

Stores can also swap out modules as needed and rearrange them so products.pricemethod=X doesn't need to mean the same thing at every store.

Member Function Documentation

PriceMethod::addItem (   $row,
  $quantity,
  $priceObj 
)

Add the item to the transaction

Parameters
$rowA product table record
$quantityScan quantity
$priceObjA DiscountType object
Returns
boolean success/failure
PriceMethod::errorInfo ( )

Information about error(s) adding the item to the transaction

Returns
string message

Member Data Documentation

PriceMethod::$MAP
static
Initial value:
= array(
0 => 'BasicPM',
1 => 'GroupPM',
2 => 'QttyEnforcedGroupPM',
3 => 'SplitABGroupPM',
4 => 'ABGroupPM',
5 => 'BigGroupPM',
6 => 'MoreThanQttyPM',
)

The documentation for this class was generated from the following file: