fix(shopping cart): UX Improvements (#21034)
* fix: nontype error for resolved and moved place order button at bottom left
* fix: removed inline style
* fix: Request for quotation move to lower right
* fix: move buttons
Co-authored-by: Naren <patilnarendra3@gmail.com>
Co-authored-by: Saqib <nextchamp.saqib@gmail.com>
diff --git a/erpnext/public/scss/website.scss b/erpnext/public/scss/website.scss
index 7b9a70d..735b417 100644
--- a/erpnext/public/scss/website.scss
+++ b/erpnext/public/scss/website.scss
@@ -78,3 +78,7 @@
z-index: 0;
}
}
+
+.place-order-container {
+ text-align: right;
+}
\ No newline at end of file
diff --git a/erpnext/templates/includes/order/order_taxes.html b/erpnext/templates/includes/order/order_taxes.html
index 4a32aa4..ebec838 100644
--- a/erpnext/templates/includes/order/order_taxes.html
+++ b/erpnext/templates/includes/order/order_taxes.html
@@ -10,16 +10,16 @@
{% endif %}
{% for d in doc.taxes %}
-{% if d.base_tax_amount > 0 %}
-<tr>
- <td class="text-right" colspan="2">
- {{ d.description }}
- </td>
- <td class="text-right">
- {{ d.get_formatted("base_tax_amount") }}
- </td>
-</tr>
-{% endif %}
+ {% if d.base_tax_amount %}
+ <tr>
+ <td class="text-right" colspan="2">
+ {{ d.description }}
+ </td>
+ <td class="text-right">
+ {{ d.get_formatted("base_tax_amount") }}
+ </td>
+ </tr>
+ {% endif %}
{% endfor %}
{% if doc.doctype == 'Quotation' %}
diff --git a/erpnext/templates/pages/cart.html b/erpnext/templates/pages/cart.html
index 912702e..3033d15 100644
--- a/erpnext/templates/pages/cart.html
+++ b/erpnext/templates/pages/cart.html
@@ -12,16 +12,6 @@
{% block header_actions %}
-{% if doc.items and cart_settings.enable_checkout %}
-<button class="btn btn-primary btn-place-order" type="button">
- {{ _("Place Order") }}
-</button>
-{% endif %}
-{% if doc.items and not cart_settings.enable_checkout %}
-<button class="btn btn-primary btn-request-for-quotation" type="button">
- {{ _("Request for Quotation") }}
-</button>
-{% endif %}
{% endblock %}
{% block page_content %}
@@ -56,6 +46,20 @@
{% endif %}
{% if doc.items %}
+ <div class="place-order-container">
+ {% if cart_settings.enable_checkout %}
+ <button class="btn btn-primary btn-place-order" type="button">
+ {{ _("Place Order") }}
+ </button>
+ {% else %}
+ <button class="btn btn-primary btn-request-for-quotation" type="button">
+ {{ _("Request for Quotation") }}
+ </button>
+ {% endif %}
+ </div>
+ {% endif %}
+
+ {% if doc.items %}
{% if doc.tc_name %}
<div class="terms-and-conditions-link">
<a href class="link-terms-and-conditions" data-terms-name="{{ doc.tc_name }}">