Compare commits
2 Commits
ff2c51d505
...
74f6779c63
Author | SHA1 | Date | |
---|---|---|---|
74f6779c63 | |||
181a65a99b |
@ -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{
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
@ -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);
|
||||
|
@ -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');
|
||||
|
@ -12,6 +12,7 @@ class Login extends Template
|
||||
|
||||
$template = new Template('login');
|
||||
$template->prepare('baseDir', BASEDIR);
|
||||
$template->prepare('baseUrl', BASEURL);
|
||||
$template->prepare('title', 'Home');
|
||||
|
||||
|
||||
|
@ -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'])) {
|
||||
|
@ -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);
|
||||
|
@ -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);
|
||||
|
||||
|
@ -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);
|
||||
|
@ -4,6 +4,8 @@
|
||||
<?php
|
||||
$partial = new Partial('head');
|
||||
$partial->prepare('baseDir',$BASEDIR);
|
||||
$partial->prepare('baseUrl',$BASEURL);
|
||||
|
||||
$partial->render();
|
||||
?>
|
||||
<title><?php echo $TITLE ?></title>
|
||||
|
@ -4,6 +4,7 @@
|
||||
<?php
|
||||
$partial = new Partial('head');
|
||||
$partial->prepare('baseDir', $BASEDIR);
|
||||
$partial->prepare('baseUrl', $BASEURL);
|
||||
$partial->render();
|
||||
?>
|
||||
<title><?php echo $TITLE ?></title>
|
||||
|
Loading…
Reference in New Issue
Block a user