blob: 4d4f5d446955f170ef246440352f06120d286cad [file] [log] [blame]
Anand Doshi5d591eb2014-04-18 16:15:31 +05301{% block title %} {{ title }} {% endblock %}
2
3{% block header %}<h2>{{ title }}</h2>{% endblock %}
4
5{% block content %}
6<div class="item-content">
7 {% include 'templates/includes/product_search_box.html' %}
8 {% include 'templates/includes/product_breadcrumbs.html' %}
9 <div class="product-page-content" itemscope itemtype="http://schema.org/Product">
10 <div class="row">
11 <div class="col-md-6">
12 {% if slideshow %}
13 {% include "templates/includes/slideshow.html" %}
14 {% else %}
15 {% if website_image %}
16 <image itemprop="image" class="item-main-image"
17 src="{{ website_image }}" />
18 {% else %}
19 <div class="img-area">
20 {% include 'templates/includes/product_missing_image.html' %}
21 </div>
22 {% endif %}
23 {% endif %}
24 </div>
25 <div class="col-md-6">
26 <h3 itemprop="name" style="margin-top: 0px;">{{ item_name }}</h3>
27 <p class="help">Item Code: <span itemprop="productID">{{ name }}</span></p>
28 <h4>Product Description</h4>
29 <div itemprop="description">
30 {{ web_long_description or description or "[No description given]" }}
31 </div>
32 <div style="min-height: 100px; margin: 10px 0;">
33 <div class="item-price-info" style="display: none;">
34 <h4 class="item-price" itemprop="price"></h4>
35 <div class="item-stock" itemprop="availablity"></div>
36 <div id="item-add-to-cart">
37 <button class="btn btn-primary">
38 <i class="icon-shopping-cart"></i> Add to Cart</button>
39 </div>
40 <div id="item-update-cart" class="input-group col-md-4" style="display: none;
41 padding-left: 0px; padding-right: 0px;">
42 <input class="form-control" type="text">
43 <div class="input-group-btn">
44 <button class="btn btn-primary">
45 <i class="icon-ok"></i></button>
46 </div>
47 </div>
48 </div>
49 </div>
50 </div>
51 </div>
52 {% if doc.get({"doctype":"Item Website Specification"}) -%}
53 <div class="row" style="margin-top: 20px">
54 <div class="col-md-12">
55 <h4>Specifications</h4>
56 <table class="table table-bordered" style="width: 100%">
57 {% for d in doc.get(
58 {"doctype":"Item Website Specification"}) -%}
59 <tr>
60 <td style="width: 30%;">{{ d.label }}</td>
61 <td>{{ d.description }}</td>
62 </tr>
63 {%- endfor %}
64 </table>
65 </div>
66 </div>
67 {%- endif %}
68 </div>
69</div>
70<script>
71 {% include "templates/includes/product_page.js" %}
72
73 $(function() {
74 if(window.logged_in && getCookie("system_user")==="yes") {
75 frappe.has_permission("Item", "{{ name }}", "write", function(r) {
76 frappe.require("/assets/frappe/js/frappe/website/editable.js");
77 frappe.make_editable($('[itemprop="description"]'), "Item", "{{ name }}", "web_long_description");
78 });
79 }
80 });
81</script>
82{% endblock %}
83
84{% block sidebar %}{% include "templates/includes/sidebar.html" %}{% endblock %}