Go to the documentation of this file.00001 <?php
00002
00008 class oxGroups extends oxI18n
00009 {
00014 protected $_sClassName = 'oxgroups';
00015
00019 public function __construct()
00020 {
00021 parent::__construct();
00022 $this->init( 'oxgroups' );
00023 }
00024
00025
00033 public function delete( $sOXID = null )
00034 {
00035 if ( !$sOXID ) {
00036 $sOXID = $this->getId();
00037 }
00038 if ( !$sOXID ) {
00039 return false;
00040 }
00041
00042
00043
00044 parent::delete( $sOXID );
00045
00046 $oDb = oxDb::getDb();
00047
00048
00049
00050 $sDelete = 'delete from oxobject2group where oxobject2group.oxgroupsid = ' . $oDb->quote( $sOXID );
00051 $rs = $oDb->execute( $sDelete );
00052
00053 $sDelete = 'delete from oxobject2delivery where oxobject2delivery.oxobjectid = ' . $oDb->quote( $sOXID );
00054 $rs = $oDb->execute( $sDelete );
00055
00056 $sDelete = 'delete from oxobject2discount where oxobject2discount.oxobjectid = ' . $oDb->quote( $sOXID );
00057 $rs = $oDb->execute( $sDelete );
00058
00059 $sDelete = 'delete from oxobject2payment where oxobject2payment.oxobjectid = ' . $oDb->quote( $sOXID );
00060 $rs = $oDb->execute( $sDelete );
00061
00062 return $rs->EOF;
00063 }
00064
00065 }