Public Member Functions | |
getEntityModelByType ($type) | |
isMessageEmpty () | |
Static Public Member Functions | |
static | getAllowedEntityTypes () |
Protected Member Functions | |
_construct () | |
Static Protected Attributes | |
static | $_allowedEntityTypes |
Definition at line 35 of file Message.php.
_construct | ( | ) | [protected] |
Enter description here...
Reimplemented from Varien_Object.
Definition at line 52 of file Message.php.
00053 { 00054 $this->_init('giftmessage/message'); 00055 }
static getAllowedEntityTypes | ( | ) | [static] |
Return list of allowed entities for using in gift messages
Definition at line 88 of file Message.php.
getEntityModelByType | ( | $ | type | ) |
Return model from entity type
string | $type |
Definition at line 63 of file Message.php.
00064 { 00065 $types = self::getAllowedEntityTypes(); 00066 if(!isset($types[$type])) { 00067 Mage::throwException(Mage::helper('giftmessage')->__('Unknown entity type')); 00068 } 00069 00070 return Mage::getModel($types[$type]); 00071 }
isMessageEmpty | ( | ) |
$_allowedEntityTypes [static, protected] |
Initial value:
array( 'order' => 'sales/order', 'order_item' => 'sales/order_item', 'order_address' => 'sales/order_address', 'quote' => 'sales/quote', 'quote_item' => 'sales/quote_item', 'quote_address' => 'sales/quote_address', 'quote_address_item' => 'sales/quote_address_item' )
Definition at line 42 of file Message.php.