From b8eaa3d3777a30373abb1dfe78ec0de4d1ecf89f Mon Sep 17 00:00:00 2001 From: Faris Ansari Date: Sat, 1 Jun 2019 20:56:37 +0530 Subject: [PATCH] fix: Issue list portal styling --- erpnext/templates/includes/issue_row.html | 59 +++++++++++------------ erpnext/templates/includes/macros.html | 2 +- 2 files changed, 29 insertions(+), 32 deletions(-) diff --git a/erpnext/templates/includes/issue_row.html b/erpnext/templates/includes/issue_row.html index 637fde26c5..ff868fabb5 100644 --- a/erpnext/templates/includes/issue_row.html +++ b/erpnext/templates/includes/issue_row.html @@ -1,33 +1,30 @@
- -
-
- - {{ doc.name }} -
-
- {{ doc.subject }}
-
- Medium - {% elif doc.priority == "Low" %} - yellow"> Low - {% else %} - red"> High - {% endif %} - {% elif doc.status == "Closed" %} - green"> Closed - {% else %} - darkgrey"> {{ doc.status }} - {% endif %} - -
-
- {{ frappe.format_date(doc.modified) }} -
-
-
+ +
+
+ {% set indicator = 'red' if doc.status == 'Open' else 'darkgrey' %} + {% set indicator = 'green' if doc.status == 'Closed' else indicator %} + + {{ doc.name }} +
+
+ {{ doc.subject }}
+
+ {% set indicator = 'red' if doc.status == 'Open' else 'darkgrey' %} + {% set indicator = 'green' if doc.status == 'Closed' else indicator %} + {% set indicator = 'orange' if doc.status == 'Open' and doc.priority == 'Medium' else indicator %} + {% set indicator = 'yellow' if doc.status == 'Open' and doc.priority == 'Low' else indicator %} + + {% if doc.status == "Open" %} + {{ doc.priority }} + {% else %} + {{ doc.status }} + {%- endif -%} + +
+
+ {{ frappe.format_date(doc.modified) }} +
+
+
- \ No newline at end of file diff --git a/erpnext/templates/includes/macros.html b/erpnext/templates/includes/macros.html index 2d27915aa8..3c82e90cc0 100644 --- a/erpnext/templates/includes/macros.html +++ b/erpnext/templates/includes/macros.html @@ -45,7 +45,7 @@
{{ card.title }}

{{ card.subtitle or '' }}

-

{{ card.content | truncate(140, True) }}

+

{{ card.content or '' | truncate(140, True) }}

{{ _('More details') }}