From fbab8aec7ff723c07212949b16c0c48f1fce93d3 Mon Sep 17 00:00:00 2001 From: Oksana Shadura Date: Mon, 6 Jan 2025 17:15:23 +0100 Subject: [PATCH] Tring to fix publication lists --- _data/publications/2598292.yml | 2 + _data/publications/2738557.yml | 2 + _data/publications/2743013.yml | 2 + _data/publications/2743608.yml | 2 + .../oshadura-alheld-agc-acat2022.yml | 2 + _layouts/challenge-area.html | 1 - _layouts/presentations.html | 2 + _scripts/get_pub.py | 1 + _scripts/publication.schema.json | 15 ++++++ pages/presentations/bychallenge.md | 48 +++++++++++++++++++ 10 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 pages/presentations/bychallenge.md diff --git a/_data/publications/2598292.yml b/_data/publications/2598292.yml index f362d03b8..a00b648c1 100644 --- a/_data/publications/2598292.yml +++ b/_data/publications/2598292.yml @@ -1,3 +1,5 @@ inspire-id: 2598292 project: - agc +challenge-area: + - agc diff --git a/_data/publications/2738557.yml b/_data/publications/2738557.yml index 2c1818d25..8fb43189f 100644 --- a/_data/publications/2738557.yml +++ b/_data/publications/2738557.yml @@ -1,3 +1,5 @@ inspire-id: 2738557 project: - agc +challenge-area: + - agc diff --git a/_data/publications/2743013.yml b/_data/publications/2743013.yml index b776be72b..1d0b6d5ea 100644 --- a/_data/publications/2743013.yml +++ b/_data/publications/2743013.yml @@ -1,3 +1,5 @@ inspire-id: 2743013 project: - agc +challenge-area: + - agc diff --git a/_data/publications/2743608.yml b/_data/publications/2743608.yml index faff8a8a6..4713f0e0b 100644 --- a/_data/publications/2743608.yml +++ b/_data/publications/2743608.yml @@ -1,3 +1,5 @@ inspire-id: 2743608 project: - agc +challenge-area: + - agc diff --git a/_data/publications/oshadura-alheld-agc-acat2022.yml b/_data/publications/oshadura-alheld-agc-acat2022.yml index 11bc707c6..4493a892e 100644 --- a/_data/publications/oshadura-alheld-agc-acat2022.yml +++ b/_data/publications/oshadura-alheld-agc-acat2022.yml @@ -7,3 +7,5 @@ focus-area: - doma - as project: agc +challenge-area: + - agc diff --git a/_layouts/challenge-area.html b/_layouts/challenge-area.html index e33262e3e..f13fbffec 100644 --- a/_layouts/challenge-area.html +++ b/_layouts/challenge-area.html @@ -145,7 +145,6 @@

Join us

- {% include_cached footer.html %} diff --git a/_layouts/presentations.html b/_layouts/presentations.html index 6c01c0528..35d1dfd33 100644 --- a/_layouts/presentations.html +++ b/_layouts/presentations.html @@ -10,6 +10,8 @@ Presentations: by area • + by area + • by institutionby date diff --git a/_scripts/get_pub.py b/_scripts/get_pub.py index c9f4fa832..1c7e882a3 100755 --- a/_scripts/get_pub.py +++ b/_scripts/get_pub.py @@ -71,6 +71,7 @@ def summarize_record(recid : int, *, max_authors : int = 5): mini_dict.update({ 'focus-area': '', + 'challenge-area': '', 'project': '', }) diff --git a/_scripts/publication.schema.json b/_scripts/publication.schema.json index 795da430a..dfbd24c2e 100644 --- a/_scripts/publication.schema.json +++ b/_scripts/publication.schema.json @@ -19,6 +19,9 @@ "focus-area": { "$ref": "#/definitions/focus_areas" }, + "challenge-area": { + "$ref": "#/definitions/challenge_areas" + }, "title": { "type": "string" }, "date": { "type": "string", "format": "date" }, "citation": { "type": "string" }, @@ -50,6 +53,18 @@ { "type": "array", "items": { "$ref": "#/definitions/focus_area" } } ] }, + "challenge_area": { + "enum": [ + "agc" + ] + }, + "challenge_areas": { + "oneOf": [ + { "type": "null" }, + { "$ref": "#/definitions/challenge_area" }, + { "type": "array", "items": { "$ref": "#/definitions/challenge_area" } } + ] + }, "string_or_array": { "oneOf": [ { "type": "null" }, diff --git a/pages/presentations/bychallenge.md b/pages/presentations/bychallenge.md new file mode 100644 index 000000000..05809cc01 --- /dev/null +++ b/pages/presentations/bychallenge.md @@ -0,0 +1,48 @@ +--- +permalink: /presentations/bychallenge.html +layout: presentations +title: Presentations by Challenge +--- + +{% assign sorted_presentations = site.data['sorted_presentations'] %} + + + +

Presentations by the IRIS-HEP team

+{% assign prescount = 0 %} + +{% assign activities = site.pages | where: "layout", "challenge-area" | where_exp: "item", "item.draft != true" | sort_natural: 'title' %} + +{% for challenge-area-page in activities %} + {% assign challenge-area-title = challenge-area-page.title %} + {% assign challenge-area-name = challenge-area-page.name | basename %} +

{{ challenge-area-title }}

+
    + {% for talk in sorted_presentations %} + {% if talk.challenge-area contains challenge-area-name %} +
  • + {%- include print_pres.html talk=talk -%} +
  • + {% assign prescount = prescount | plus: "1" %} + {% endif %} + {% endfor %} +
+{% endfor %} + + +

General

+
    +{% for talk in sorted_presentations %} + {% if talk.challenge-area == nil %} +
  • + {%- include print_pres.html talk=talk -%} +
  • + {% assign prescount = prescount | plus: "1" %} + {% endif %} +{% endfor %} +
+ +Total presentations (presentations spanning multiple areas listed multiple times): {{ prescount }}.