style: Fix minor styleguide issues for PHPCS
This commit is contained in:
parent
4bffcf1ba5
commit
c3ef50978a
|
@ -5,7 +5,6 @@ namespace Icinga\Exception\Http;
|
||||||
|
|
||||||
use Icinga\Exception\IcingaException;
|
use Icinga\Exception\IcingaException;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Base class for HTTP exceptions
|
* Base class for HTTP exceptions
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
|
|
||||||
namespace Icinga\Exception\Http;
|
namespace Icinga\Exception\Http;
|
||||||
|
|
||||||
|
|
||||||
interface HttpExceptionInterface
|
interface HttpExceptionInterface
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -772,7 +772,8 @@ class Form extends Zend_Form
|
||||||
$action = $action->without(array_keys($this->getElements()));
|
$action = $action->without(array_keys($this->getElements()));
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(el): Re-evalute this necessity. JavaScript could use the container's URL if there's no action set.
|
// TODO(el): Re-evalute this necessity.
|
||||||
|
// JavaScript could use the container'sURL if there's no action set.
|
||||||
// We MUST set an action as JS gets confused otherwise, if
|
// We MUST set an action as JS gets confused otherwise, if
|
||||||
// this form is being displayed in an additional column
|
// this form is being displayed in an additional column
|
||||||
$this->setAction($action);
|
$this->setAction($action);
|
||||||
|
|
|
@ -74,14 +74,15 @@ class InlinePie extends AbstractWidget
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
private $template =<<<'EOD'
|
private $template =<<<'EOD'
|
||||||
<span sparkType="pie" class="sparkline {class}" title="{title}" role="img" aria-label="{title}" sparkSliceColors="[{colors}]" values="{data}">
|
<span sparkType="pie" class="sparkline {class}" title="{title}" role="img" aria-label="{title}"
|
||||||
</span>
|
sparkSliceColors="[{colors}]" values="{data}"></span>
|
||||||
{noscript}
|
{noscript}
|
||||||
EOD;
|
EOD;
|
||||||
|
|
||||||
private $noscript =<<<'EOD'
|
private $noscript =<<<'EOD'
|
||||||
<noscript>
|
<noscript>
|
||||||
<img width={size} height={size} class="inlinepie {class}" title="{title}" role="img" aria-label="{title}" src="{url}" data-icinga-colors="{colors}" data-icinga-values="{data}"/>
|
<img width={size} height={size} class="inlinepie {class}" title="{title}" role="img" aria-label="{title}"
|
||||||
|
src="{url}" data-icinga-colors="{colors}" data-icinga-values="{data}"/>
|
||||||
</noscript>
|
</noscript>
|
||||||
EOD;
|
EOD;
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,9 @@ EOT;
|
||||||
*/
|
*/
|
||||||
private $dropdownTpl = <<< 'EOT'
|
private $dropdownTpl = <<< 'EOT'
|
||||||
<li class="dropdown-nav-item">
|
<li class="dropdown-nav-item">
|
||||||
<a href="#" class="dropdown-toggle" title="{TITLE}" aria-label="{TITLE}"><i aria-hidden="true" class="icon-down-open"></i></a>
|
<a href="#" class="dropdown-toggle" title="{TITLE}" aria-label="{TITLE}">
|
||||||
|
<i aria-hidden="true" class="icon-down-open"></i>
|
||||||
|
</a>
|
||||||
<ul class="nav">
|
<ul class="nav">
|
||||||
{TABS}
|
{TABS}
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -127,7 +127,6 @@ class UserDomainMigration
|
||||||
rename($from, $to);
|
rename($from, $to);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function migrateNavigation()
|
protected function migrateNavigation()
|
||||||
|
|
|
@ -369,7 +369,9 @@ class TransportConfigForm extends ConfigForm
|
||||||
'order' => 0,
|
'order' => 0,
|
||||||
'ignore' => true,
|
'ignore' => true,
|
||||||
'label' => $this->translate('Force Changes'),
|
'label' => $this->translate('Force Changes'),
|
||||||
'description' => $this->translate('Check this box to enforce changes without connectivity validation')
|
'description' => $this->translate(
|
||||||
|
'Check this box to enforce changes without connectivity validation'
|
||||||
|
)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
@ -204,7 +204,10 @@ class ApiCommandTransport implements CommandTransportInterface
|
||||||
->setPayload($command->getData())
|
->setPayload($command->getData())
|
||||||
->send();
|
->send();
|
||||||
} catch (JsonDecodeException $e) {
|
} catch (JsonDecodeException $e) {
|
||||||
throw new CommandTransportException('Got invalid JSON response from the Icinga 2 API: %s', $e->getMessage());
|
throw new CommandTransportException(
|
||||||
|
'Got invalid JSON response from the Icinga 2 API: %s',
|
||||||
|
$e->getMessage()
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset($response['error'])) {
|
if (isset($response['error'])) {
|
||||||
|
@ -256,9 +259,15 @@ class ApiCommandTransport implements CommandTransportInterface
|
||||||
try {
|
try {
|
||||||
$response = $request->send();
|
$response = $request->send();
|
||||||
} catch (CurlException $e) {
|
} catch (CurlException $e) {
|
||||||
throw new CommandTransportException('Couldn\'t connect to the Icinga 2 API: %s', $e->getMessage());
|
throw new CommandTransportException(
|
||||||
|
'Couldn\'t connect to the Icinga 2 API: %s',
|
||||||
|
$e->getMessage()
|
||||||
|
);
|
||||||
} catch (JsonDecodeException $e) {
|
} catch (JsonDecodeException $e) {
|
||||||
throw new CommandTransportException('Got invalid JSON response from the Icinga 2 API: %s', $e->getMessage());
|
throw new CommandTransportException(
|
||||||
|
'Got invalid JSON response from the Icinga 2 API: %s',
|
||||||
|
$e->getMessage()
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset($response['error'])) {
|
if (isset($response['error'])) {
|
||||||
|
|
|
@ -96,7 +96,8 @@ class ConfigCommand extends Command
|
||||||
*
|
*
|
||||||
* --path=<urlpath> The URL path to Icinga Web 2 [/icingaweb2]
|
* --path=<urlpath> The URL path to Icinga Web 2 [/icingaweb2]
|
||||||
*
|
*
|
||||||
* --root|--document-root=<directory> The directory from which the webserver will serve files [/path/to/icingaweb2/public]
|
* --root|--document-root=<directory> The directory from which the webserver will serve files
|
||||||
|
* [/path/to/icingaweb2/public]
|
||||||
*
|
*
|
||||||
* --config=<directory> Path to Icinga Web 2's configuration files [/etc/icingaweb2]
|
* --config=<directory> Path to Icinga Web 2's configuration files [/etc/icingaweb2]
|
||||||
*
|
*
|
||||||
|
@ -106,9 +107,13 @@ class ConfigCommand extends Command
|
||||||
*
|
*
|
||||||
* icingacli setup config webserver apache
|
* icingacli setup config webserver apache
|
||||||
*
|
*
|
||||||
* icingacli setup config webserver apache --path=/icingaweb2 --document-root=/usr/share/icingaweb2/public --config=/etc/icingaweb2
|
* icingacli setup config webserver apache \
|
||||||
|
* --path=/icingaweb2 \
|
||||||
|
* --document-root=/usr/share/icingaweb2/public \
|
||||||
|
* --config=/etc/icingaweb2
|
||||||
*
|
*
|
||||||
* icingacli setup config webserver apache --file=/etc/apache2/conf.d/icingaweb2.conf
|
* icingacli setup config webserver apache \
|
||||||
|
* --file=/etc/apache2/conf.d/icingaweb2.conf
|
||||||
*
|
*
|
||||||
* icingacli setup config webserver nginx
|
* icingacli setup config webserver nginx
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in New Issue