Kanchan Chauhan | e0818f8 | 2016-04-22 14:39:02 +0530 | [diff] [blame] | 1 | {% extends "templates/web.html" %} |
| 2 | |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 3 | {% from "erpnext/templates/includes/macros.html" import render_homepage_section %} |
Kanchan Chauhan | e0818f8 | 2016-04-22 14:39:02 +0530 | [diff] [blame] | 4 | |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 5 | {% block content %} |
| 6 | <main> |
| 7 | {% if homepage.hero_section_based_on == 'Default' %} |
mergify[bot] | 5b7b583 | 2022-07-26 13:46:03 +0530 | [diff] [blame] | 8 | <section class="hero-section border-bottom {%if homepage.hero_image%}hero-image{%endif%}" |
| 9 | {% if homepage.hero_image %} |
| 10 | style="background-image: url('{{ homepage.hero_image }}');" |
| 11 | {%- endif %} |
| 12 | > |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 13 | <div class="container py-5"> |
| 14 | <h1 class="d-none d-sm-block display-4">{{ homepage.tag_line }}</h1> |
| 15 | <h1 class="d-block d-sm-none">{{ homepage.tag_line }}</h1> |
| 16 | <h2 class="d-none d-sm-block">{{ homepage.description }}</h2> |
| 17 | <h3 class="d-block d-sm-none">{{ homepage.description }}</h3> |
Rushabh Mehta | ac123c5 | 2016-05-20 16:36:56 +0530 | [diff] [blame] | 18 | </div> |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 19 | |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 20 | </section> |
| 21 | {% elif homepage.hero_section_based_on == 'Slideshow' and slideshow %} |
| 22 | <section class="hero-section"> |
| 23 | {% include "templates/includes/slideshow.html" %} |
| 24 | </section> |
| 25 | {% elif homepage.hero_section_based_on == 'Homepage Section' %} |
| 26 | {{ render_homepage_section(homepage.hero_section_doc) }} |
| 27 | {% endif %} |
| 28 | |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 29 | {% if blogs %} |
| 30 | <section class="container my-5"> |
| 31 | <h3>{{ _('Publications') }}</h3> |
Rushabh Mehta | ac123c5 | 2016-05-20 16:36:56 +0530 | [diff] [blame] | 32 | |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 33 | <div class="row"> |
| 34 | {% for blog in blogs %} |
| 35 | <div class="col-md-4 mb-4"> |
| 36 | <div class="card h-100"> |
| 37 | <div class="card-body"> |
| 38 | <h5 class="card-title">{{ blog.title }}</h5> |
| 39 | <p class="card-subtitle mb-2 text-muted">{{ _('By {0}').format(blog.blogger) }}</p> |
| 40 | <p class="card-text">{{ blog.blog_intro }}</p> |
| 41 | </div> |
| 42 | <div class="card-body flex-grow-0"> |
| 43 | <a href="{{ blog.route }}" class="card-link">{{ _('Read blog') }}</a> |
| 44 | </div> |
| 45 | </div> |
| 46 | </div> |
| 47 | {% endfor %} |
| 48 | </div> |
| 49 | </section> |
| 50 | {% endif %} |
Kanchan Chauhan | 239b351 | 2016-05-02 11:43:44 +0530 | [diff] [blame] | 51 | |
Faris Ansari | 5f8b358 | 2019-03-19 11:48:32 +0530 | [diff] [blame] | 52 | {% for section in homepage_sections %} |
| 53 | {{ render_homepage_section(section) }} |
| 54 | {% endfor %} |
| 55 | </main> |
Ankush Menat | 4551d7d | 2021-08-19 13:41:10 +0530 | [diff] [blame] | 56 | {% endblock %} |