show/activitilog: make "disabled" property visible

This commit is contained in:
Thomas Gelf 2016-02-23 00:27:53 +01:00
parent 23090c502a
commit 7665cb2424
1 changed files with 10 additions and 2 deletions

View File

@ -55,9 +55,17 @@ class ShowController extends ActionController
{
$this->view->title = sprintf('%s config diff', $entry->object_name);
$this->getTabs()->activate('diff');
$old = $this->oldObject($entry);
$new = $this->newObject($entry);
if ($old->disabled === 'y' && $new->disabled === 'n') {
$old = null;
} elseif ($old->disabled === 'n' && $new->disabled === 'y') {
$new = null;
}
$d = ConfigDiff::create(
$this->oldObject($entry),
$this->newObject($entry)
$old,
$new
);
$this->view->output = $d->renderHtml();