monitoring: Use translatePlural for the success message in the DeleteDowntimesCommandForm
This commit is contained in:
parent
8207579e13
commit
ed25488cff
|
@ -57,15 +57,18 @@ class DeleteDowntimesCommandForm extends CommandForm
|
||||||
{
|
{
|
||||||
foreach ($this->downtimes as $downtime) {
|
foreach ($this->downtimes as $downtime) {
|
||||||
$delDowntime = new DeleteDowntimeCommand();
|
$delDowntime = new DeleteDowntimeCommand();
|
||||||
$delDowntime->setDowntimeId($downtime->id);
|
$delDowntime
|
||||||
$delDowntime->setIsService(isset($downtime->service_description));
|
->setDowntimeId($downtime->id)
|
||||||
|
->setIsService(isset($downtime->service_description));
|
||||||
$this->getTransport($this->request)->send($delDowntime);
|
$this->getTransport($this->request)->send($delDowntime);
|
||||||
}
|
}
|
||||||
$redirect = $this->getElement('redirect')->getValue();
|
$redirect = $this->getElement('redirect')->getValue();
|
||||||
if (! empty($redirect)) {
|
if (! empty($redirect)) {
|
||||||
$this->setRedirectUrl($redirect);
|
$this->setRedirectUrl($redirect);
|
||||||
}
|
}
|
||||||
Notification::success($this->translate('Deleting downtime.'));
|
Notification::success(
|
||||||
|
$this->translatePlural('Deleting downtime..', 'Deleting downtimes..', count($this->downtimes))
|
||||||
|
);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue