--- a/ckanext/ga_report/templates/ga_report/publisher/popular.html +++ b/ckanext/ga_report/templates/ga_report/publisher/popular.html @@ -2,17 +2,25 @@ xmlns:i18n="http://genshi.edgewall.org/i18n" xmlns:xi="http://www.w3.org/2001/XInclude" py:strip=""> + <py:if test="dataset_count == 0"> + <p>We do not currently have usage data for ${publisher.title}</p> + </py:if> + <py:if test="dataset_count > 0"> <div class="popular_datasets"> - <ul class="popular_dataset_list"> + <ul> <py:for each="dataset,views,visits in datasets"> <li> ${h.link_to(dataset.title, h.url_for(controller='package', action='read', id=dataset.name))} </li> </py:for> </ul> - - <p>${h.link_to("More analytics for " + publisher.title, h.url_for(controller='ckanext.ga_report.controller:GaPublisherReport',action='read',id=publisher.name))}</p> + <p> + <a href="${h.url_for(controller='ckanext.ga_report.controller:GaDatasetReport',action='read_publisher',id=publisher.name)}"> + <img py:if="preview_image" src="${preview_image}" /><br/> + More usage data for ${publisher.title} + </a> + </p> </div> </py:if> </html>