<?php
/**
 * Magento Enterprise Edition
 *
 * NOTICE OF LICENSE
 *
 * This source file is subject to the Magento Enterprise Edition License
 * that is bundled with this package in the file LICENSE_EE.txt.
 * It is also available through the world-wide-web at this URL:
 * http://www.magentocommerce.com/license/enterprise-edition
 * If you did not receive a copy of the license and are unable to
 * obtain it through the world-wide-web, please send an email
 * to license@magentocommerce.com so we can send you a copy immediately.
 *
 * DISCLAIMER
 *
 * Do not edit or add to this file if you wish to upgrade Magento to newer
 * versions in the future. If you wish to customize Magento for your
 * needs please refer to http://www.magentocommerce.com for more information.
 *
 * @category    design
 * @package     enterprise_default
 * @copyright   Copyright (c) 2009 Irubin Consulting Inc. DBA Varien (http://www.varien.com)
 * @license     http://www.magentocommerce.com/license/enterprise-edition
 */
?>
<?php  $_order = $this->getOrder() ?>
<div class="order-page">
<div class="page-title title-buttons">
    <h1><?php echo $this->__('Order #%s - %s', $_order->getRealOrderId(), $_order->getStatusLabel()) ?></h1>
    <?php if ($this->helper('sales/reorder')->canReorder($_order)) : ?>
        <a href="<?php echo $this->getReorderUrl($_order) ?>"><?php echo $this->__('Reorder') ?></a>
        <span class="separator">|</span>
    <?php endif ?>
    <a href="<?php echo $this->getPrintUrl($_order) ?>" onclick="this.target='_blank';"><?php echo $this->__('Print Order') ?></a>
    <?php if($this->helper('rss/order')->isStatusNotificationAllow()): ?>
        <span class="separator">|</span>
        <a href="<?php echo $this->helper('rss/order')->getStatusHistoryRssUrl($_order) ?>" class="link-rss f-none"><?php echo $this->__('Subscribe to Order Status') ?></a>
    <?php endif; ?>
    <?php if(Mage::helper('awrma')->isEnabled() && Mage::helper('awrma')->isAllowedForOrder($_order)) : ?>
        <span class="separator">|</span>
        <a href="<?php echo $this->getUrl('awrma/customer_rma/createfororder/', array('order_id' => $_order->getIncrementId())) ?>"><?php echo $this->__('Request RMA') ?></a>
    <?php endif ?>
</div>
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
<?php echo $this->getStatusHistoryRssUrl($_order) ?>
<dl class="order-info">
    <dt><?php echo $this->__('About This Order:') ?></dt>
    <dd>
        <?php $_links = $this->getLinks(); ?>
        <ul>
        <?php foreach ($_links as $_link): ?>
            <?php if($_link->getUrl()): ?>
                <li><a href="<?php echo $_link->getUrl() ?>"><?php echo $_link->getLabel() ?></a></li>
            <?php else: ?>
                <li class="current"><strong><?php echo $_link->getLabel() ?></strong></li>
            <?php endif; ?>
        <?php endforeach; ?>
        </ul>
    </dd>
</dl>
<p class="order-date"><?php echo $this->__('Order Date: %s', $this->formatDate($_order->getCreatedAtStoreDate(), 'long')) ?></p>
<?php if (!$_order->getIsVirtual()): ?>
<div class="col2-set">
    <div class="col-1">
        <div class="info-box">
            <h2 class="box-title"><?php echo $this->__('Shipping Address') ?></h2>
            <address class="box-content"><?php echo $_order->getShippingAddress()->format('html') ?></address>
        </div>
    </div>
    <div class="col-2">
        <div class="info-box">
            <h2 class="box-title"><?php echo $this->__('Shipping Method') ?><?php /* | <a href="#"><?php echo $this->__('Track Order') ?></a>*/ ?></h2>
            <div class="box-content">
        <?php if ($_order->getShippingDescription()): ?>
            <?php echo $_order->getShippingDescription() ?>
        <?php else: ?>
            <?php echo $this->helper('sales')->__('No shipping information available'); ?>
        <?php endif; ?>
            </div>
        </div>
    </div>
</div>
<?php endif; ?>
<div class="col2-set">
    <div class="col-1">
        <div class="info-box">
            <h2 class="box-title"><?php echo $this->__('Billing Address') ?></h2>
            <address class="box-content"><?php echo $_order->getBillingAddress()->format('html') ?></address>
        </div>
    </div>
    <div class="col-2">
        <div class="info-box">
            <h2 class="box-title"><?php echo $this->__('Payment Method') ?></h2>
            <div class="box-content"><?php echo $this->getPaymentInfoHtml() ?></div>
        </div>
    </div>
</div>
</div>
