/** * Remove an Id from the set. * @param object Id $id The Id to remove. * @access public * @return void */ function removeItem($id) { // Store the old order $oldOrder = $this->_items; // remove the Item parent::removeItem($id); // update the database with the new order keys. $this->_updateOrders($oldOrder); // Remove the item from the database $query = new DeleteQuery(); $query->setTable("sets"); $query->addWhere("id='" . addslashes($this->_setId->getIdString()) . "'"); $query->addWhere("item_id='" . addslashes($id->getIdString()) . "'"); $dbHandler = Services::getService("DatabaseManager"); $dbHandler->query($query, $this->_dbIndex); }