diff options
Diffstat (limited to 'alphabetlearning/templates/payments')
-rw-r--r-- | alphabetlearning/templates/payments/cart_lineitem.html | 2 | ||||
-rw-r--r-- | alphabetlearning/templates/payments/cartitem_confirm_delete.html | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/alphabetlearning/templates/payments/cart_lineitem.html b/alphabetlearning/templates/payments/cart_lineitem.html index 79899df..9524d96 100644 --- a/alphabetlearning/templates/payments/cart_lineitem.html +++ b/alphabetlearning/templates/payments/cart_lineitem.html @@ -12,7 +12,7 @@ </div> <div class="p-2"> <p>{{ item.resource.card_description }}</p> - <p><a class="btn btn-danger btn-sm fs-6 text" href="#">Remove from basket</a></p> + <p><a class="btn btn-danger btn-sm fs-6 text" href="{% url "payments:delete_cart_item" item.pk %}">Remove from basket</a></p> </div> </div> </div> diff --git a/alphabetlearning/templates/payments/cartitem_confirm_delete.html b/alphabetlearning/templates/payments/cartitem_confirm_delete.html new file mode 100644 index 0000000..da3b81e --- /dev/null +++ b/alphabetlearning/templates/payments/cartitem_confirm_delete.html @@ -0,0 +1,7 @@ +<!- TODO improve the handling of this and make it htmx -> +<form method="post"> + {% csrf_token %} + <p>Are you sure you want to delete "{{ object }}"?</p> + {{ form }} + <input type="submit" value="Confirm"> +</form> |