blob: e074fa3cfa5560bc1c44998f32759318edcadcf8 [file] [log] [blame]
Rushabh Mehta51008f22016-01-01 17:23:12 +05301{% extends "templates/web.html" %}
2
Anand Doshi5d591eb2014-04-18 16:15:31 +05303{% block title %} {{ title }} {% endblock %}
4
Anand Doshi13bf1232016-01-04 17:50:40 +05305{% block breadcrumbs %}
6 {% include "templates/includes/breadcrumbs.html" %}
7{% endblock %}
8
Rushabh Mehta51008f22016-01-01 17:23:12 +05309{% block page_content %}
Anand Doshida858cc2015-02-24 17:50:44 +053010{% from "erpnext/templates/includes/macros.html" import product_image %}
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053011<div class="item-content" style="margin-top:20px;">
Anand Doshi5d591eb2014-04-18 16:15:31 +053012 <div class="product-page-content" itemscope itemtype="http://schema.org/Product">
13 <div class="row">
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053014 <div class="col-sm-6">
Anand Doshi5d591eb2014-04-18 16:15:31 +053015 {% if slideshow %}
16 {% include "templates/includes/slideshow.html" %}
17 {% else %}
Anand Doshida858cc2015-02-24 17:50:44 +053018 {{ product_image(website_image, "product-full-image") }}
Anand Doshi5d591eb2014-04-18 16:15:31 +053019 {% endif %}
20 </div>
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053021 <div class="col-sm-6" style="padding-left:20px;">
22 <h2 itemprop="name" style="margin-top: 0px;">{{ item_name }}</h2>
23
Rushabh Mehta3f517052014-04-21 22:10:15 +053024 <p class="text-muted">
Anand Doshi6d69ca62015-10-29 11:35:16 +053025 {{ _("Item Code") }}: <span itemprop="productID">{{ variant and variant.name or name }}</span></p>
Rushabh Mehta3f517052014-04-21 22:10:15 +053026 <br>
Anand Doshi25ef4ff2015-10-20 18:34:21 +053027 <div class="item-attribute-selectors">
28 {% if has_variants %}
29 {% for d in attributes %}
Anand Doshi3f3696d2015-10-26 19:57:31 +053030 {% if attribute_values[d.attribute] -%}
31 <div class="item-view-attribute {% if (attribute_values[d.attribute] | len)==1 -%} hidden {%- endif %}"
Anand Doshi25ef4ff2015-10-20 18:34:21 +053032 style="margin-bottom: 10px;">
33 <h6 class="text-muted">{{ _(d.attribute) }}</h6>
34 <select class="form-control"
35 style="max-width: 140px"
36 data-attribute="{{ d.attribute }}">
37 {% for value in attribute_values[d.attribute] %}
38 <option value="{{ value }}"
Anand Doshi3f3696d2015-10-26 19:57:31 +053039 {% if selected_attributes and selected_attributes[d.attribute]==value -%}
40 selected
41 {%- elif disabled_attributes and value in disabled_attributes.get(d.attribute, []) -%}
42 disabled
43 {%- endif %}>
Anand Doshi25ef4ff2015-10-20 18:34:21 +053044 {{ _(value) }}
45 </option>
46 {% endfor %}
47 </select>
48 </div>
Anand Doshi3f3696d2015-10-26 19:57:31 +053049 {%- endif %}
Anand Doshi25ef4ff2015-10-20 18:34:21 +053050 {% endfor %}
51 {% endif %}
52 </div>
53 <br>
Anand Doshi5d591eb2014-04-18 16:15:31 +053054 <div style="min-height: 100px; margin: 10px 0;">
Kanchan Chauhan239b3512016-05-02 11:43:44 +053055 <div itemprop="offers" itemscope itemtype="http://schema.org/Offer">
56 <h4 class="item-price" itemprop="price"></h4>
57 <div class="item-stock" itemprop="availability"></div>
58 </div>
Rushabh Mehta156ce602015-09-11 18:49:59 +053059 <div class="item-cart hide">
60 <div id="item-add-to-cart">
61 <button class="btn btn-primary btn-sm">
62 {{ _("Add to Cart") }}</button>
63 </div>
64 <div id="item-update-cart"
65 style="display: none;
66 padding-left: 0px; padding-right: 0px;
67 padding-top: 10px;">
Saurabh69f99752016-01-06 16:41:50 +053068 <a href="/cart">{{ _("Goto Cart") }}</a>
Rushabh Mehta156ce602015-09-11 18:49:59 +053069 </div>
70 </div>
Anand Doshi5d591eb2014-04-18 16:15:31 +053071 </div>
72 </div>
73 </div>
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053074 <div class="row item-website-description" style="margin-top:30px; margin-bottom:20px">
Anand Doshi5d591eb2014-04-18 16:15:31 +053075 <div class="col-md-12">
Kanchan Chauhan239b3512016-05-02 11:43:44 +053076 <div class="h6 text-uppercase">{{ _("Description") }}</div>
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053077 <div itemprop="description" class="item-desc">
78 {{ web_long_description or description or _("No description given") }}
79 </div>
80 </div>
81 </div>
82
83 {% if website_specifications -%}
84 <div class="row item-website-specification" style="margin-top: 40px">
85 <div class="col-md-12">
Kanchan Chauhan239b3512016-05-02 11:43:44 +053086 <div class="h6 text-uppercase">{{ _("Specifications") }}</div>
Anand Doshi7c0eadb2015-10-20 17:30:02 +053087
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053088 <table class="table borderless" style="width: 100%">
Anand Doshi7c0eadb2015-10-20 17:30:02 +053089 {% for d in website_specifications -%}
Anand Doshi5d591eb2014-04-18 16:15:31 +053090 <tr>
Kanchan Chauhan11638ba2016-04-20 16:20:49 +053091 <td class="product-label text-muted" style="width: 30%;">{{ d.label }}</td>
Anand Doshi5d591eb2014-04-18 16:15:31 +053092 <td>{{ d.description }}</td>
93 </tr>
94 {%- endfor %}
95 </table>
96 </div>
97 </div>
98 {%- endif %}
99 </div>
100</div>
101<script>
102 {% include "templates/includes/product_page.js" %}
103
Rushabh Mehta80d2a552015-10-05 16:27:52 +0530104 {% if variant_info %}
105 window.variant_info = {{ variant_info }};
Rushabh Mehta6e322d02015-10-07 14:30:19 +0530106 {% else %}
107 window.variant_info = null;
Rushabh Mehta80d2a552015-10-05 16:27:52 +0530108 {% endif %}
Anand Doshi5d591eb2014-04-18 16:15:31 +0530109</script>
110{% endblock %}