dynamic rendering patch
pages being rendered dynamically were not displaying properly due to hitting a case that was not being captured. patched
This commit is contained in:
parent
44b8e9b5ad
commit
3ae9dbea00
2 changed files with 11 additions and 4 deletions
app/Http/Controllers
|
@ -42,21 +42,25 @@ class FrontController extends Controller
|
|||
if (is_numeric($first)) {
|
||||
if ($first == 00 || !isset($first)) {
|
||||
$page = $pages->where('id', 1)->first();
|
||||
$pageData = $this->sort->page($page);
|
||||
$pageData = $this->sort->page($page, false);
|
||||
$template = $currentTheme . '.index';
|
||||
} else {
|
||||
$page = $this->pages->getBySlug($third);
|
||||
$pageData = $this->sort->page($page);
|
||||
$pageData = $this->sort->page($page, false);
|
||||
$template = $currentTheme . '.' . $page['layout'];
|
||||
}
|
||||
} else {
|
||||
if ($first == null || $first == '') {
|
||||
$page = $pages->where('id', 1)->first();
|
||||
$pageData = $this->sort->page($page);
|
||||
$page = $pages->where('id', 0)->first();
|
||||
$pageData = $this->sort->page($page, false);
|
||||
$template = $currentTheme . '.index';
|
||||
} else {
|
||||
$page = $this->pages->getBySlug($first);
|
||||
$pageData = $this->sort->page($page, false);
|
||||
$template = $currentTheme . '.' . $page['layout'];
|
||||
}
|
||||
}
|
||||
|
||||
return view($template, $pageData);
|
||||
} else {
|
||||
if (is_file('../public/index.html')) {
|
||||
|
|
|
@ -59,6 +59,9 @@ class RouteGetController extends Controller
|
|||
case 'backup':
|
||||
return $this->downloadBackup($second);
|
||||
break;
|
||||
default:
|
||||
return $this->front->index($first, $second, $third);
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
return $this->front->index($first, $second, $third);
|
||||
|
|
Loading…
Add table
Reference in a new issue