oxselectlist.php

Go to the documentation of this file.
00001 <?php
00002 
00005 class oxSelectlist extends oxI18n
00006 {
00011     protected $_aFieldList = null;
00012 
00017     protected $_sClassName = 'oxselectlist';
00018 
00027     public function __construct( $sObjectsInListName = 'oxselectlist')
00028     {
00029         parent::__construct();
00030         $this->init( 'oxselectlist' );
00031     }
00032 
00040     public function getFieldList( $dVat = null )
00041     {
00042         if ( $this->_aFieldList == null && $this->oxselectlist__oxvaldesc->value ) {
00043             $this->_aFieldList = oxUtils::getInstance()->assignValuesFromText( $this->oxselectlist__oxvaldesc->value, $dVat );
00044             foreach ( $this->_aFieldList as $sKey => $oField ) {
00045                 $this->_aFieldList[$sKey]->name = strip_tags( $this->_aFieldList[$sKey]->name );
00046             }
00047         }
00048         return $this->_aFieldList;
00049     }
00050 
00058     public function delete( $sOXID = null )
00059     {
00060         if ( !$sOXID ) {
00061             $sOXID = $this->getId();
00062         }
00063         if ( !$sOXID ) {
00064             return false;
00065         }
00066 
00067         // remove selectlists from articles also
00068         if ( $blRemove = parent::delete( $sOXID ) ) {
00069             oxDb::getDb()->execute( "delete from oxobject2selectlist where oxselnid = '$sOXID' " );
00070         }
00071 
00072         return $blRemove;
00073     }
00074 }

Generated on Tue Aug 18 09:21:06 2009 for OXID eShop CE by  doxygen 1.5.5