Skip to content

Commit

Permalink
publication_list: support links to presentations.
Browse files Browse the repository at this point in the history
  • Loading branch information
xuhdev committed Feb 28, 2017
1 parent b82395b commit 318f5b4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion v7/publication_list/publication_list.py
Expand Up @@ -112,7 +112,7 @@ def run(self):
bibtex_fields = dict(entry.fields)
# Remove some fields for the publicly available BibTeX file since they are mostly only
# used by this plugin.
for field_to_remove in ('abstract', 'fulltext'):
for field_to_remove in ('abstract', 'fulltext', 'presentation'):
if field_to_remove in bibtex_fields:
del bibtex_fields[field_to_remove]
bibtex_entry = Entry(entry.type, bibtex_fields, entry.persons)
Expand All @@ -127,6 +127,9 @@ def run(self):
if 'fulltext' in entry.fields: # the link to the full text, usually a link to the pdf file
extra_links += '[<a href="{}">full text</a>] '.format(entry.fields['fulltext'])

if 'presentation' in entry.fields: # the link to the presentation
extra_links += '[<a href="{}">presentation</a>] '.format(entry.fields['presentation'])

if extra_links or detail_page_dir:
html += '<br>'
html += extra_links
Expand Down

0 comments on commit 318f5b4

Please sign in to comment.