mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-04-08 08:57:50 -04:00
Suspending Work Order lost work order number
This commit is contained in:
@@ -958,6 +958,7 @@ class Sale_lib
|
||||
$this->set_customer($this->CI->Sale->get_customer($sale_id)->person_id);
|
||||
$this->set_employee($this->CI->Sale->get_employee($sale_id)->person_id);
|
||||
$this->set_quote_number($this->CI->Sale->get_quote_number($sale_id));
|
||||
$this->set_work_order_number($this->CI->Sale->get_work_order_number($sale_id));
|
||||
$this->set_sale_type($this->CI->Sale->get_sale_type($sale_id));
|
||||
$this->set_comment($this->CI->Sale->get_comment($sale_id));
|
||||
$this->set_dinner_table($this->CI->Sale->get_dinner_table($sale_id));
|
||||
|
||||
@@ -1310,6 +1310,26 @@ class Sale extends CI_Model
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the work order number for the selected sale
|
||||
*/
|
||||
public function get_work_order_number($sale_id)
|
||||
{
|
||||
$this->db->from('sales');
|
||||
$this->db->where('sale_id', $sale_id);
|
||||
|
||||
$row = $this->db->get()->row();
|
||||
|
||||
if($row != NULL)
|
||||
{
|
||||
return $row->work_order_number;
|
||||
}
|
||||
else
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the quote_number for the selected sale
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user