From 724f505a8f7e3fef417ea204cb39bc54d042cf50 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Fri, 4 Jan 2019 12:39:02 +0100 Subject: Sheet: refactor display of fields (more compact) --- .../media/upload/templates/document_reference.odt | Bin 10626 -> 10678 bytes .../ishtar/blocks/sheet_creation_section.html | 18 ++++++-------- .../templates/ishtar/blocks/window_field_flex.html | 6 ++--- .../ishtar/blocks/window_field_flex_detail.html | 6 ++--- .../ishtar/blocks/window_field_flex_full.html | 6 ++--- .../window_field_flex_historized_multiple.html | 6 ++--- .../ishtar/blocks/window_field_flex_multiple.html | 6 ++--- .../blocks/window_field_flex_multiple_full.html | 6 ++--- .../ishtar/blocks/window_field_flex_url.html | 6 ++--- scss/custom.scss | 27 ++++++++++++++++++++- 10 files changed, 55 insertions(+), 32 deletions(-) mode change 100644 => 100755 example_project/media/upload/templates/document_reference.odt diff --git a/example_project/media/upload/templates/document_reference.odt b/example_project/media/upload/templates/document_reference.odt old mode 100644 new mode 100755 index ffd697841..acda588fb Binary files a/example_project/media/upload/templates/document_reference.odt and b/example_project/media/upload/templates/document_reference.odt differ diff --git a/ishtar_common/templates/ishtar/blocks/sheet_creation_section.html b/ishtar_common/templates/ishtar/blocks/sheet_creation_section.html index 78126a240..6247920cd 100644 --- a/ishtar_common/templates/ishtar/blocks/sheet_creation_section.html +++ b/ishtar_common/templates/ishtar/blocks/sheet_creation_section.html @@ -1,20 +1,18 @@ {% load i18n link_to_window %} {% if item.history_creator.ishtaruser.person %} -
-
{% trans "Creation" context "Sheet" %}
-
- {{item.history_creator.ishtaruser.person}} - {{item.history_creator.ishtaruser.person|link_to_window}}
+
+
{% trans "Creation" context "Sheet" %}{{item.history_creator.ishtaruser.person|link_to_window}}
+
+ {{item.history_creator.ishtaruser.person}}
{{item.history_creation_date|date:"DATETIME_FORMAT"}}
{% endif %} {% if item.history_creation_date != item.last_edition_date %} -
-
{% trans "Modification" context "Sheet" %}
-
- {{item.history_modifier.ishtaruser.person}} - {{item.history_modifier.ishtaruser.person|link_to_window}}
+
+
{% trans "Modification" context "Sheet" %}{{item.history_modifier.ishtaruser.person|link_to_window}}
+
+ {{item.history_modifier.ishtaruser.person}}
{% firstof item.history_date|date:"DATETIME_FORMAT" item.history.all.0.history_date|date:"DATETIME_FORMAT" %}
diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex.html b/ishtar_common/templates/ishtar/blocks/window_field_flex.html index add2a5520..133750bee 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex.html @@ -1,6 +1,6 @@ {% load i18n %}{% if data %} -
-
{% trans caption %}
-
{{pre_data|safe}}{{data|linebreaksbr}}{{post_data|safe }}
+
+
{% trans caption %}
+
{{pre_data|safe}}{{data|linebreaksbr}}{{post_data|safe }}
{% endif %} diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_detail.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_detail.html index 6f5d80ba8..f7ca5ce8f 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_detail.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_detail.html @@ -1,6 +1,6 @@ {% load i18n %}{% if item %} -
-
{% trans caption %}
-
{{item}}{{link}}
+
+
{% trans caption %}{{link}}
+
{{item}}
{% endif %} diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_full.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_full.html index f44cdc6fd..ec337a5f8 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_full.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_full.html @@ -1,6 +1,6 @@ {% load i18n %}{% if data %} -
-
{% trans caption %}
-
{{pre_data|safe}}{{data|linebreaksbr}}{{post_data|safe }}
+
+
{% trans caption %}
+
{{pre_data|safe}}{{data|linebreaksbr}}{{post_data|safe }}
{% endif %} diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_historized_multiple.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_historized_multiple.html index a68bd0cb4..493585a60 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_historized_multiple.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_historized_multiple.html @@ -1,7 +1,7 @@ {% load i18n %}{% if data %} -
-
{% trans caption %}
-
{% for d in data %} +
+
{% trans caption %}
+
{% for d in data %} {% if forloop.counter0 %} ; {% endif %}{{ d }} {% endfor %}
diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple.html index 010200837..abf03ead1 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple.html @@ -1,7 +1,7 @@ {% load i18n %}{% if data.count %} -
-
{% trans caption %}
-
{% for d in data.all %} +
+
{% trans caption %}
+
{% for d in data.all %} {% if forloop.counter0 %} ; {% endif %}{{ d }} {% endfor %}
diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple_full.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple_full.html index b70c1d2fc..14cab4722 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple_full.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_multiple_full.html @@ -1,7 +1,7 @@ {% load i18n %}{% if data.count %} -
-
{% trans caption %}
-
{% for d in data.distinct.all %} +
+
{% trans caption %}
+
{% for d in data.distinct.all %} {% if forloop.counter0 %} ; {% endif %}{{ d }} {% endfor %}
diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_url.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_url.html index b3a801636..4f23ff74b 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_url.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_url.html @@ -1,7 +1,7 @@ {% load i18n %}{% if link %} -
-
{% trans caption %}
-
+
+
{% trans caption %}
+
{% if link_name %}{{link_name}}{% else %}{{link}}{% endif %}
diff --git a/scss/custom.scss b/scss/custom.scss index d0cbdc6eb..22f912879 100644 --- a/scss/custom.scss +++ b/scss/custom.scss @@ -225,7 +225,32 @@ textarea { height: 90px; } -.sheet h4 { color: $text-muted; } +.sheet { + .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, + .col-10, .col-11, .col-12, .col, .col-auto, .col-sm-1, .col-sm-2, .col-sm-3, + .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, + .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-sm-auto, .col-md-1, + .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, + .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-md-auto, + .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, + .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, + .col-lg, .col-lg-auto, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, + .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, + .col-xl-11, .col-xl-12, .col-xl, .col-xl-auto { + padding-right: 5px; + padding-left: 5px; + } + ol, ul, dl { + margin-bottom: 0.5rem; + } + dt { + line-height: 1.4em; + } + h4 { + color: $text-muted; + } +} + #bookmark-list .input-link{ width: 100%; -- cgit v1.2.3