jsonDb supprimer le template
This commit is contained in:
parent
318a2d7e1c
commit
0c08e387b7
@ -318,12 +318,9 @@ class common {
|
|||||||
//Retourne une chaine contenant le dossier à créer
|
//Retourne une chaine contenant le dossier à créer
|
||||||
$folder = $this->dirData ($keys[0],'fr');
|
$folder = $this->dirData ($keys[0],'fr');
|
||||||
// Constructeur JsonDB
|
// Constructeur JsonDB
|
||||||
//require_once "core/vendor/jsondb/Dot.php";
|
|
||||||
//require_once "core/vendor/jsondb/JsonDb.php";
|
|
||||||
$db = new \Prowebcraft\JsonDb([
|
$db = new \Prowebcraft\JsonDb([
|
||||||
'name' => $keys[0] . '.json',
|
'name' => $keys[0] . '.json',
|
||||||
'dir' => $folder,
|
'dir' => $folder
|
||||||
'template' => self::TEMP_DIR . 'data.template.json'
|
|
||||||
]);
|
]);
|
||||||
switch(count($keys)) {
|
switch(count($keys)) {
|
||||||
case 1:
|
case 1:
|
||||||
@ -387,8 +384,7 @@ class common {
|
|||||||
// Constructeur JsonDB
|
// Constructeur JsonDB
|
||||||
$db = new \Prowebcraft\JsonDb([
|
$db = new \Prowebcraft\JsonDb([
|
||||||
'name' => $keys[0] . '.json',
|
'name' => $keys[0] . '.json',
|
||||||
'dir' => $folder,
|
'dir' => $folder
|
||||||
'template' => self::TEMP_DIR . 'data.template.json'
|
|
||||||
]);
|
]);
|
||||||
switch(count($keys)) {
|
switch(count($keys)) {
|
||||||
case 1:
|
case 1:
|
||||||
@ -956,8 +952,7 @@ class common {
|
|||||||
// Constructeur JsonDB
|
// Constructeur JsonDB
|
||||||
$db = new \Prowebcraft\JsonDb([
|
$db = new \Prowebcraft\JsonDb([
|
||||||
'name' => $keys[0] . '.json',
|
'name' => $keys[0] . '.json',
|
||||||
'dir' => $folder,
|
'dir' => $folder
|
||||||
'template' => self::TEMP_DIR . 'data.template.json'
|
|
||||||
]);
|
]);
|
||||||
|
|
||||||
switch(count($keys)) {
|
switch(count($keys)) {
|
||||||
@ -1008,8 +1003,7 @@ class common {
|
|||||||
// Constructeur JsonDB
|
// Constructeur JsonDB
|
||||||
$db = new \Prowebcraft\JsonDb([
|
$db = new \Prowebcraft\JsonDb([
|
||||||
'name' => $module . '.json',
|
'name' => $module . '.json',
|
||||||
'dir' => $folder,
|
'dir' => $folder
|
||||||
'template' => self::TEMP_DIR . 'data.template.json'
|
|
||||||
]);
|
]);
|
||||||
if ($sampleSite === true) {
|
if ($sampleSite === true) {
|
||||||
$db->set($module,init::$siteData[$module]);
|
$db->set($module,init::$siteData[$module]);
|
||||||
@ -1753,11 +1747,11 @@ class core extends common {
|
|||||||
foreach($this->getData(['user']) as $userId => $userIds){
|
foreach($this->getData(['user']) as $userId => $userIds){
|
||||||
$t = explode('/',$this->getData(['user', $userId, 'accessUrl']));
|
$t = explode('/',$this->getData(['user', $userId, 'accessUrl']));
|
||||||
if ( $this->getuser('id') &&
|
if ( $this->getuser('id') &&
|
||||||
$userId !== $this->getuser('id') &&
|
$userId !== $this->getuser('id') &&
|
||||||
$this->getData(['user', $userId,'accessUrl']) === $this->getUrl() &&
|
$this->getData(['user', $userId,'accessUrl']) === $this->getUrl() &&
|
||||||
array_intersect($t,self::$accessList) &&
|
array_intersect($t,self::$accessList) &&
|
||||||
array_intersect($t,self::$accessExclude) !== false &&
|
array_intersect($t,self::$accessExclude) !== false &&
|
||||||
time() < $this->getData(['user', $userId,'accessTimer']) + self::ACCESS_TIMER
|
time() < $this->getData(['user', $userId,'accessTimer']) + self::ACCESS_TIMER
|
||||||
) {
|
) {
|
||||||
$access = false;
|
$access = false;
|
||||||
$accessInfo['userName'] = $this->getData(['user', $userId, 'lastname']) . ' ' . $this->getData(['user', $userId, 'firstname']);
|
$accessInfo['userName'] = $this->getData(['user', $userId, 'lastname']) . ' ' . $this->getData(['user', $userId, 'firstname']);
|
||||||
|
Loading…
Reference in New Issue
Block a user