public function __construct() { parent::__construct(); if (Mage::getStoreConfig('zendesk/features/show_on_order')) { $this->_addButton('ticket_new', array('label' => Mage::helper('zendesk')->__('Create Ticket'), 'onclick' => 'setLocation(\'' . $this->getTicketUrl() . '\')', 'class' => 'zendesk')); } }
public function __construct() { parent::__construct(); $payment = $this->getOrder()->getPayment(); $method = $payment->getMethodInstance()->getCode(); $tid = $payment->getAdditionalInformation('Cielo_tid'); if (!$tid) { return; } if ($method == "Maxima_Cielo_Cc") { if ($this->_isAllowedAction("cielo-capture")) { $this->_addButton('maxima_cielo_capture', array('label' => Mage::helper('Maxima_Cielo')->__('Capture'), 'onclick' => "captureCieloOrder('" . $tid . "', " . $this->getOrder()->getId() . ");", 'class' => 'go')); } } if ($method == "Maxima_Cielo_Cc" || $method == "Maxima_Cielo_Dc") { if ($this->_isAllowedAction("cielo-consult")) { $this->_addButton('maxima_cielo_consult', array('label' => Mage::helper('Maxima_Cielo')->__('Consult WebService'), 'onclick' => "loadCieloWebServiceData('" . $tid . "', " . $this->getOrder()->getId() . ");", 'class' => 'go')); } } if ($method == "Maxima_Cielo_Cc") { if ($this->_isAllowedAction("cielo-cancel")) { $this->_addButton('maxima_cielo_cancel', array('label' => Mage::helper('Maxima_Cielo')->__('Cancel on Cielo'), 'onclick' => "cancelCieloOrder('" . $tid . "', " . $this->getOrder()->getId() . ");", 'class' => 'go')); } } }
public function __construct() { parent::__construct(); if ($this->_hasPdfShippingLabels()) { $this->_addButton('zitec_print_shipping_label', array('label' => $this->_getHelper()->__('Print Shipping Labels'), 'onclick' => "setLocation('{$this->_getPrintShippingLabelsUrl()}')")); } }
public function __construct() { parent::__construct(); $vendorOrder = Mage::registry('vendor_order'); if ($vendorOrder) { if (!$vendorOrder->canCancel()) { $this->_removeButton('order_cancel'); } if (!$vendorOrder->canCreditmemo()) { $this->_removeButton('order_creditmemo'); } if (!$vendorOrder->canInvoice()) { $this->_removeButton('order_invoice'); } if (!$vendorOrder->canShip()) { $this->_removeButton('order_ship'); } if (true) { $this->_removeButton('order_edit'); } if (true) { $this->_removeButton('send_notification'); } if (!$vendorOrder->canReorder()) { $this->_removeButton('order_reorder'); } if ($vendorOrder->isCanceled()) { $this->_removeButton('send_notification'); } } }
public function __construct() { parent::__construct(); if (Mage::helper('core')->isModuleEnabled('Gamuza_Labels') && Mage::getStoreConfig('labels/settings/active') && $this->getOrder()->hasInvoices()) { $this->_addButton('order_label', array('label' => Mage::helper('labels')->__('Label'), 'onclick' => "popWin ('" . $this->getLabelUrl() . "', '','width=400,height=585,resizable=no,scrollbars=no')", 'class' => 'go')); } }
public function __construct() { parent::__construct(); $order = $this->getOrder(); $url = $this->getUrl('sendcloud/index/parcel', array('id' => $order->getId(), 'redirect' => 'order_view')); $onclick = "setLocation('{$url}');"; $this->_addButton('sendtosendcloud', array('label' => Mage::helper('sales')->__('Doorsturen naar Sendcloud'), 'onclick' => $onclick, 'class' => 'go'), 0, 100, 'header', 'header'); }
public function __construct() { parent::__construct(); if ($this->_isAllowedAction('review_payment') && $this->getOrder()->getPayment()->getMethod() == 'payu_account' && $this->getOrder()->getStatus() == 'pending_payment' && (int) Mage::getStoreConfig('payment/payu_account/selfreturn') == 0) { $this->_addButton('payu-complete', array('label' => Mage::helper('payu_account')->__('Complete PayU payment'), 'onclick' => 'setLocation(\'' . $this->getCompletePaymentUrl() . '\')', 'class' => ''), 0, 100, 'header', 'header'); $this->_addButton('payu-cancel', array('label' => Mage::helper('payu_account')->__('Cancel PayU payment'), 'onclick' => 'setLocation(\'' . $this->getCancelPaymentUrl() . '\')', 'class' => ''), 0, 200, 'header', 'header'); } }
public function __construct() { parent::__construct(); $enable = Mage::helper('pdfinvoiceplus')->checkEnable(); $active = Mage::helper('pdfinvoiceplus')->checkStoreTemplate(); if ($enable == 1 && $active == 1) { $this->_addButton('printpdf', array('label' => Mage::helper('pdfinvoiceplus')->__('Print Custom PDF File'), 'class' => 'save', 'onclick' => $this->getPrintPdfLink())); } }
public function __construct() { $order = $this->getOrder(); // removes the 'Edit' button by disallowing // Editing of an order to avoid confusion if ($this->_isAllowedAction('edit') && $order->canEdit()) { $order->setActionFlag('edit', false); } parent::__construct(); }
public function __construct() { $states = explode(',', Mage::getStoreConfig('nfe/general/pedido_status')); if (in_array($this->getOrder()->getState(), $states) || !is_array($states)) { $this->_addButton('call_to_send_nfe', array('label' => Mage::helper('Sales')->__('Emitir NF-e'), 'onclick' => 'setLocation(\'' . $this->getUrlSend() . '\')', 'class' => 'go'), 0, 100, 'header', 'header'); } else { $this->_addButton('call_to_send_nfe', array('label' => Mage::helper('Sales')->__('Emitir NF-e'), 'class' => 'disabled'), 0, 100, 'header', 'header'); } parent::__construct(); }
public function __construct() { $read = Mage::getSingleton('core/resource')->getConnection('core_read'); $row = $read->fetchRow("select * from epay_order_status where orderid = '" . $this->getOrder()->getIncrementId() . "'"); $standard = Mage::getModel('epay/standard'); if (!$row || $row['status'] == '0') { $this->_addButton('button_sendpaymentrequest', array('label' => Mage::helper('epay')->__('Create payment request'), 'onclick' => 'setLocation(\'' . Mage::helper("adminhtml")->getUrl('epay/adminhtml_paymentrequest/create/', array('id' => $this->getOrder()->getRealOrderId())) . '\')', 'class' => 'scalable go'), 0, 100, 'header', 'header'); } parent::__construct(); }
public function __construct() { parent::__construct(); $this->_removeButton('order_cancel'); $this->_removeButton('order_hold'); $this->_removeButton('order_unhold'); $this->_removeButton('order_invoice'); $this->_removeButton('order_ship'); $this->_removeButton('order_creditmemo'); }
public function __construct() { $code = $this->getOrder()->getPayment()->getMethodInstance()->getCode(); if (Mage::helper('ratepaypayment/payment')->isRatepayPayment($code)) { parent::__construct(); $this->removeButton('order_ship'); } else { parent::__construct(); } }
public function __construct() { parent::__construct(); $order = $this->getOrder(); /* if ($this->_isAllowedAction('ship') && $order->canShip() && !$order->getForcedDoShipmentWithInvoice()) */ if (!$order->canVirtual() && Mage::helper('printlabel')->printlabel_enable()) { $this->_addButton('order_print_label', array('label' => Mage::helper('sales')->__('Print Label'), 'onclick' => 'setLocation(\'' . $this->getPrintLabelUrl() . '\')', 'class' => 'go')); } }
public function __construct() { if (Mage::helper('tweaks')->isOrderViewPrevnextBottonsEnable()) { if ($prevOrderUrl = $this->getPrevNextOrderUrl('<')) { $this->_addButton('order_prev', array('label' => Mage::helper('tweaks')->__('View Previous'), 'onclick' => "setLocation('{$prevOrderUrl}')")); } parent::__construct(); if ($nextOrderUrl = $this->getPrevNextOrderUrl('>')) { $this->_addButton('order_next', array('label' => Mage::helper('tweaks')->__('View Next'), 'onclick' => "setLocation('{$nextOrderUrl}')")); } } else { parent::__construct(); } }
function __construct() { $itemscount = 0; $totalWeight = 0; $_order = Mage::getModel('sales/order')->load($this->getRequest()->getParam('order_id')); $itemsv = $_order->getAllVisibleItems(); foreach ($itemsv as $itemvv) { if ($itemvv->getQtyOrdered() > $itemvv->getQtyShipped()) { $itemscount += $itemvv->getQtyOrdered() - $itemvv->getQtyShipped(); } if ($itemvv->getWeight() != 0) { $weight = $itemvv->getWeight() * $itemvv->getQtyOrdered(); } else { $weight = 0.5 * $itemvv->getQtyOrdered(); } $totalWeight += $weight; } $shipments = Mage::getResourceModel('sales/order_shipment_collection')->addAttributeToSelect('*')->addFieldToFilter("order_id", $_order->getId())->join("sales/shipment_comment", 'main_table.entity_id=parent_id', 'comment')->addFieldToFilter('comment', array('like' => "%{$_order->getIncrementId()}%"))->load(); $aramex_return_button = false; if ($shipments->count()) { foreach ($shipments as $key => $comment) { if (version_compare(PHP_VERSION, '5.3.0') <= 0) { $awbno = substr($comment->getComment(), 0, strpos($comment->getComment(), "- Order No")); } else { $awbno = strstr($comment->getComment(), "- Order No", true); } $awbno = trim($awbno, "AWB No."); break; } if ((int) $awbno) { $aramex_return_button = true; } } if ($_order->canShip()) { $this->_addButton('create_aramex_shipment', array('label' => Mage::helper('Sales')->__('Prepare Aramex Shipment'), 'onclick' => 'aramexpop(' . $itemscount . ')', 'class' => 'go'), 0, 100, 'header', 'header'); } elseif (!$_order->canShip() && $aramex_return_button) { $this->_addButton('create_aramex_shipment', array('label' => Mage::helper('Sales')->__('Return Aramex Shipment'), 'onclick' => 'aramexreturnpop(' . $itemscount . ')', 'class' => 'go'), 0, 100, 'header', 'header'); } //barry code if ($itemscount == 0) { $this->_addButton('print_aramex_label', array('label' => Mage::helper('Sales')->__('Aramex Print Label'), 'onclick' => "myObj.printLabel()", 'class' => 'go'), 0, 200, 'header', 'header'); } //barry code end here parent::__construct(); }
public function __construct() { parent::__construct(); $order = $this->getOrder(); $orderId = $order->getId(); $allowedInvoice = $this->_isAllowedAction('invoice'); $canInvoice = $order->canInvoice(); if ($order->hasInvoices() || $order->hasShipments() || $order->getState() == 'closed') { $deleteInvoiceShipMemoPath = $this->getUrl('ordereditor/adminhtml_ordereditor/deleteInvoiceShipCreditMemo') . '?order_id=' . $orderId; $onclickInvoiceJs = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure? It will delete the created Invoice(s) and then you can create new updated invoice.') . '\', \'' . $deleteInvoiceShipMemoPath . '\');'; } else { $onclickInvoiceJs = 'alert(\'' . Mage::helper('sales')->__('Sorry, no invoice is created,please create new Invoice') . '\');'; } $_label = Mage::helper('sales')->__('Delete Invoice'); $this->_addButton('delete_invoice', array('label' => $_label, 'onclick' => $onclickInvoiceJs, 'class' => ''), 0, 15); /* if ($order->hasInvoices() || $order->hasShipments() || $order->getState() == 'closed' ) { $resetItemStatusPath = $this->getUrl('ordereditor/adminhtml_ordereditor/resetItemStatus').'?order_id='.$orderId; $resetItemStatus = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure?') . '\', \'' . $resetItemStatusPath . '\');'; } else { $resetItemStatus = 'alert(\'' . Mage::helper('sales')->__('Sorry, no invoice is created,please create new Invoice') . '\');'; } $_label = Mage::helper('sales')->__('Reset Item Status'); $this->_addButton('reset_item', array( 'label' => $_label, 'onclick' => $resetItemStatus, 'class' => '' ),0,26); */ $deleteOrderAction = $this->getUrl('ordereditor/adminhtml_ordereditor/deleteOrder') . '?order_id=' . $orderId; $deleteAlert = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure you want to delete the order.') . '\', \'' . $deleteOrderAction . '\');'; $_label = Mage::helper('sales')->__('Delete'); $this->_addButton('delete_order', array('label' => $_label, 'onclick' => $deleteAlert, 'class' => 'delete'), 0, 25); }
public function __construct() { parent::__construct(); $order = $this->getOrder(); // Consulta transaçao Bcash $quoteId = $order->getQuoteId(); $quote = Mage::getModel('sales/quote')->loadByIdWithoutStore($quoteId); $transactionIdBcash = $quote->getTransactionIdBcash(); $transactionInfo = Mage::helper('bcash')->getTransaction($transactionIdBcash); // Checa se o status da transaçao Bcash permite cancelamento if ($transactionInfo->transacao->cod_status == NotificationStatusEnum::IN_PROGRESS || $transactionInfo->transacao->cod_status == NotificationStatusEnum::APPROVED) { if ($order->canCancel() || $order->canCreditmemo()) { $confirmationMessage = Mage::helper('core')->jsQuoteEscape(Mage::helper('sales')->__('Deseja realmente cancelar o pedido ' . $order->getId() . '? \\n\\nA transação de pagamento também será cancelada.')); $this->_addButton('button_cancel_with_bcash', array('label' => 'Cancelar com Bcash', 'onclick' => 'deleteConfirm(\'' . $confirmationMessage . '\', \'' . $this->getUrl('bcash/admin_sales_order/canceltransaction/') . '\')'), 0, 100, 'header', 'header'); } } $payment_link = $quote->getPaymentLinkBcash(); if ($transactionInfo->transacao->cod_status == 1 && $payment_link) { $this->_addButton('button_payment_link_bcash', array('label' => 'Link de Pagamento Bcash', 'onclick' => 'window.open(\'' . $payment_link . '\')'), 0, 110, 'header', 'header'); } }
public function __construct() { parent::__construct(); $order_id = $this->getOrderId(); $order = $this->getOrder(); $manual_shipping = Mage::getStoreConfig('carriers/shiphawk_shipping/book_shipment'); $shipping_code = $order->getShippingMethod(); $confirm_messsage = $this->__('Are you sure to process?'); $check_shiphawk = Mage::helper('shiphawk_shipping')->isShipHawkShipping($shipping_code); if ($check_shiphawk !== false) { if ($order->canShip()) { if ($manual_shipping) { $this->_addButton('shiphawk_shipping', array('label' => Mage::helper('shiphawk_shipping')->__('ShipHawk Shipment'), 'onclick' => "confirmSetLocation('{$confirm_messsage}', '{$this->getShipHawkUrl($order_id)}')", 'class' => 'go'), 0, 100, 'header', 'header'); } } } else { if ($order->canShip()) { $this->_addButton('shiphawk_shipping_new', array('label' => Mage::helper('shiphawk_shipping')->__('New ShipHawk Shipment'), 'class' => 'newshipment', 'onclick' => "showPopup('{$this->getNewShipHawkUrl($order_id)}')"), 0, 150, 'header', 'header'); } } }
public function __construct() { parent::__construct(); if (!Mage::helper('giftcard')->isActive()) { return; } $order = $this->getOrder(); $items = $order->getAllItems(); if (count($items) != 0) { foreach ($items as $item) { if ($item->getProductType() == MT_Giftcard_Model_Catalog_Product_Type::TYPE_GIFTCARD_PRODUCT) { $this->_addButton('download_pdf_giftcard', array('label' => Mage::helper('sales')->__('Gift Card (.pdf)'), 'class' => 'scalable', 'onclick' => 'downloadPdfGiftCard()')); $this->_addButton('download_pdf_giftcard_zipped', array('label' => Mage::helper('sales')->__('Gift Card (.jpg zipped)'), 'class' => 'scalable', 'onclick' => 'downloadImageGiftCard()')); $downloadPdfLink = Mage::helper("adminhtml")->getUrl("adminhtml/giftcard_export/order", array('id' => $order->getId(), 'format' => 'pdf')); $downloadImageLink = Mage::helper("adminhtml")->getUrl("adminhtml/giftcard_export/order", array('id' => $order->getId(), 'format' => 'zip')); $this->_formScripts[] = " function downloadPdfGiftCard(){ window.location.href='" . $downloadPdfLink . "'; } "; $this->_formScripts[] = " function downloadImageGiftCard(){ window.location.href='" . $downloadImageLink . "'; } "; break; } } } }
public function __construct() { parent::__construct(); $order = $this->getOrder(); if (Mage::helper("creditcard")->isMOPLitle($order->getPayment())) { $authTransaction = $order->getPayment()->lookupTransaction(false, Mage_Sales_Model_Order_Payment_Transaction::TYPE_AUTH); // check if Auth-Reversal need to be shown if (!Mage::helper("creditcard")->isMOPLitleECheck($order->getPayment()->getData('method'))) { if ($authTransaction && !$authTransaction->getIsClosed()) { if ($order->getPayment()->getAmountPaid() == 0) { $message = 'Are you sure you want to reverse the authorization?'; $this->_updateButton('void_payment', 'label', 'Auth-Reversal'); $this->_updateButton('void_payment', 'onclick', "confirmSetLocation('{$message}', '{$this->getVoidPaymentUrl()}')"); } } else { $this->removeButton('order_invoice'); } } // check if Void-Refund needs to be shown if (Mage::helper("creditcard")->isStateOfOrderEqualTo($order, Mage_Sales_Model_Order_Payment_Transaction::TYPE_REFUND)) { $onclickJs = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure? The refund request will be canceled.') . '\', \'' . $this->getVoidPaymentUrl() . '\');'; $this->_addButton('void_refund', array('label' => 'Void Refund', 'onclick' => $onclickJs)); } //check if void capture or void sale needs to be shown if (Mage::helper("creditcard")->isStateOfOrderEqualTo($order, Mage_Sales_Model_Order_Payment_Transaction::TYPE_CAPTURE) && $this->wasLastTxnLessThan24HrsAgo($order->getPayment())) { $mop = $order->getPayment()->getData('method'); //check if paying with a credit card if (Mage::helper("creditcard")->isMOPLitleCC($mop) || Mage::helper("creditcard")->isMOPLitlePaypal($mop)) { $onclickJs = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure? If any previous partial captures were done on this order, or if capture was not done today then do a refund instead.') . '\', \'' . $this->getVoidPaymentUrl() . '\');'; $this->_addButton('void_capture', array('label' => 'Void Capture', 'onclick' => $onclickJs)); } elseif (Mage::helper("creditcard")->isMOPLitleECheck($mop)) { $onclickJs = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure? If any previous partial captures were done on this order, or if capture was not done today then do a refund instead.') . '\', \'' . $this->getVoidPaymentUrl() . '\');'; $this->_addButton('void_sale', array('label' => 'Void Sale', 'onclick' => $onclickJs)); } } } }
public function __construct() { parent::__construct(); $message = Mage::helper('sales')->__('Are you sure you want to delete this order?'); $this->_addButton('button_id', array('label' => Mage::helper('Sales')->__('Delete Order'), 'onclick' => 'deleteConfirm(\'' . $message . '\', \'' . $this->getDeleteUrl() . '\')', 'class' => 'go'), 0, 100, 'header', 'header'); }
public function __construct() { parent::__construct(); $this->_addButton('print', array('label' => Mage::helper('sales')->__('Print'), 'class' => 'save', 'onclick' => 'setLocation(\'' . $this->getPrintUrl() . '\')')); }
public function __construct() { parent::__construct(); $order = $this->getOrder(); $this->_addButton('unionpay_query', array('label' => Mage::helper('sales')->__('Unionpay Order Query'), 'onclick' => 'setLocation(\'' . $this->getUrl('unionpay/adminhtml_query/query', array('order_increcement' => $order->getIncrementId())) . '\')', 'class' => 'go')); }
public function __construct() { parent::__construct(); }
public function __construct() { $this->_objectId = 'order_id'; $this->_controller = 'sales_order'; $this->_mode = 'view'; parent::__construct(); $this->_removeButton('delete'); $this->_removeButton('reset'); $this->_removeButton('save'); $this->setId('sales_order_view'); $order = $this->getOrder(); if ($this->_isAllowedAction('edit') && $order->canEdit()) { $onclickJs = 'deleteConfirm(\'' . Mage::helper('sales')->__('Are you sure? This order will be canceled and a new one will be created instead') . '\', \'' . $this->getEditUrl() . '\');'; $this->_addButton('order_edit', array('label' => Mage::helper('sales')->__('Edit'), 'onclick' => $onclickJs)); // see if order has non-editable products as items $nonEditableTypes = array_keys($this->getOrder()->getResource()->aggregateProductsByTypes($order->getId(), array_keys(Mage::getConfig()->getNode('adminhtml/sales/order/create/available_product_types')->asArray()), false)); if ($nonEditableTypes) { $this->_updateButton('order_edit', 'onclick', 'if (!confirm(\'' . Mage::helper('sales')->__('This order contains (%s) items and therefore cannot be edited through the admin interface at this time, if you wish to continue editing the (%s) items will be removed, the order will be canceled and a new order will be placed.', implode(', ', $nonEditableTypes), implode(', ', $nonEditableTypes)) . '\')) return false;' . $onclickJs); } } if ($this->_isAllowedAction('cancel') && $order->canCancel()) { $message = Mage::helper('sales')->__('Are you sure you want to cancel this order?'); $this->_addButton('order_cancel', array('label' => Mage::helper('sales')->__('Cancel'), 'onclick' => 'deleteConfirm(\'' . $message . '\', \'' . $this->getCancelUrl() . '\')')); } if ($this->_isAllowedAction('emails') && !$order->isCanceled()) { $message = Mage::helper('sales')->__('Are you sure you want to send order email to customer?'); $this->addButton('send_notification', array('label' => Mage::helper('sales')->__('Send Email'), 'onclick' => "confirmSetLocation('{$message}', '{$this->getEmailUrl()}')")); } if ($this->_isAllowedAction('creditmemo') && $order->canCreditmemo()) { $message = Mage::helper('sales')->__('This will create an offline refund. To create an online refund, open an invoice and create credit memo for it. Do you wish to proceed?'); $onClick = "setLocation('{$this->getCreditmemoUrl()}')"; if ($order->getPayment()->getMethodInstance()->isGateway()) { $onClick = "confirmSetLocation('{$message}', '{$this->getCreditmemoUrl()}')"; } $this->_addButton('order_creditmemo', array('label' => Mage::helper('sales')->__('Credit Memo'), 'onclick' => $onClick, 'class' => 'go')); } // invoice action intentionally if ($this->_isAllowedAction('invoice') && $order->canVoidPayment()) { $message = Mage::helper('sales')->__('Are you sure you want to void the payment?'); $this->addButton('void_payment', array('label' => Mage::helper('sales')->__('Void'), 'onclick' => "confirmSetLocation('{$message}', '{$this->getVoidPaymentUrl()}')")); } if ($this->_isAllowedAction('hold') && $order->canHold()) { $this->_addButton('order_hold', array('label' => Mage::helper('sales')->__('Hold'), 'onclick' => 'setLocation(\'' . $this->getHoldUrl() . '\')')); } if ($this->_isAllowedAction('unhold') && $order->canUnhold()) { $this->_addButton('order_unhold', array('label' => Mage::helper('sales')->__('Unhold'), 'onclick' => 'setLocation(\'' . $this->getUnholdUrl() . '\')')); } if ($this->_isAllowedAction('review_payment')) { if ($order->canReviewPayment()) { $message = Mage::helper('sales')->__('Are you sure you want to accept this payment?'); $this->_addButton('accept_payment', array('label' => Mage::helper('sales')->__('Accept Payment'), 'onclick' => "confirmSetLocation('{$message}', '{$this->getReviewPaymentUrl('accept')}')")); $message = Mage::helper('sales')->__('Are you sure you want to deny this payment?'); $this->_addButton('deny_payment', array('label' => Mage::helper('sales')->__('Deny Payment'), 'onclick' => "confirmSetLocation('{$message}', '{$this->getReviewPaymentUrl('deny')}')")); } if ($order->canFetchPaymentReviewUpdate()) { $this->_addButton('get_review_payment_update', array('label' => Mage::helper('sales')->__('Get Payment Update'), 'onclick' => 'setLocation(\'' . $this->getReviewPaymentUrl('update') . '\')')); } } // if ($this->_isAllowedAction('invoice') && $order->canInvoice()) { // $_label = $order->getForcedDoShipmentWithInvoice() ? // Mage::helper('sales')->__('Invoice and Ship') : // Mage::helper('sales')->__('Invoice'); // $this->_addButton('order_invoice', array( // 'label' => $_label, // 'onclick' => 'setLocation(\'' . $this->getInvoiceUrl() . '\')', // 'class' => 'go' // )); // } if ($this->_isAllowedAction('ship') && $order->canShip() && !$order->getForcedDoShipmentWithInvoice()) { $this->_addButton('order_ship', array('label' => Mage::helper('sales')->__('Ship'), 'onclick' => 'setLocation(\'' . $this->getShipUrl() . '\')', 'class' => 'go')); } if ($this->_isAllowedAction('reorder') && $this->helper('sales/reorder')->isAllowed($order->getStore()) && $order->canReorderIgnoreSalable()) { $this->_addButton('order_reorder', array('label' => Mage::helper('sales')->__('Reorder'), 'onclick' => 'setLocation(\'' . $this->getReorderUrl() . '\')', 'class' => 'go')); } }