<?php
/**
 * Maho
 *
 * @category    design
 * @package     default_default
 * @copyright   Copyright (c) 2006-2020 Magento, Inc. (https://magento.com)
 * @copyright   Copyright (c) 2021-2024 The OpenMage Contributors (https://openmage.org)
 * @copyright   Copyright (c) 2024 Maho (https://mahocommerce.com)
 * @license     https://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
 */

/** @var Mage_Adminhtml_Block_Tax_Rate_ImportExport $this */
?>
<div class="content-header">
    <table cellspacing="0">
        <tr>
            <td><h3><?= Mage::helper('tax')->__('Import / Export Tax Rates') ?></h3></td>
        </tr>
    </table>
</div>
<div class="entry-edit">
    <?php if (!$this->getIsReadonly()): ?>
    <div class="box-left">
        <form id="import_form" action="<?= $this->getUrl('*/*/importPost') ?>" method="post" enctype="multipart/form-data">
            <?= $this->getBlockHtml('formkey') ?>
            <div class="entry-edit-head">
                <h4><?= Mage::helper('tax')->__('Import Tax Rates') ?></h4>
            </div>
            <fieldset>
                <legend><?= Mage::helper('tax')->__('Import Tax Rates') ?></legend>
                <input type="file" name="import_rates_file" class="input-file required-entry"/>
                <?= $this->getButtonHtml('Import Tax Rates', "this.form.submit()") ?>
            </fieldset>
        </form>
        <script type="text/javascript">
            var importForm = new varienForm('import_form');
        </script>
    </div>
    <?php endif ?>
    <div class="<?php if ($this->getIsReadonly()): ?>box-left<?php else: ?>box-right<?php endif ?>">
        <form id="export_form" action="<?= $this->getUrl('*/*/exportPost') ?>" method="post" enctype="multipart/form-data">
            <?= $this->getBlockHtml('formkey') ?>
            <div class="entry-edit-head">
                <h4><?= Mage::helper('tax')->__('Export Tax Rates') ?></h4>
            </div>
            <fieldset>
                <legend><?= Mage::helper('tax')->__('Export Tax Rates') ?></legend>
                <?= $this->getButtonHtml('Export Tax Rates', "this.form.submit()") ?>
            </fieldset>
        </form>
    </div>
    <div class="clear"></div>
</div>
