diff --git a/core/class/jsondb/JsonDb.class.php b/core/class/jsondb/JsonDb.class.php index 978a813a..808b766a 100644 --- a/core/class/jsondb/JsonDb.class.php +++ b/core/class/jsondb/JsonDb.class.php @@ -31,6 +31,16 @@ class JsonDb extends \Prowebcraft\Dot parent::__construct(); } + /** + * Reload data from file + * @return $this + */ + public function reload() + { + $this->loadData(true); + return $this; + } + /** * Set value or array of values to path * diff --git a/core/module/page/page.php b/core/module/page/page.php index 7eff20eb..b8adc753 100644 --- a/core/module/page/page.php +++ b/core/module/page/page.php @@ -501,6 +501,10 @@ class page extends common { // Met à jour le site map $this->createSitemap('all'); + + // Mise à jour de la liste des pages pour TinyMCE + $this->pages2Json(); + // Redirection vers la configuration if( $this->getInput('pageEditModuleRedirect', helper::FILTER_BOOLEAN) @@ -534,8 +538,6 @@ class page extends common { self::$pagesBarId[$parentPageId] = $this->getData(['page', $parentPageId, 'title']); } } - // Mise à jour de la liste des pages pour TinyMCE - $this->pages2Json(); // Valeurs en sortie $this->addOutput([ 'title' => $this->getData(['page', $this->getUrl(2), 'title']),