From 4a5c62692c2a0afd2f23cd01c7e5db6ebff500e6 Mon Sep 17 00:00:00 2001 From: Mark Calvert Date: Fri, 23 Feb 2024 09:13:20 +0800 Subject: [PATCH] Created patch for CKAN core bug https://github.com/ckan/ckan/pull/8020 --- ckan/patches/00_test_test.patch | 1 - ...ve_custom_org_type_in_user_activity_streams.patch | 12 ++++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) delete mode 100644 ckan/patches/00_test_test.patch create mode 100644 ckan/patches/ckan/8020_preserve_custom_org_type_in_user_activity_streams.patch diff --git a/ckan/patches/00_test_test.patch b/ckan/patches/00_test_test.patch deleted file mode 100644 index 30d74d25..00000000 --- a/ckan/patches/00_test_test.patch +++ /dev/null @@ -1 +0,0 @@ -test \ No newline at end of file diff --git a/ckan/patches/ckan/8020_preserve_custom_org_type_in_user_activity_streams.patch b/ckan/patches/ckan/8020_preserve_custom_org_type_in_user_activity_streams.patch new file mode 100644 index 00000000..a05ced5c --- /dev/null +++ b/ckan/patches/ckan/8020_preserve_custom_org_type_in_user_activity_streams.patch @@ -0,0 +1,12 @@ +diff --git a/ckanext/activity/templates/snippets/stream.html b/ckanext/activity/templates/snippets/stream.html +index 52c0d4b49..270a5f22f 100644 +--- a/ckanext/activity/templates/snippets/stream.html ++++ b/ckanext/activity/templates/snippets/stream.html +@@ -14,6 +14,7 @@ + {% endmacro %} + + {% macro organization(activity) %} ++ {% set group_type = group_type or (activity.data.group.type if (activity.data.group and activity.data.group.type) else 'organization') %} + + {{ activity.data.group.title if activity.data.group else _('unknown') }} +