From 108fbb09b00bf15a77201aa162506d9f326bfa16 Mon Sep 17 00:00:00 2001 From: PCoder Date: Mon, 24 Jun 2019 04:29:34 +0200 Subject: [PATCH] Add ssh key form to order_detail page To ask for the SSH key at the time of confirming and placing the order. The order does not proceed until the user provides a valid ssh key. --- .../datacenterlight/order_detail.html | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/datacenterlight/templates/datacenterlight/order_detail.html b/datacenterlight/templates/datacenterlight/order_detail.html index 31933e12..fa2ba7ca 100644 --- a/datacenterlight/templates/datacenterlight/order_detail.html +++ b/datacenterlight/templates/datacenterlight/order_detail.html @@ -134,6 +134,27 @@
{% csrf_token %} + {% if generic_payment_details %} + {% else %} + {% comment %} + We are in VM buy flow and we want user to click the "Place order" button. + At this point, we also want the user to input the SSH key for the VM. + {% endcomment %} + + {% if messages %} +
+ {% for message in messages %} + {{ message }} + {% endfor %} +
+ {% endif %} +
+

 {% trans "Add your public SSH key" %}

+
+ {% for field in form %} + {% bootstrap_field field %} + {% endfor %} + {% endif %}
{% if generic_payment_details %}