Skip to content

Commit

Permalink
list/history: Use intl's default locale to format time and date (#5170)
Browse files Browse the repository at this point in the history
  • Loading branch information
nilmerg authored Aug 7, 2024
2 parents b370d9b + ab3c9f3 commit ff0fc55
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion application/views/scripts/error/error.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ $modReason = [];

if (isset($requiredVendor, $requiredProject) && $requiredVendor && $requiredProject) {
// TODO: I don't like this, can we define requirements somewhere else?
$coreDeps = ['icinga-php-library' => '>= 0.13', 'icinga-php-thirdparty' => '>= 0.12'];
$coreDeps = ['icinga-php-library' => '>= 0.13.2', 'icinga-php-thirdparty' => '>= 0.12'];

foreach ($coreDeps as $libraryName => $requiredVersion) {
if (! $libraries->has($libraryName)) {
Expand Down
2 changes: 1 addition & 1 deletion doc/02-Installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ You will need to install certain dependencies depending on your setup:
monitor your infrastructure
* A web server, e.g. Apache or Nginx
* PHP version ≥ 7.2
* [Icinga PHP Library (ipl)](https://github.com/Icinga/icinga-php-library) (≥ 0.13)
* [Icinga PHP Library (ipl)](https://github.com/Icinga/icinga-php-library) (≥ 0.13.2)
* [Icinga PHP Thirdparty](https://github.com/Icinga/icinga-php-thirdparty) (≥ 0.12)
* The following PHP modules must be installed: cURL, json, gettext, fileinfo, intl, dom, OpenSSL and xml
* The [pdfexport](https://github.com/Icinga/icingaweb2-module-pdfexport) module (≥0.10) is required for the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ $history->limit($limit * $page);
?>
<div class="content">
<?php
$dateFormatter = new IntlDateFormatter(setlocale(LC_TIME, 0), IntlDateFormatter::FULL, IntlDateFormatter::NONE);
$dateFormatter = new IntlDateFormatter(Locale::getDefault(), IntlDateFormatter::FULL, IntlDateFormatter::NONE);
$lastDate = null;
$flappingMsg = $this->translate('Flapping with a %.2f%% state change rate');
$rowAction = Url::fromPath('monitoring/event/show');
Expand Down
2 changes: 1 addition & 1 deletion modules/setup/library/Setup/WebWizard.php
Original file line number Diff line number Diff line change
Expand Up @@ -602,7 +602,7 @@ public function getRequirements($skipModules = false)
)));

$set->add(new WebLibraryRequirement(array(
'condition' => ['icinga-php-library', '>=', '0.13.0'],
'condition' => ['icinga-php-library', '>=', '0.13.2'],
'alias' => 'Icinga PHP library',
'description' => mt(
'setup',
Expand Down

0 comments on commit ff0fc55

Please sign in to comment.