{% extends "shop/checkout/base_pay_ship.html" %}
{% load i18n satchmo_util %}
{# credit card pay_ship version - we just need to collect CC info #}

{% block extra-head %}
{{ block.super }}
{% include "shop/_jquery.html" %}
{% include "shop/_jquery_form.html" %}
{% blackbird_logging %}
<script type="text/javascript" src="{{ media_url }}js/satchmo_pay_ship.js"></script>
<script type="text/javascript"><!--
$(function() {satchmo.setup_issue_fields({{ form.requires_issue_number|as_json }})});
-->
</script>
{% endblock %}

{% block payment_table %}
    <tr><td><h4>{% trans "Payment Information" %}</h4></td></tr>
    {% if not PAYMENT_LIVE %}
    <tr><td valign="top"><b>TEST MODE</b></td><td><i>Use Visa 4111111111111111 for CC#<br/>any future date for expiration<br/>any 3 digit CCV</i></td></tr>
    {% endif %}

    <tr><td><label for="id_card_holder">{% trans "Card Holder" %}</label></td> <td>{{ form.card_holder }}</td></tr>
    {% if form.card_holder.errors %}<tr><td></td><td>*** {{ form.card_holder.errors|join:", " }}</td></tr>{% endif %}

    <tr><td><label for="id_credit_type">{% trans "Type of credit card" %}</label></td> <td>{{ form.credit_type }}</td></tr>
    {% if form.credit_type.errors %}<tr><td></td><td>*** {{ form.credit_type.errors|join:", " }}</td></tr>{% endif %}

    <tr><td><label for="id_credit_number">{% trans "Credit card number" %}</label></td><td> {{ form.credit_number }}</td></tr>
    {% if form.credit_number.errors %}<tr><td></td><td>*** {{ form.credit_number.errors|join:", " }}</td></tr>{% endif %}

    <tr class="issue"><td><label for="id_issue_num">{% trans "Issue number" %}</label></td><td> {{ form.issue_num }}</td></tr>
    {% if form.issue_num.errors %}<tr><td></td><td>*** {{ form.issue_num.errors|join:", " }}</td></tr>{% endif %}

    <tr class="issue"><td><label for="id_year_start">{% trans "Issue date" %}</label><label for="id_year_start"></label></td><td> {{ form.month_start}} {{ form.year_start }}</td></tr>
    {% if form.year_start.errors %}<tr><td></td><td>*** {{ form.year_start.errors|join:", " }}</td></tr>{% endif %}
    {% if form.month_start.errors %}<tr><td></td><td>*** {{ form.month_start.errors|join:", " }}</td></tr>{% endif %}

    <tr><td><label for="id_month_expires">{% trans "Expiration date" %}</label><label for="id_year_expires"></label></td><td> {{ form.month_expires }} {{form.year_expires}}</td></tr>
    {% if form.year_expires.errors %}<tr><td></td><td>*** {{ form.year_expires.errors|join:", " }}</td></tr>{% endif %}

    <tr><td><label for="id_ccv">{% trans "CCV" %}</label></td><td> {{ form.ccv}}</td></tr>
    {% if form.ccv.errors %}<tr><td></td><td>*** {{ form.ccv.errors|join:", " }}</td></tr>{% endif %}

{% endblock %}
