mirror of
https://git.steelants.cz/SH/PHP_SMART_HOME_V3.git
synced 2026-10-11 17:54:34 +00:00
Adtional tweeks and fixes
This commit is contained in:
1 parent
94d6576070
commit
e3b7e866f0
6 files changed
+43
-28
No files matched your search
@@ -3,7 +3,7 @@ class RoomManager{
|
||||
public static $rooms;
|
||||
|
||||
static function getDefaultRoomId() {
|
||||
$defaultRoom = Db::loadOne("SELECT room_id FROM rooms WHERE 'default' = 1");
|
||||
$defaultRoom = Db::loadOne("SELECT `room_id` FROM `rooms` WHERE `default` = 1");
|
||||
return $defaultRoom['room_id'];
|
||||
}
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ class UserManager
|
||||
{
|
||||
public static function getUsers ($filtr = ['*']) {
|
||||
try {
|
||||
$allUsers = Db::loadAll ("SELECT " . implode($filtr, ",") . " FROM users");
|
||||
$allUsers = Db::loadAll ("SELECT " . implode(",", $filtr) . " FROM users");
|
||||
return $allUsers;
|
||||
} catch(PDOException $error) {
|
||||
echo $error->getMessage();
|
||||
|
||||
Reference in new issue
Block a user