Compare commits

...

2 Commits

Author SHA1 Message Date
74f6779c63 Fix 2020-12-09 12:28:31 +01:00
181a65a99b Bug Fixes 2020-12-09 12:19:19 +01:00
10 changed files with 29 additions and 15 deletions

View File

@ -22,6 +22,9 @@ class SettingsManager{
}
public static function update ($name, $value) {
if ($this.getByName($name)){
$this->create($name, $value);
} else {
try {
Db::edit ('settings', ['value' => $value], 'WHERE name = ?', array($name));
} catch(PDOException $error) {
@ -30,4 +33,5 @@ class SettingsManager{
}
}
}
}
?>

View File

@ -53,6 +53,7 @@ class Automation extends Template
$template = new Template('automation');
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('debugMod', DEBUGMOD);
$template->prepare('title', 'Automation');
$template->prepare('langMng', $langMng);

View File

@ -19,6 +19,7 @@ class Log extends Template
$result = $this->logFinder ('../logs/', $result);
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('debugMod', DEBUGMOD);
$template->prepare('logToLiveTime', LOGTIMOUT);
$template->prepare('title', 'Logy');

View File

@ -12,6 +12,7 @@ class Login extends Template
$template = new Template('login');
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('title', 'Home');

View File

@ -8,6 +8,7 @@ class Oauth extends Template
$template = new Template('oauth');
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('title', 'Simple Home - Oauth');
if (isset($_GET['redirect_uri'])) {

View File

@ -25,6 +25,7 @@ class Plugins extends Template
$template = new Template('plugins');
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('debugMod', DEBUGMOD);
$template->prepare('title', 'Plugins');
$template->prepare('langMng', $langMng);

View File

@ -36,6 +36,7 @@ class Server extends Template
$template->prepare('title', 'Server');
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('debugMod', DEBUGMOD);
$template->prepare('langMng', $langMng);

View File

@ -23,6 +23,7 @@ class Setting extends Template
$template = new Template('setting');
$template->prepare('baseDir', BASEDIR);
$template->prepare('baseUrl', BASEURL);
$template->prepare('debugMod', DEBUGMOD);
$template->prepare('title', 'Automation');
$template->prepare('langMng', $langMng);

View File

@ -4,6 +4,8 @@
<?php
$partial = new Partial('head');
$partial->prepare('baseDir',$BASEDIR);
$partial->prepare('baseUrl',$BASEURL);
$partial->render();
?>
<title><?php echo $TITLE ?></title>

View File

@ -4,6 +4,7 @@
<?php
$partial = new Partial('head');
$partial->prepare('baseDir', $BASEDIR);
$partial->prepare('baseUrl', $BASEURL);
$partial->render();
?>
<title><?php echo $TITLE ?></title>