Sale library handling sale processing, registration, and management in CodeIgniter.
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');
/**
* Sale library
*
* Library with utilities to manage sales
*/
class Sale_lib
{
private $CI;
public function __construct()
{
$this->CI =& get_instance();
$this->CI->load->library('tax_lib');
$this->CI->load->model('enums/Rounding_mode');
}
public function get_line_sequence_options()
{
return array(
'0' => $this->CI->lang->line('sales_entry'),
'1' => $this->CI->lang->line('sales_group_by_type'),
'2' => $this->CI->lang->line('sales_group_by_category')
);
}
public function get_register_mode_options()
{
$register_modes = array();
if($this->CI->config->item('invoice_enable') == '0')
{
$register_modes['sale'] = $this->CI->lang->line('sales_sale');
}
else
{
$register_m
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search 40K more like it.
Get a free API key