From 50f7227b10cce806dc485084eee6688cfd78bdd6 Mon Sep 17 00:00:00 2001 From: Polycarp Okock Date: Thu, 20 Jul 2017 15:00:14 +0300 Subject: [PATCH 1/2] Updated Order_detail Added the tag to load the Card holder name entered from the billing address --- datacenterlight/templates/datacenterlight/order_detail.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datacenterlight/templates/datacenterlight/order_detail.html b/datacenterlight/templates/datacenterlight/order_detail.html index 4b8862df..8b1180bb 100644 --- a/datacenterlight/templates/datacenterlight/order_detail.html +++ b/datacenterlight/templates/datacenterlight/order_detail.html @@ -35,7 +35,7 @@

{% trans "Billed To:"%}

{% with request.session.billing_address_data as billing_address %} - {{request.session.user.name}}
{{billing_address|get_value_from_dict:'street_address'}}, {{billing_address|get_value_from_dict:'postal_code'}}
+ {{billing_address|get_value_from_dict:'cardholder_name'}}
{{billing_address|get_value_from_dict:'street_address'}}, {{billing_address|get_value_from_dict:'postal_code'}}
{{billing_address|get_value_from_dict:'city'}}, {{billing_address|get_value_from_dict:'country'}}. {% endwith %}
From 7a8154a907b74c1dbc7b0bfdd9b8becce5f9020c Mon Sep 17 00:00:00 2001 From: Polycarp Okock Date: Thu, 20 Jul 2017 15:02:59 +0300 Subject: [PATCH 2/2] Updated Views Added the cardholder_name as one of the fields retrieved from the Payment page --- datacenterlight/views.py | 1 + 1 file changed, 1 insertion(+) diff --git a/datacenterlight/views.py b/datacenterlight/views.py index ea7ca3ef..6b0e0d7e 100644 --- a/datacenterlight/views.py +++ b/datacenterlight/views.py @@ -343,6 +343,7 @@ class PaymentOrderView(FormView): if billing_address_data: form_kwargs.update({ 'initial': { + 'cardholder_name': billing_address_data['cardholder_name'], 'street_address': billing_address_data['street_address'], 'city': billing_address_data['city'], 'postal_code': billing_address_data['postal_code'],