Skip to content
Extraits de code Groupes Projets
Valider 635cca81 rédigé par Gregor Aisch's avatar Gregor Aisch
Parcourir les fichiers

hiding visitor map if there's no data

parent 615fd471
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
deploy.sh
\ No newline at end of file
...@@ -82,6 +82,7 @@ class Piwik_UserCountryMap_Controller extends Piwik_Controller ...@@ -82,6 +82,7 @@ class Piwik_UserCountryMap_Controller extends Piwik_Controller
$config['svgBasePath'] = 'plugins/UserCountryMap/svg/'; $config['svgBasePath'] = 'plugins/UserCountryMap/svg/';
$config['mapCssPath'] = 'plugins/UserCountryMap/css/map.css'; $config['mapCssPath'] = 'plugins/UserCountryMap/css/map.css';
$view->config = json_encode($config); $view->config = json_encode($config);
$view->noData = $config['visitsSummary']['nb_visits'] === 0;
echo $view->render(); echo $view->render();
} }
......
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
} }
.mapWidgetStatus { .mapWidgetStatus {
height: 100px; padding-bottom: 24px;
} }
.widgetUserCountryMapvisitorMap .widgetTop .button { .widgetUserCountryMapvisitorMap .widgetTop .button {
......
...@@ -18,12 +18,13 @@ ...@@ -18,12 +18,13 @@
<div class="UserCountryMap-info-btn" data-tooltip-target=".UserCountryMap-tooltip"></div> <div class="UserCountryMap-info-btn" data-tooltip-target=".UserCountryMap-tooltip"></div>
</div> </div>
<div class="mapWidgetStatus"> <div class="mapWidgetStatus">
{if $noData }
<div class="pk-emptyDataTable">{'CoreHome_ThereIsNoDataForThisReport'|translate}</div>
{else}
<span class="loadingPiwik"> <span class="loadingPiwik">
<img src="{$piwikUrl}themes/default/images/loading-blue.gif"> {'General_LoadingData'|translate}... <img src="{$piwikUrl}themes/default/images/loading-blue.gif"> {'General_LoadingData'|translate}...
</span> </span>
<span class="noDataForReport" style="display:none"> {/if}
{'CoreHome_ThereIsNoDataForThisReport'|translate}...
</span>
</div> </div>
<div class="dataTableFeatures" style="padding-top:0px;"> <div class="dataTableFeatures" style="padding-top:0px;">
<div class="dataTableFooterIcons"> <div class="dataTableFooterIcons">
...@@ -64,6 +65,8 @@ ...@@ -64,6 +65,8 @@
</div> </div>
</div> </div>
{if !$noData }
<!-- configure some piwik vars --> <!-- configure some piwik vars -->
<script type="text/javascript"> <script type="text/javascript">
...@@ -96,4 +99,4 @@ ...@@ -96,4 +99,4 @@
{/literal} {/literal}
</script> </script>
{/if}
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter