Clanky | pokud je PDF s cislem, odkazat na nej.
This commit is contained in:
		
							parent
							
								
									d06d0ff2ea
								
							
						
					
					
						commit
						98f2ad12a7
					
				
					 1 changed files with 14 additions and 9 deletions
				
			
		|  | @ -9,15 +9,20 @@ | ||||||
| </h1> | </h1> | ||||||
| 
 | 
 | ||||||
| {% for clanek in object_list %} | {% for clanek in object_list %} | ||||||
| {% with clanek.cislo.rocnik.rocnik as rocnik %} | 	{% with clanek.cislo.rocnik.rocnik as rocnik %} | ||||||
|   {% ifchanged rocnik %} | 		{% ifchanged rocnik %} | ||||||
|     {% if not forloop.first %}</ul>{% endif %} | 			{% if not forloop.first %}</ul>{% endif %} | ||||||
|     <h2>{{ rocnik }}. ročník</h2> | 			<h2>{{ rocnik }}. ročník</h2> | ||||||
|     <ul> | 			<ul> | ||||||
|   {% endifchanged %} | 		{% endifchanged %} | ||||||
|       <li> | 		<li> | ||||||
|         <a href="{{ clanek.verejne_url }}">{{ clanek.nazev }}</a> | 			{% if clanek.cislo.pdf %} | ||||||
| {% endwith %} | 				<a href="{{ clanek.cislo.pdf.url }}">{{ clanek.nazev }}</a> | ||||||
|  | 			{% else %} | ||||||
|  | 				{{ clanek.nazev }} (vyšlo v čísle {{clanek.cislo}}) | ||||||
|  | 			{% endif %} | ||||||
|  | 		</li> | ||||||
|  | 	{% endwith %} | ||||||
| {% endfor %} | {% endfor %} | ||||||
| </ul> | </ul> | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue