Display downtime type as text in the downtimes list

This commit is contained in:
Eric Lippmann 2017-03-28 10:12:07 +02:00
parent bbaf10aed2
commit 49239dc7db
1 changed files with 6 additions and 2 deletions

View File

@ -39,8 +39,12 @@
); ?> ); ?>
<?php endif ?> <?php endif ?>
<span class="comment-time"> <span class="comment-time">
<?= $this->translate('by') ?> <?= $this->escape(sprintf(
<?= $this->escape($downtime->author_name) ?> $downtime->is_flexible
? $this->translate('Flexible downtime by %s')
: $this->translate('Fixed downtime by %s'),
$downtime->author_name
)) ?>
</span> </span>
<?php if (! $downtime->is_in_effect && $downtime->start >= time()): ?> <?php if (! $downtime->is_in_effect && $downtime->start >= time()): ?>
<span><?= sprintf($this->translate('expires %s'), $this->timeUntil($downtime->end)) ?></span> <span><?= sprintf($this->translate('expires %s'), $this->timeUntil($downtime->end)) ?></span>