summaryrefslogtreecommitdiff
path: root/modules/gallery/views
diff options
context:
space:
mode:
authorNathan Kinkade <nkinkade@nkinka.de>2011-01-31 20:49:25 +0000
committerNathan Kinkade <nkinkade@nkinka.de>2011-01-31 20:49:25 +0000
commitde6f3fce9110b777d61dec97f2a3a61d887a5ccd (patch)
tree1a184dc0d6bbfd644164d85d3df1bc9926455da7 /modules/gallery/views
parent2898fe3b82ce10d045dd2c274a3290bacf209a00 (diff)
parentd2c77fd0590501f7b6b51d9f4cc033ed9485b082 (diff)
Did a git pull, but had to manually merge a conflict.
Diffstat (limited to 'modules/gallery/views')
-rw-r--r--modules/gallery/views/admin_block_stats.html.php2
-rw-r--r--modules/gallery/views/upgrade_checker_block.html.php53
2 files changed, 54 insertions, 1 deletions
diff --git a/modules/gallery/views/admin_block_stats.html.php b/modules/gallery/views/admin_block_stats.html.php
index 1dec8ccd..c8c54765 100644
--- a/modules/gallery/views/admin_block_stats.html.php
+++ b/modules/gallery/views/admin_block_stats.html.php
@@ -1,7 +1,7 @@
<?php defined("SYSPATH") or die("No direct script access.") ?>
<ul>
<li>
- <?= t("Version: %version", array("version" => gallery::VERSION)) ?>
+ <?= t("Version: %version", array("version" => gallery::version_string())) ?>
</li>
<li>
<?= t("Albums: %count", array("count" => $album_count)) ?>
diff --git a/modules/gallery/views/upgrade_checker_block.html.php b/modules/gallery/views/upgrade_checker_block.html.php
new file mode 100644
index 00000000..b04887b2
--- /dev/null
+++ b/modules/gallery/views/upgrade_checker_block.html.php
@@ -0,0 +1,53 @@
+<?php defined("SYSPATH") or die("No direct script access.") ?>
+<p>
+ <?= t("Gallery can check to see if there is a new version available for you to use. It is a good idea to upgrade your Gallery to get the latest features and security fixes. Your privacy is important so no information about your Gallery is shared during this process. You can disable this feature below.") ?>
+</p>
+
+<p>
+ <? if (gallery::RELEASE_CHANNEL == "release"): ?>
+ <?= t("You are using the official Gallery %version release, code named <i>%code_name</i>.", array("version" => gallery::VERSION, "code_name" => gallery::CODE_NAME)) ?>
+ <? else: ?>
+ <?= t("You are using an experimental snapshot of Gallery %version (build %build_number on branch %branch).", array("version" => gallery::VERSION, "branch" => gallery::RELEASE_BRANCH, "build_number" => gallery::build_number())) ?>
+ <? endif ?>
+</p>
+
+<? if ($new_version): ?>
+<ul class="g-message-block">
+ <li class="g-message g-info">
+ <?= $new_version ?>
+ </li>
+</ul>
+<? endif ?>
+
+<p>
+ <a class="g-button ui-state-default ui-corner-all"
+ href="<?= url::site("admin/upgrade_checker/check_now?csrf=$csrf") ?>">
+ <?= t("Check now") ?>
+ </a>
+ <? if ($auto_check_enabled): ?>
+ <a class="g-button ui-state-default ui-corner-all"
+ href="<?= url::site("admin/upgrade_checker/set_auto/0?csrf=$csrf") ?>">
+ <?= t("Disable automatic checking") ?>
+ </a>
+ <? else: ?>
+ <a class="g-button ui-state-default ui-corner-all"
+ href="<?= url::site("admin/upgrade_checker/set_auto/1?csrf=$csrf") ?>">
+ <?= t("Enable automatic checking") ?>
+ </a>
+ <? endif ?>
+</p>
+
+<p class="g-text-small">
+ <? if ($auto_check_enabled): ?>
+ <?= t("Automatic upgrade checking is enabled.") ?>
+ <? else: ?>
+ <?= t("Automatic upgrade checking is disabled.") ?>
+ <? endif ?>
+ <? if (!$version_info): ?>
+ <?= t("No upgrade checks have been made yet.") ?>
+ <? else: ?>
+ <?= t("The last upgrade check was made on %date.",
+ array("date" => gallery::date_time($version_info->timestamp))) ?>
+ <? endif ?>
+</p>
+