From 50bc43a0671435f6aed5fafad163385115e0b26a Mon Sep 17 00:00:00 2001 From: Raghavendra Kamath Date: Wed, 28 Mar 2018 17:49:57 +0530 Subject: [PATCH] Add page head and add list macro --- foundation/public/less/erpnext-org-theme.less | 2 +- foundation/templates/includes/macros.html | 16 ++++++++++ foundation/templates/includes/page-head.html | 16 ++++++++++ foundation/templates/web.html | 31 +------------------ 4 files changed, 34 insertions(+), 31 deletions(-) create mode 100644 foundation/templates/includes/page-head.html diff --git a/foundation/public/less/erpnext-org-theme.less b/foundation/public/less/erpnext-org-theme.less index 8c1d62d7..4c064779 100644 --- a/foundation/public/less/erpnext-org-theme.less +++ b/foundation/public/less/erpnext-org-theme.less @@ -1,6 +1,6 @@ @import "variables.less"; -@import (css) "/assets/css/frappe-css.css"; @import (css) "reset.css"; +@import (css) "/assets/css/frappe-css.css"; @import "indicator.less"; .logo-img { diff --git a/foundation/templates/includes/macros.html b/foundation/templates/includes/macros.html index 43c65a3b..9d22e4b7 100644 --- a/foundation/templates/includes/macros.html +++ b/foundation/templates/includes/macros.html @@ -15,3 +15,19 @@ {% endmacro %} + +{% macro list(link, image, title, subtitle) %} +
+
+
+ + +
+
+ {% if title %}

{{ title }}

{% endif %} + {{ content }} +
+
+
+{% endmacro %} diff --git a/foundation/templates/includes/page-head.html b/foundation/templates/includes/page-head.html new file mode 100644 index 00000000..606809c7 --- /dev/null +++ b/foundation/templates/includes/page-head.html @@ -0,0 +1,16 @@ +
+
+

+ {{ title }} +

+
+
+ + + {% if self.header_actions() %} +
+ {% block header_actions %}{% endblock %} +
+ {% endif %} +
+
diff --git a/foundation/templates/web.html b/foundation/templates/web.html index 6b90bd36..50c292b6 100644 --- a/foundation/templates/web.html +++ b/foundation/templates/web.html @@ -8,41 +8,12 @@ {% include "templates/includes/web_sidebar.html" %}
-
-
- -
-
- {% block header %}{% endblock %} -
-
- {% if show_search %} -
- {% block search %} - {% include - 'templates/includes/search_box.html' %} - {% endblock %} -
- {% endif %} - - {% if self.header_actions() %} -
- {% block header_actions %}{% endblock %} -
- {% endif %} -
-
+ {% include "foundation/templates/includes/page-head.html" %}
{%- block page_content -%}{%- endblock -%}
- - {% endblock %}