CORE POS - IS4C
The CORE POS front end
|
Static Public Member Functions | |
static | printfooter ($readOnly=False) |
static | plainmsg ($strmsg) |
static | msgbox ($strmsg, $icon, $noBeep=false, $buttons=array()) |
static | xboxMsg ($strmsg, $buttons=array()) |
static | boxMsg ($strmsg, $header="", $noBeep=false, $buttons=array()) |
static | inputUnknown () |
static | standardClearButton () |
static | printheaderb () |
static | printItem ($field2, $field3, $total, $field5, $trans_id=-1) |
static | printItemColor ($color, $description, $comments, $total, $suffix, $trans_id=-1) |
static | printItemColorHilite ($color, $description, $comments, $total, $suffix) |
static | scaledisplaymsg ($input="") |
static | termdisplaymsg () |
static | drawNotifications () |
static | listItems ($top_item, $highlight) |
static | printReceiptfooter ($readOnly=False) |
static | drawItems ($top_item, $rows, $highlight) |
static | lastpage ($readOnly=False) |
static | screenDisplay ($min, $max) |
static | touchScreenScrollButtons ($selector='#search') |
Functions for drawing display elements
|
static |
Get a centered message box with "exclaimC" graphic
$strmsg | the message |
$header | title for the box |
$noBeep | don't beep scale |
$buttons | see msgbox() |
An alias for msgbox().
|
static |
Get the currently displayed items
$top_item | is the trans_id of the first item to display |
$rows | is the number of items to display |
$highlight | is the trans_id of the selected item |
This function probably shouldn't be used directly. Call listitems() or lastpage() instead.
30Oct2014 Andy Idea here is to look up the currently displayed items and perform any necessary transformations of the text in PHP instead of tucking that logic inside the screendisplay view. I'm leaving the query above for reference in case I screwed something up and the old method of drawing the screen needs to be quickly re-enabled.
14Nov2014 Andy Disabled for the sake of putting together a release. Will go into testing following the release and be included in the next one
03Dec2014 Andy Axing screen display isn't a super high priority right now With better unit testing in place, I want to write more tests to verify this method behaves the same as the screendisplay via. No ETA at this point.
11Mar14 Andy Ancient idea about displaying transaction line-items on credit card terminal screen. Current terminal does not even support this functionality.
I'm leaving the "get last relevant line" implementation for reference. if (is_object($td) && !empty($last_item)) { $due = sprintf('%.2f',CoreLocal::get("amtdue")); $dueline = 'Subtotal' .str_pad('',22-strlen($due),' ') .$due; $items = ""; $count = 0; for($i=count($last_item)-1;$i>=0;$i–) { $items = ":".$last_item[$i].$items; $count++; if ($count >= 3) break; } for($i=$count;$i<3;$i++) { $items = ": ".$items; } $td->WriteToScale("display:".$last_item.":".$dueline); }
|
static |
Use the right side of the screen to show various notifications
|
static |
|
static |
Get the currently displayed items
$readOnly | don't update session |
This will always display the most recently scanned items. If you want a specific subset, use listitems().
|
static |
Get the items currently on screen
$top_item | is trans_id (localtemptrans) of the first item to display |
$highlight | is the trans_id (localtemptrans) of the currently selected item |
If you just want to show the most recently scanned items, use lastpage().
|
static |
Get a centered message box
$strmsg | the message |
$icon | graphic icon file |
$noBeep | don't send a scale beep |
$buttons | keyed array of touchable/clickable buttons
|
This function will include the header printheaderb().
|
static |
Wrap a message in a id="plainmsg" div
$strmsg | the message |
|
static |
Get the standard footer with total and amount(s) saved
$readOnly | don't update any session info This would be set when rendering a separate, different customer display |
|
static |
Get the standard header row with CASHIER and MEMBER info
|
static |
Get a transaction line item
$field2 | typically description |
$field3 | comment section. Used for things like "0.59@1.99" on weight items. |
$total | the right-hand number |
$field5 | flags after the number |
$trans_id | value from localtemptrans. Including the trans_id makes the lines selectable via mouseclick (or touchscreen). |
|
static |
Get a transaction line item in a specific color
$color | is a hex color code (do not include a '#') (see CSS notes) |
$description | typically description |
$comments | comment section. Used for things like "0.59@1.99" on weight items. |
$total | the right-hand number |
$suffix | flags after the number |
$trans_id | value from localtemptrans. Including the trans_id makes the lines selectable via mouseclick (or touchscreen). |
CSS Notes: In an effort to replace hard-coded colors, some values are re-written as CSS classes rather than inline styles. Current mapping:
|
static |
Get a transaction line item in a specific color
$color | is a hex color code (do not include a '#') (see CSS notes) |
$description | typically description |
$comments | comment section. Used for things like "0.59@1.99" on weight items. |
$total | the right-hand number |
$suffix | flags after the number |
CSS Notes: In an effort to replace hard-coded colors, some values are re-written as CSS classes rather than inline styles. Current mapping:
|
static |
Show some items and farewell message
$readOnly | don't update totals |
Show a few recent items and the "Thank you for shopping" messaging.
Yes, this function should be renamed. It has nothing to do with receipts.
|
static |
Get the scale display box
$input | message from scale |
If $input is specified, weight information in the session gets updated before returning the current value.
Known input values are:
|
static |
Select items from the transaction with formatting for on screen display
$min | [int] minimum localtemptrans.trans_id |
$max | [int] maximum localtemtprans.trans_id |
Each record contains the following keys:
Note: the outer array is indexed by localtemptrans.trans_id instead of zero through array.length.
|
static |
Display CC terminal state
|
static |