<?php
    if (isset($tpl['status']))
    {
        $status = __('status', true);
        switch ($tpl['status'])
        {
            case 2:
                pjUtil::printNotice(NULL, $status[2]);
                break;
        }
    } else {

        $titles = __('error_titles', true);
        $bodies = __('error_bodies', true);
        ?>
        <form action="<?php echo $_SERVER['PHP_SELF']; ?>?controller=pjAdminExtras&amp;action=pjActionCreate" method="post" id="frmCreateExtra" class="form pj-form" autocomplete="off">
            <p style="position: relative">
                <label class="title"><?php __('lblExtraName'); ?></label>
                <input type="text" name="name" id="name" class="pj-form-field required w200" />
            </p>

            <div class="inline_block" data-options="1">
                <p style="position: relative;">
                    <label class="title"><?php __('lblExtraOption'); ?> <span data-option-id="1">1</span></label>

                    <span class="pj-form-field-custom pj-form-field-custom-after">
                        <input type="text" name="options[1][name]" id="name" class="pj-form-field required w200" />
                    </span>

                    <span class="pj-form-field-custom pj-form-field-custom-before">
                        <span class="pj-form-field-before"><abbr class="pj-form-field-icon-text"><?php echo pjUtil::formatCurrencySign(NULL, $tpl['option_arr']['o_currency'], ""); ?></abbr></span>
                        <input type="text" name="options[1][price]" id="price" class="pj-form-field number w50" />
                    </span>

                    <span class="pj-form-field-custom pj-form-field-custom-before" style="display: none; float: right; margin-left: 3px;">
                        <button type="button" class="pj-button" data-delete-option="1"><?php __('lblDelete'); ?></button>
                    </span>
                </p>
            </div>

            <p>
                <label class="title">&nbsp;</label>
                <input type="button" value="<?php __('btnAdd', false, true); ?>" class="pj-button" data-add-option="1" />
                <input type="submit" value="<?php __('btnSave', false, true); ?>" class="pj-button" />
                <input type="button" value="<?php __('btnCancel'); ?>" class="pj-button" onclick="window.location.href='<?php echo PJ_INSTALL_URL; ?>index.php?controller=pjAdminClients&action=pjActionIndex';" />
            </p>
        </form>

        <script type="text/javascript">
            var myLabel = myLabel || {};
        </script>
        <?php
    }
?>