mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-24 23:49:19 +00:00
[website] [product] show currency symbol and show specifications below the image
This commit is contained in:
@@ -7,4 +7,7 @@
|
||||
font-size: 18px;
|
||||
line-height: 200%;
|
||||
}
|
||||
.item-price {
|
||||
margin-top: 20px;
|
||||
}
|
||||
</style>
|
||||
@@ -35,23 +35,25 @@
|
||||
{{ web_long_description or web_short_description or
|
||||
"[No description given]" }}
|
||||
</div>
|
||||
{% if obj.doclist.get({"doctype":"Item Website Specification"}) %}
|
||||
<div class="item-price hide"></div>
|
||||
<div class="item-stock"></div>
|
||||
</div>
|
||||
</div>
|
||||
{% if obj.doclist.get({"doctype":"Item Website Specification"}) -%}
|
||||
<div class="row" style="margin-top: 20px">
|
||||
<div class="span12">
|
||||
<h4>Specifications</h4>
|
||||
<table class="table table-bordered" style="width: 100%">
|
||||
{% for d in obj.doclist.get(
|
||||
{"doctype":"Item Website Specification"}) %}
|
||||
{"doctype":"Item Website Specification"}) -%}
|
||||
<tr>
|
||||
<td style="width: 30%;">{{ d.label }}</td>
|
||||
<td>{{ d.description }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
{%- endfor %}
|
||||
</table>
|
||||
{% endif %}
|
||||
<div class="item-price hide">
|
||||
<p>Price:</p>
|
||||
</div>
|
||||
<div class="item-stock"></div>
|
||||
</div>
|
||||
</div>
|
||||
{%- endif %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -26,8 +26,8 @@ $(document).ready(function() {
|
||||
success: function(data) {
|
||||
if(data.message) {
|
||||
if(data.message.price) {
|
||||
$("<h4>").html(data.message.price[0].ref_currency + " "
|
||||
+ data.message.price[0].ref_rate).appendTo(".item-price");
|
||||
$("<h4>").html(data.message.price.ref_currency + " "
|
||||
+ data.message.price.ref_rate).appendTo(".item-price");
|
||||
$(".item-price").toggle(true);
|
||||
}
|
||||
if(data.message.stock==0) {
|
||||
|
||||
Reference in New Issue
Block a user