mirror of
https://github.com/typemill/typemill.git
synced 2025-08-01 20:00:37 +02:00
Version 1.4.7: Fixed errors for paging after cache is deleted
This commit is contained in:
1
cache/index.json
vendored
1
cache/index.json
vendored
File diff suppressed because one or more lines are too long
@@ -6,14 +6,13 @@ meta:
|
||||
owner: null
|
||||
author: 'Sebastian Schürmanns'
|
||||
manualdate: null
|
||||
modified: '2020-11-19'
|
||||
modified: '2021-06-13'
|
||||
created: null
|
||||
time: null
|
||||
navtitle: ''
|
||||
hide: false
|
||||
mycustom:
|
||||
product: car
|
||||
price: '123,20'
|
||||
hide: true
|
||||
allowedrole: null
|
||||
alloweduser: null
|
||||
seo:
|
||||
heroimage: media/live/bildschirmfoto-zu-2019-08-30-20-46-29.png
|
||||
heroimagealt: Alt-Text
|
||||
|
@@ -377,7 +377,7 @@ class PageController extends Controller
|
||||
$extended = $yaml->getYaml('cache', 'structure-extended.yaml');
|
||||
|
||||
# create an array of object with the whole content of the folder
|
||||
# $structure = Folder::getFolderContentDetails($pagetree, $extended, $uri->getBaseUrl(), $uri->getBasePath());
|
||||
$structure = Folder::getFolderContentDetails($pagetree, $extended, $uri->getBaseUrl(), $uri->getBasePath());
|
||||
|
||||
# now update the extended structure
|
||||
if(!$extended)
|
||||
@@ -389,16 +389,13 @@ class PageController extends Controller
|
||||
$yaml->updateYaml('cache', 'structure-extended.yaml', $extended);
|
||||
|
||||
# we have to update the structure with extended again
|
||||
# $structure = Folder::getFolderContentDetails($pagetree, $extended, $uri->getBaseUrl(), $uri->getBasePath());
|
||||
$structure = Folder::getFolderContentDetails($pagetree, $extended, $uri->getBaseUrl(), $uri->getBasePath());
|
||||
}
|
||||
else
|
||||
{
|
||||
$extended = false;
|
||||
}
|
||||
}
|
||||
|
||||
# create an array of object with the whole content of the folder
|
||||
$structure = Folder::getFolderContentDetails($pagetree, $extended, $uri->getBaseUrl(), $uri->getBasePath());
|
||||
|
||||
# cache structure
|
||||
$cache->updateCache('cache', 'structure.txt', 'lastCache.txt', $structure);
|
||||
|
@@ -337,6 +337,12 @@ class Folder
|
||||
|
||||
public static function getPagingForItem($content, $item)
|
||||
{
|
||||
# if page is home
|
||||
if(trim($item->pathWithoutType, "/") == 'index')
|
||||
{
|
||||
return $item;
|
||||
}
|
||||
|
||||
$keyPos = count($item->keyPathArray)-1;
|
||||
$thisChapArray = $item->keyPathArray;
|
||||
$nextItemArray = $item->keyPathArray;
|
||||
|
Reference in New Issue
Block a user