summaryrefslogtreecommitdiff
path: root/resources/views/modules/statistics-chart
diff options
context:
space:
mode:
authorRico Sonntag <mail@ricosonntag.de>2019-02-06 14:04:42 +0100
committerGreg Roach <fisharebest@webtrees.net>2019-02-12 09:05:08 +0000
commit88de55fda5bcccfc1527a19eaa4a245e17861255 (patch)
treebe38be9cd678436332dc2b2560ae31ca3922d51a /resources/views/modules/statistics-chart
parent3596348a22b198a8682758420bc71ce601bb1058 (diff)
downloadwebtrees-88de55fda5bcccfc1527a19eaa4a245e17861255.tar.gz
webtrees-88de55fda5bcccfc1527a19eaa4a245e17861255.tar.bz2
webtrees-88de55fda5bcccfc1527a19eaa4a245e17861255.zip
Update google charts
Diffstat (limited to 'resources/views/modules/statistics-chart')
-rw-r--r--resources/views/modules/statistics-chart/custom.phtml14
-rw-r--r--resources/views/modules/statistics-chart/individuals.phtml2
-rw-r--r--resources/views/modules/statistics-chart/other.phtml2
-rw-r--r--resources/views/modules/statistics-chart/page.phtml12
4 files changed, 18 insertions, 12 deletions
diff --git a/resources/views/modules/statistics-chart/custom.phtml b/resources/views/modules/statistics-chart/custom.phtml
index 7fb3fe9369..df8bc61762 100644
--- a/resources/views/modules/statistics-chart/custom.phtml
+++ b/resources/views/modules/statistics-chart/custom.phtml
@@ -246,22 +246,22 @@
<option value="world" selected>
<?= I18N::translate('World') ?>
</option>
- <option value="europe">
+ <option value="150">
<?= I18N::translate('Europe') ?>
</option>
- <option value="usa">
- <?= I18N::translate('United States') ?>
+ <option value="021">
+ <?= I18N::translate('Northern America') ?>
</option>
- <option value="south_america">
+ <option value="005">
<?= I18N::translate('South America') ?>
</option>
- <option value="asia">
+ <option value="142">
<?= I18N::translate('Asia') ?>
</option>
- <option value="middle_east">
+ <option value="145">
<?= I18N::translate('Middle East') ?>
</option>
- <option value="africa">
+ <option value="002">
<?= I18N::translate('Africa') ?>
</option>
</select>
diff --git a/resources/views/modules/statistics-chart/individuals.phtml b/resources/views/modules/statistics-chart/individuals.phtml
index 71b550881c..0585809dfb 100644
--- a/resources/views/modules/statistics-chart/individuals.phtml
+++ b/resources/views/modules/statistics-chart/individuals.phtml
@@ -1,5 +1,3 @@
-<?php use Fisharebest\Webtrees\I18N; ?>
-
<?php
/** @var \Fisharebest\Webtrees\Statistics $stats */
?>
diff --git a/resources/views/modules/statistics-chart/other.phtml b/resources/views/modules/statistics-chart/other.phtml
index d20f54ed63..c681580a1b 100644
--- a/resources/views/modules/statistics-chart/other.phtml
+++ b/resources/views/modules/statistics-chart/other.phtml
@@ -1,4 +1,6 @@
<?php
+declare(strict_types=1);
+
/** @var \Fisharebest\Webtrees\Statistics $stats */
?>
diff --git a/resources/views/modules/statistics-chart/page.phtml b/resources/views/modules/statistics-chart/page.phtml
index 7f8775b966..b27d3f31bb 100644
--- a/resources/views/modules/statistics-chart/page.phtml
+++ b/resources/views/modules/statistics-chart/page.phtml
@@ -1,4 +1,10 @@
-<?php use Fisharebest\Webtrees\View; ?>
+<?php
+declare(strict_types=1);
+
+use Fisharebest\Webtrees\View;
+?>
+
+<?= view('statistics/other/chart-setup') ?>
<h2 class="wt-page-title">
<?= $title ?>
@@ -33,7 +39,7 @@
// If the URL contains a fragment, then activate the corresponding tab.
// Use a prefix on the fragment, to prevent scrolling to the element.
- var target = document.location.hash.replace("tab-", "");
+ var target = window.location.hash.replace("tab-", "");
var tab = $("#statistics-tabs .nav-link[href='" + target + "']");
// If not, then activate the first tab.
if (tab.length === 0) {
@@ -43,7 +49,7 @@
// If the user selects a tab, update the URL to reflect this
$('#statistics-tabs a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
- document.location.hash = "tab-" + e.target.href.substring(e.target.href.indexOf('#') + 1);
+ window.location.hash = "tab-" + e.target.href.substring(e.target.href.indexOf('#') + 1);
});
</script>
<?php View::endpush() ?>