title tag in a series list

Ali Alnubani alialnu at mellanox.com
Mon Jul 23 22:28:07 AEST 2018


BTW,
Is it ok that the diff of my previous email was saved by patchwork (http://patchwork.ozlabs.org/patch/947699/) without it having git-send-email as the x-mailer?
I see that there are no restrictions in the code, should there be?

Thanks,
Ali

From: Patchwork <patchwork-bounces+alialnu=mellanox.com at lists.ozlabs.org> On Behalf Of Ali Alnubani
Sent: Monday, July 23, 2018 2:48 PM
To: 'patchwork at lists.ozlabs.org' <patchwork at lists.ozlabs.org>
Cc: Thomas Monjalon <thomas at monjalon.net>
Subject: title tag in a series list

Hi,

I'm trying to set the HTML title tag in a series filtered list as the series title instead of the project name.
I did something like the following, but it's not working (obviously):

diff --git a/patchwork/templates/patchwork/list.html b/patchwork/templates/patchwork/list.html
index 180c560..d7476d6 100644
--- a/patchwork/templates/patchwork/list.html
+++ b/patchwork/templates/patchwork/list.html
@@ -3,7 +3,13 @@
{% load person %}
{% load static %}

-{% block title %}{{project.name}}{% endblock %}
+{% if filters.applied_filters %}
+ {% for filter in filters.applied_filters %}
+  {% if filter.name ==  "Series" %}
+   {% block title %}{{filter.condition}}{% endblock %}
+  {% endif %}
+ {% endfor %}
+{% endif %}
{% block patch_active %}active{% endblock %}

{% block body %}


How can I get this to work?
Any suggestions for a better approach?

Thanks,
Ali
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/patchwork/attachments/20180723/35c1b0ee/attachment.html>


More information about the Patchwork mailing list