1+ {% load static %}
2+ {% load tags %}
3+
14<!DOCTYPE html>
25< html >
36 < style >
3639 padding-left : 20px ;
3740 text-decoration : none;
3841 }
42+ .figure {
43+ display : block;
44+ margin : 0 ;
45+ padding : 0 ;
46+ text-align : center;
47+ }
3948 .caption {
4049 font-size : 13px ;
41- padding-left : 6px ;
50+ display : block;
51+ text-align : center;
52+ }
53+ .image {
54+ max-width : 100% ;
55+ height : 300px ;
56+ width : auto;
57+ margin : 0 auto;
4258 }
4359 # situational_overview {
4460 font-size : 15px ;
@@ -54,53 +70,66 @@ <h1 class="title-heading-main">{{title}}</h1>
5470 < h2 class ="heading "> Situational Overview</ h2 >
5571 < div id ="situational_overview "> < p > {{situational_overview|safe}}</ p > </ div >
5672
57- < h2 class ="heading "> Graphics and Maps</ h2 >
58-
5973 {% if not map_list|length == 0 %}
60- < table >
61- < tr >
74+ < h2 class ="heading "> Graphics and Maps</ h2 >
6275 {% for map in map_list %}
63- < td > < img style ='width:100%; height:100%; ' src ="{{map.image}} " alt ="image "> < br > < p class ='caption '> {{map.caption}}</ p > </ td >
76+ < figure class ='figure '>
77+ < img class ='image ' src ="{{ map.image | media_full_path }} " alt ="image " />
78+ {% if map.caption %}
79+ < figcaption class ='caption '> {{map.caption}}</ figcaption >
80+ {% endif %}
81+ </ figure >
6482 {% endfor %}
65- </ tr >
66- </ table >
6783 {% endif %}
6884
69- {% if not graphic_list|length == 0 %}
70- < table >
71- < tr >
85+ {% if graphic_list|length > 0 %}
7286 {% for graphic in graphic_list %}
73- < td > < img style ='width:100%; height:100%; ' src ="{{graphic.image}} " alt ="image "> < br > < p class ='caption '> {{graphic.caption}}</ p > </ td >
87+ < figure class ="figure ">
88+ < img class ='image ' src ="{{ graphic.image | media_full_path}} " alt ="image " />
89+ {% if graphic.caption %}
90+ < figcaption class ='caption '> {{graphic.caption}}</ figcaption >
91+ {% endif %}
92+ </ figure >
7493 {% endfor %}
75- </ tr >
76- </ table >
7794 {% endif %}
7895
79- < h2 class ="heading "> Actions Taken</ h2 >
96+ {% if not actions_taken|length == 0 %}
97+ < h2 class ="heading "> Actions Taken</ h2 >
98+ {% for act_taken in actions_taken %}
99+ {% if not act_taken.action_details|length == 0 or act_taken.summary %}
100+ < p class ="sub-heading "> Actions Taken by {{act_taken.organization_display}}</ p >
80101
81- {% for act_taken in actions_taken %}
82- < p class ="sub-heading "> Actions Taken by {{act_taken.organization_display}}</ p >
102+ {% if act_taken.summary %}
103+ < p class ="sub-heading "> Descriptions</ p >
104+ < span class ='desc '> {{act_taken.summary|linebreaks}}</ span >
105+ {% endif %}
83106
84- < p class =" sub-heading " > Descriptions </ p >
85- < span class =' desc ' > {{act_taken.summary|linebreaks}} </ span >
86-
87- < p class ="sub-heading " > Actions </ p >
88- {% for action in act_taken.action_details %}
89- < p class =" actions " > {{action.name}} </ p >
90- {%endfor %}
107+ {% if not act_taken.action_details|length == 0 %}
108+ < p class =" sub-heading " > Actions </ p >
109+ {% for action in act_taken.action_details %}
110+ < p class ="actions " > {{action.name}} </ p >
111+ {%endfor %}
112+ {% endif %}
113+ {% endif %}
91114 {% endfor %}
92115
116+ {% endif %}
117+
118+ {% if not resources|length == 0 %}
93119 < h2 class ="heading "> Resources</ h2 >
94120 {% for resource in resources %}
95121 < p class ="desc "> {{resource.date}} < br >
96- {{resource.source_description}} < br >
122+ {% if resource.source_description %}
123+ {{resource.source_description}} < br >
124+ {% endif %}
97125 {% if resource.url %}
98126 < a class ="actions "> {{resource.url}}</ a > < br >
99127 {% endif %}
100128 {% if resource.flash_file %}
101129 < a class ="actions " href ={{resource.flash_file}} > Download document</ a >
102130 {% endif %}
103131 </ p >
104- {%endfor%}
132+ {% endfor %}
133+ {% endif %}
105134 </ body >
106135</ html >
0 commit comments