*/ class Webshopapps_Wsalogger_Adminhtml_Block_Notification_Grid_Renderer_Severity extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract { /** * Renders grid column * * @param Varien_Object $row * @return string */ public function render(Varien_Object $row) { $notice = Mage::getSingleton('wsalogger/log'); switch ($row->getData($this->getColumn()->getIndex())) { case Mage_AdminNotification_Model_Inbox::SEVERITY_CRITICAL: $class = 'critical'; $value = $notice->getSeverities(Mage_AdminNotification_Model_Inbox::SEVERITY_CRITICAL); break; case Mage_AdminNotification_Model_Inbox::SEVERITY_MAJOR: $class = 'major'; $value = $notice->getSeverities(Mage_AdminNotification_Model_Inbox::SEVERITY_MAJOR); break; case Mage_AdminNotification_Model_Inbox::SEVERITY_MINOR: $class = 'minor'; $value = $notice->getSeverities(Mage_AdminNotification_Model_Inbox::SEVERITY_MINOR); break; case Mage_AdminNotification_Model_Inbox::SEVERITY_NOTICE: $class = 'notice'; $value = $notice->getSeverities(Mage_AdminNotification_Model_Inbox::SEVERITY_NOTICE); break; } return '' . $value . ''; } }