Example #1
0
 public function render(Varien_Object $row)
 {
     $amountDesc = $row->getAmountDesc();
     $html = '';
     if ($amountDesc != '') {
         $amountDesc = json_decode($amountDesc, true);
         foreach ($amountDesc as $incrementId => $baseNetAmount) {
             $url = 'javascript:void(0);';
             $target = "";
             $amount = Mage::app()->getLocale()->currency($row->getBaseCurrency())->toCurrency($baseNetAmount);
             $vorder = Mage::getModel('sales/order')->loadByIncrementId($incrementId);
             if ($this->_frontend && $vorder && $vorder->getId()) {
                 $url = Mage::getUrl("csmarketplace/vorders/view/", array('increment_id' => $incrementId));
                 $target = "target='_blank'";
                 $html .= '<label for="order_id_' . $incrementId . '"><b>Order# </b>' . "<a href='" . $url . "' " . $target . " >" . $incrementId . "</a>" . '</label>, <b>Amount </b>' . $amount . '<br/>';
             } else {
                 $html .= '<label for="order_id_' . $incrementId . '"><b>Order# </b>' . $incrementId . '</label>, <b>Amount </b>' . $amount . '<br/>';
             }
         }
     }
     return $html;
 }