<commit_before>{% extends "oscar/checkout/checkout.html" %}
{% load i18n %}

{% block title %}
    {% trans "Shipping address" %} | {{ block.super }}
{% endblock %}

{% block checkout_nav %}
    {% include 'oscar/checkout/nav.html' with step=1 %}
{% endblock %}

{% block checkout_title %}{% trans "Shipping address" %}{% endblock %}

{% block order_contents %}{% endblock %}

{% block shipping_address %}
<div class="col-sm-12">
    <div class="sub-header">
        <h2>{% trans "Where should we ship to?" %}</h2>
    </div>
    {% if user.is_authenticated %}
        {% if addresses %}
            <h3>{% trans "An address from your address book?" %}</h3>
            <div class="choose-block">
                <div class="row">
                    {% for address in addresses %}
                        {% block select_address_form %}
                            <div class="col-sm-6">
                                <div class="well">
                                    <address>
                                        {% block select_address_fields %}
                                            {% for field in address.active_address_fields %}
                                                <span>{{ field }}</span>{% if not forloop.first %}<br/>{% endif %}
                                            {% endfor %}
                                        {% endblock %}
                                    </address>
                                    <form action="{% url 'checkout:shipping-address' %}" method="post" id="select_shipping_address_{{ address.id }}">
                                        {% csrf_token %}
                                        <input type="hidden" name="action" value="ship_to" />
                                        <input type="hidden" name="address_id" value="{{ address.id }}" />
                                        {% if address.is_default_for_shipping %}
                                            <button type="submit" class="btn btn-success btn-large ship-address" data-loading-text="{% trans 'Saving...' %}"><i class="icon-ok"></i> {% trans "Ship to your default shipping address" %}</button>
                                        {% else %}
                                            <button type="submit" class="btn btn-primary btn-large ship-address" data-loading-text="{% trans 'Saving...' %}">{% trans "Ship to this address" %}</button>
                                        {% endif %}

                                        <div class="btn-group address-controls">
                                            <a href="{% url 'checkout:user-address-update' pk=address.id %}" class="btn btn-default btn-sm">{% trans "Edit address" %}</a>
                                            <button class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown">
                                                <span class="caret"></span>
                                            </button>
                                            <ul class="dropdown-menu">
                                                <li><a href="{% url 'checkout:user-address-delete' pk=address.id %}" class="btn-remove-address">{% trans "Delete" %}</a></li>
                                            </ul>
                                        </div><commit_msg>"Saving..." -> "Submitting..." on using saved address<commit_after>{% extends "oscar/checkout/checkout.html" %}
{% load i18n %}

{% block title %}
    {% trans "Shipping address" %} | {{ block.super }}
{% endblock %}

{% block checkout_nav %}
    {% include 'oscar/checkout/nav.html' with step=1 %}
{% endblock %}

{% block checkout_title %}{% trans "Shipping address" %}{% endblock %}

{% block order_contents %}{% endblock %}

{% block shipping_address %}
<div class="col-sm-12">
    <div class="sub-header">
        <h2>{% trans "Where should we ship to?" %}</h2>
    </div>
    {% if user.is_authenticated %}
        {% if addresses %}
            <h3>{% trans "An address from your address book?" %}</h3>
            <div class="choose-block">
                <div class="row">
                    {% for address in addresses %}
                        {% block select_address_form %}
                            <div class="col-sm-6">
                                <div class="well">
                                    <address>
                                        {% block select_address_fields %}
                                            {% for field in address.active_address_fields %}
                                                <span>{{ field }}</span>{% if not forloop.first %}<br/>{% endif %}
                                            {% endfor %}
                                        {% endblock %}
                                    </address>
                                    <form action="{% url 'checkout:shipping-address' %}" method="post" id="select_shipping_address_{{ address.id }}">
                                        {% csrf_token %}
                                        <input type="hidden" name="action" value="ship_to" />
                                        <input type="hidden" name="address_id" value="{{ address.id }}" />
                                        {% if address.is_default_for_shipping %}
                                            <button type="submit" class="btn btn-success btn-large ship-address" data-loading-text="{% trans 'Submitting...' %}"><i class="icon-ok"></i> {% trans "Ship to your default shipping address" %}</button>
                                        {% else %}
                                            <button type="submit" class="btn btn-primary btn-large ship-address" data-loading-text="{% trans 'Submitting...' %}">{% trans "Ship to this address" %}</button>
                                        {% endif %}

                                        <div class="btn-group address-controls">
                                            <a href="{% url 'checkout:user-address-update' pk=address.id %}" class="btn btn-default btn-sm">{% trans "Edit address" %}</a>
                                            <button class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown">
                                                <span class="caret"></span>
                                            </button>
                                            <ul class="dropdown-menu">
                                                <li><a href="{% url 'checkout:user-address-delete' pk=address.id %}" class="btn-remove-address">{% trans "Delete" %}</a></li>
                                            </ul>
                                        </div>
{'fraction_non_alphanumeric': 0.13841554559043348, 'fraction_numerical': 0.0029895366218236174, 'mean_word_length': 1.1542176432710882, 'pattern_counts': {'":': 0, '<': 81, '<?xml version=': 0, '>': 82, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 88, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6812997', 'n_tokens_mistral': 1584, 'n_tokens_neox': 1430, 'n_words': 364}