Params/_render: get rid of it, start with iframe
This commit is contained in:
parent
bb23d0636c
commit
3b84078b2f
|
@ -13,7 +13,7 @@ if (array_key_exists('_dev', $_GET)) {
|
|||
|
||||
$ie8jsfile = 'js/icinga.ie8.js';
|
||||
$lang = Translator::getLanguage();
|
||||
$isIframe = isset($_GET['_render']) && $_GET['_render'] === 'iframe';
|
||||
$isIframe = isset($_GET['isIframe']);
|
||||
$iframeClass = $isIframe ? ' iframe' : '';
|
||||
|
||||
?><!DOCTYPE html>
|
||||
|
|
|
@ -396,7 +396,7 @@ class Url
|
|||
*
|
||||
* @return self
|
||||
*/
|
||||
public function setParam($param, $value)
|
||||
public function setParam($param, $value = true)
|
||||
{
|
||||
$this->params->set($param, $value);
|
||||
return $this;
|
||||
|
|
|
@ -165,9 +165,9 @@ EOD;
|
|||
{
|
||||
$view = $this->view();
|
||||
$url = clone($this->url);
|
||||
$url->addParams(array('view' => 'compact'));
|
||||
$url->setParam('view', 'compact');
|
||||
$iframeUrl = clone($url);
|
||||
$iframeUrl->addParams(array('_render' => 'iframe'));
|
||||
$iframeUrl->setParam('isIframe');
|
||||
|
||||
$html = str_replace('{URL}', $url, $this->template);
|
||||
$html = str_replace('{IFRAME_URL}', $iframeUrl, $html);
|
||||
|
|
|
@ -442,6 +442,7 @@ class Monitoring_ListController extends Controller
|
|||
$params = clone $this->params;
|
||||
|
||||
$params->shift('_render');
|
||||
$params->shift('isIframe');
|
||||
$limit = $params->shift('limit');
|
||||
$sort = $params->shift('sort');
|
||||
$dir = $params->shift('dir');
|
||||
|
|
Loading…
Reference in New Issue