mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-10-07 01:52:20 -04:00
Fix delete in Item model (#507)
This commit is contained in:
1 parent
de711b82dd
commit
488af06663
1 file changed
+1
-3
@@ -248,11 +248,9 @@ class Item extends CI_Model
|
||||
*/
|
||||
public function delete($item_id)
|
||||
{
|
||||
$this->db->where('item_id', $item_id);
|
||||
|
||||
// set to 0 quantities
|
||||
$this->Item_quantity->reset_quantity($item_id);
|
||||
|
||||
$this->db->where('item_id', $item_id);
|
||||
return $this->db->update('items', array('deleted'=>1));
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user