jsonDb supprimer le template

This commit is contained in:
Fred Tempez 2020-09-18 03:57:02 +02:00
parent 318a2d7e1c
commit 0c08e387b7

View File

@ -318,12 +318,9 @@ class common {
//Retourne une chaine contenant le dossier à créer
$folder = $this->dirData ($keys[0],'fr');
// Constructeur JsonDB
//require_once "core/vendor/jsondb/Dot.php";
//require_once "core/vendor/jsondb/JsonDb.php";
$db = new \Prowebcraft\JsonDb([
'name' => $keys[0] . '.json',
'dir' => $folder,
'template' => self::TEMP_DIR . 'data.template.json'
'dir' => $folder
]);
switch(count($keys)) {
case 1:
@ -387,8 +384,7 @@ class common {
// Constructeur JsonDB
$db = new \Prowebcraft\JsonDb([
'name' => $keys[0] . '.json',
'dir' => $folder,
'template' => self::TEMP_DIR . 'data.template.json'
'dir' => $folder
]);
switch(count($keys)) {
case 1:
@ -956,8 +952,7 @@ class common {
// Constructeur JsonDB
$db = new \Prowebcraft\JsonDb([
'name' => $keys[0] . '.json',
'dir' => $folder,
'template' => self::TEMP_DIR . 'data.template.json'
'dir' => $folder
]);
switch(count($keys)) {
@ -1008,8 +1003,7 @@ class common {
// Constructeur JsonDB
$db = new \Prowebcraft\JsonDb([
'name' => $module . '.json',
'dir' => $folder,
'template' => self::TEMP_DIR . 'data.template.json'
'dir' => $folder
]);
if ($sampleSite === true) {
$db->set($module,init::$siteData[$module]);