[304] Restyled sidebar
[ckanext-ga-report.git] / ckanext / ga_report / templates / ga_report / ga_util.html
blob:a/ckanext/ga_report/templates/ga_report/ga_util.html -> blob:b/ckanext/ga_report/templates/ga_report/ga_util.html
--- a/ckanext/ga_report/templates/ga_report/ga_util.html
+++ b/ckanext/ga_report/templates/ga_report/ga_util.html
@@ -8,8 +8,8 @@
 
 <select name="month" py:def="month_selector(current_month, months, day)">
     <option value='' py:attrs="{'selected': 'selected' if not current_month else None}">All months</option>
-  <py:for each="i, (val,desc) in enumerate(months)">
-    <option value='${val}' py:attrs="{'selected': 'selected' if current_month == val else None}">${desc}<py:if test="i == 0 and day"> (up to ${day})</py:if></option>
+  <py:for each="(iso_code,string_name) in months">
+    <option value='${iso_code}' py:attrs="{'selected': 'selected' if current_month == iso_code else None}">${h.month_option_title(iso_code,months,day)}</option>
   </py:for>
 </select>
 
@@ -37,7 +37,6 @@
     <script type="text/javascript">
       $(function() {
           var items = $items_json;
-          if (items.length==0) { return; }
           CKAN.GA_Reports.render_rickshaw('$id', items, '$mode', '$colorscheme');
       });
     </script>
@@ -63,10 +62,13 @@
   <span class="subheading">
     <img src="/images/arrow-down-right.png" />
     <a class="${if_(active_name=='Site-wide','active')}" href="${h.url_for(controller='ckanext.ga_report.controller:GaReport',action='index')}${if_(c.month,'?month='+c.month)}">Site-wide</a>
+    <!--!
+    Temporarily disabled for production whilst we get to the bottom of #854
     <span class="divider">|</span>
     <a class="${if_(active_name=='Publishers','active')}" href="${h.url_for(controller='ckanext.ga_report.controller:GaDatasetReport',action='publishers')}${if_(c.month,'?month='+c.month)}">Publishers</a>
     <span class="divider">|</span>
     <a class="${if_(active_name=='Datasets','active')}" href="${h.url_for(controller='ckanext.ga_report.controller:GaDatasetReport',action='read')}${if_(c.month,'?month='+c.month)}">Datasets</a>
+    -->
   </span>
 </div>
 
@@ -81,7 +83,7 @@
     <div class="widget-container widget_text">
       <h4>Graph Legend</h4>
       <div id="graph-legend-container">
-        <div id="legend_none">(No graph loaded)</div>
+        <div style="display: none;" id="legend_none">(No graph is loaded)</div>
       </div>
     </div>
     <div class="widget-container widget_text">