-
Notifications
You must be signed in to change notification settings - Fork 12
/
entry.rhtml
101 lines (71 loc) · 3.09 KB
/
entry.rhtml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<% url = ''; url = entry['myurl'] ? entry['myurl'] : entry['url'] %>
<% title = entry.title.to_s(:filter => :latex) %>
<% warn ("No URL for publication "+entry.key.to_s) unless url %>
<% if !defined? no_js then no_js = false end %>
<p>
<% if entry.type == :string %>
<%# fail silently %>
<% elsif entry.type == :inproceedings %>
<%# @inproceedings %>
<a href="<%=url%>"><b><%= title %></b></a>. <%= entry.author.pretty %>.
In <i><%= entry['booktitle'] %></i>. <%= entry['year'] %>.
<% elsif entry.type == :article %>
<%# journal article %>
<a href="<%=url%>"><b><%= title %></b></a>. <%= entry.author.pretty %>.
<i><%= entry['journal'] %></i><%if entry['volume']%> <%= entry['volume']%><%if entry['number']%> (<%= entry['number']%>)<%end%><%end%>.
<%if entry['note']%><%= entry['note']%>.<%end%>
<%= entry['year'] %>.
<% elsif entry.type == :incollection %>
<%# @incollection %>
<a href="<%=url%>"><b><%= title %></b></a>. <%= entry.author.pretty %>.
In <%= entry['editor'] %>, editors. <i><%= entry['booktitle'] %></i>. <%= entry['publisher'] %>. <%= entry['year'] %>.
<% elsif entry.type == :mastersthesis %>
<%# thesis %>
<b><%= title %></b>. <%= entry.author.pretty %>.
Synthesis project (Required for Ph.D. candidacy), <%= entry['school']%>, <%= entry['year'] %>.
<% elsif entry.type == :phdthesis %>
<%# thesis %>
<a href="<%=url%>"><b><%= title %></b></a>. <%= entry.author.pretty %>.
Ph.D. Dissertation, <%= entry['school']%>, <%= entry['year'] %>.
<% elsif entry.type == :techreport %>
<%# TR %>
<a href="<%=url%>"><b><%= title %></b></a>. <%= entry.author.pretty %>.
<%= entry['institution'] %> Technical Report, <%= entry['number']%>, <%= entry['year'] %>.
<% elsif entry.type == :unpublished %>
<%# Probably an arxiv preprint %>
<a href="<%=url%>"><b><%= title %></b></a>. <%= entry.author.pretty %>.
<%= entry['year'] %>.
<% if entry['eprint'] %><%= entry['archiveprefix'] %> <%= entry['primaryclass'] %>/<%= entry['eprint'] %><% end %>
<% else %>
ERROR! Can't display <%= entry.type %> <%= entry.key %>
<% end %>
<% if entry['annote'] %>
<span class="annote">(<%= entry['annote'] %>)</span>
<% end %>
</p>
<% if entry['webnote'] %>
<p class="note">(<%= entry['webnote'] %>)</p>
<% end %>
<p>
[
<% if url %>
<a href="<%=url%>">.pdf</a>
<% else %>
to appear
<% end %>
<% if !no_js %>
| <a href="javascript:toggle('bib<%=entry.key %>', 'bib_link_<%=entry.key %>', 'bib')" id="bib_link_<%=entry.key %>">bib</a>
<% if entry['abstract'] %>
| <a href="javascript:toggle('abs<%=entry.key %>', 'abs_link_<%=entry.key %>', 'abstract')" id="abs_link_<%= entry.key %>">abstract</a>
<% end %>
<% end %>
<% if entry['eprint'] %>
| <a href="<%=entry['url'] %>"><%=entry['archiveprefix'] %></a>
<% end %>
]
<% if !no_js %>
<div id="div<%=entry.key %>"></div>
<div style="display:none;" id="abs<%= entry.key%>"><div class="abstract"><%= entry['abstract']%></div></div>
<div style="display:none;" id="bib<%= entry.key%>"><pre class="bibtex"><%=entry.minimize.to_s%></pre></div>
<% end %>
</p>