cvs: pear /Perm_LiveUser/Admin/Perm/Container DB_Medium.php MDB2_Medium.php MDB_Medium.php

From: Date: Sun, 24 Oct 2004 11:16:01 +0000
Subject: cvs: pear /Perm_LiveUser/Admin/Perm/Container DB_Medium.php MDB2_Medium.php MDB_Medium.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-25167@lists.php.net to get a copy of this message
dufuz Sun Oct 24 07:16:01 2004 EDT Modified files: /pear/Perm_LiveUser/Admin/Perm/Container DB_Medium.php MDB2_Medium.php MDB_Medium.php Log: - BC break! [de]activateGroup was removed in favor of using the optional array for handling that. http://cvs.php.net/diff.php/pear/Perm_LiveUser/Admin/Perm/Container/DB_Medium.php?r1=1.76&r2=1.77&ty=u Index: pear/Perm_LiveUser/Admin/Perm/Container/DB_Medium.php diff -u pear/Perm_LiveUser/Admin/Perm/Container/DB_Medium.php:1.76 pear/Perm_LiveUser/Admin/Perm/Container/DB_Medium.php:1.77 --- pear/Perm_LiveUser/Admin/Perm/Container/DB_Medium.php:1.76 Sun Oct 24 06:56:42 2004 +++ pear/Perm_LiveUser/Admin/Perm/Container/DB_Medium.php Sun Oct 24 07:15:59 2004 @@ -51,7 +51,7 @@ * @author Markus Wolff <wolff@21st.de> * @author Matt Scifo <mscifo@php.net> * @author Arnaud Limbourg <arnaud@php.net> - * @version $Id: DB_Medium.php,v 1.76 2004/10/24 10:56:42 dufuz Exp $ + * @version $Id: DB_Medium.php,v 1.77 2004/10/24 11:15:59 dufuz Exp $ * @package LiveUser */ class LiveUser_Admin_Perm_Container_DB_Medium extends LiveUser_Admin_Perm_Container_DB_Simple @@ -292,62 +292,6 @@ } /** - * Activate group - * - * @access public - * @param integer id of group - * @return mixed boolean or DB Error object or false - */ - function activateGroup($groupId) - { - if (!is_numeric($groupId)) { - return false; - } - - $query = 'UPDATE - ' . $this->prefix . 'groups - SET - is_active = \'Y\' - WHERE - ' . $this->groupTableCols['required']['group_id']['name'] . ' = ' - . (int)$groupId; - - $result = $this->dbc->query($query); - - if (DB::isError($result)) { - return $result; - } - - return true; - } - - /** - * Deactivate group - * - * @access public - * @param integer id of group - * @return mixed boolean or DB Error object - */ - function deactivateGroup($groupId) - { - $query = 'UPDATE - ' . $this->prefix . 'groups - SET - is_active = \'N\' - WHERE - ' . $this->groupTableCols['required']['group_id']['name'] . ' = ' - . (int)$groupId; - - $result = $this->dbc->query($query); - - if (DB::isError($result)) { - return $result; - } - - return true; - } - - /** * Grant right to group * * @access public http://cvs.php.net/diff.php/pear/Perm_LiveUser/Admin/Perm/Container/MDB2_Medium.php?r1=1.37&r2=1.38&ty=u Index: pear/Perm_LiveUser/Admin/Perm/Container/MDB2_Medium.php diff -u pear/Perm_LiveUser/Admin/Perm/Container/MDB2_Medium.php:1.37 pear/Perm_LiveUser/Admin/Perm/Container/MDB2_Medium.php:1.38 --- pear/Perm_LiveUser/Admin/Perm/Container/MDB2_Medium.php:1.37 Sun Oct 24 06:56:42 2004 +++ pear/Perm_LiveUser/Admin/Perm/Container/MDB2_Medium.php Sun Oct 24 07:16:00 2004 @@ -51,7 +51,7 @@ * @author Markus Wolff <wolff@21st.de> * @author Matt Scifo <mscifo@php.net> * @author Arnaud Limbourg <arnaud@php.net> - * @version $Id: MDB2_Medium.php,v 1.37 2004/10/24 10:56:42 dufuz Exp $ + * @version $Id: MDB2_Medium.php,v 1.38 2004/10/24 11:16:00 dufuz Exp $ * @package LiveUser */ class LiveUser_Admin_Perm_Container_MDB2_Medium extends LiveUser_Admin_Perm_Container_MDB2_Simple @@ -292,62 +292,6 @@ } /** - * Activate group - * - * @access public - * @param integer id of group - * @return mixed boolean or MDB2 Error object or false - */ - function activateGroup($groupId) - { - if (!is_numeric($groupId)) { - return false; - } - - $query = 'UPDATE - ' . $this->prefix . 'groups - SET - is_active = '.$this->dbc->quote(true, 'boolean').' - WHERE - ' . $this->groupTableCols['required']['group_id']['name'] . ' = ' - . $this->dbc->quote($groupId, $this->groupTableCols['required']['group_id']['type']); - - $result = $this->dbc->query($query); - - if (MDB2::isError($result)) { - return $result; - } - - return true; - } - - /** - * Deactivate group - * - * @access public - * @param integer id of group - * @return mixed boolean or MDB2 Error object - */ - function deactivateGroup($groupId) - { - $query = 'UPDATE - ' . $this->prefix . 'groups - SET - is_active = ' . $this->dbc->quote(false, 'boolean') . ' - WHERE - ' . $this->groupTableCols['required']['group_id']['name'] . ' = ' - . $this->dbc->quote($groupId, $this->groupTableCols['required']['group_id']['type']); - - $result = $this->dbc->query($query); - - if (MDB2::isError($result)) { - return $result; - } - - return true; - } - - /** * Grant right to group * * @access public http://cvs.php.net/diff.php/pear/Perm_LiveUser/Admin/Perm/Container/MDB_Medium.php?r1=1.62&r2=1.63&ty=u Index: pear/Perm_LiveUser/Admin/Perm/Container/MDB_Medium.php diff -u pear/Perm_LiveUser/Admin/Perm/Container/MDB_Medium.php:1.62 pear/Perm_LiveUser/Admin/Perm/Container/MDB_Medium.php:1.63 --- pear/Perm_LiveUser/Admin/Perm/Container/MDB_Medium.php:1.62 Sun Oct 24 06:56:42 2004 +++ pear/Perm_LiveUser/Admin/Perm/Container/MDB_Medium.php Sun Oct 24 07:16:00 2004 @@ -51,7 +51,7 @@ * @author Markus Wolff <wolff@21st.de> * @author Matt Scifo <mscifo@php.net> * @author Arnaud Limbourg <arnaud@php.net> - * @version $Id: MDB_Medium.php,v 1.62 2004/10/24 10:56:42 dufuz Exp $ + * @version $Id: MDB_Medium.php,v 1.63 2004/10/24 11:16:00 dufuz Exp $ * @package LiveUser */ class LiveUser_Admin_Perm_Container_MDB_Medium extends LiveUser_Admin_Perm_Container_MDB_Simple @@ -292,62 +292,6 @@ } /** - * Activate group - * - * @access public - * @param integer id of group - * @return mixed boolean or MDB Error object or false - */ - function activateGroup($groupId) - { - if (!is_numeric($groupId)) { - return false; - } - - $query = 'UPDATE - ' . $this->prefix . 'groups - SET - is_active = '.$this->dbc->getValue('boolean', true).' - WHERE - ' . $this->groupTableCols['required']['group_id']['name'] . ' = ' - . $this->dbc->getValue($this->groupTableCols['required']['group_id']['type'], $groupId); - - $result = $this->dbc->query($query); - - if (MDB::isError($result)) { - return $result; - } - - return true; - } - - /** - * Deactivate group - * - * @access public - * @param integer id of group - * @return mixed boolean or MDB Error object - */ - function deactivateGroup($groupId) - { - $query = 'UPDATE - ' . $this->prefix . 'groups - SET - is_active = ' . $this->dbc->getValue('boolean', false) . ' - WHERE - ' . $this->groupTableCols['required']['group_id']['name'] . ' = ' - . $this->dbc->getValue($this->groupTableCols['required']['group_id']['type'], $groupId); - - $result = $this->dbc->query($query); - - if (MDB::isError($result)) { - return $result; - } - - return true; - } - - /** * Grant right to group * * @access public

« previous php.pear.cvs (#25167) next »