diff --git a/.idea/dataSources.xml b/.idea/dataSources.xml index 94734fd..2321224 100644 --- a/.idea/dataSources.xml +++ b/.idea/dataSources.xml @@ -1,11 +1,11 @@ - + mysql.8 true com.mysql.cj.jdbc.Driver - jdbc:mysql://its-dev.site:3306/delta_core + jdbc:mysql://10.10.10.85:3306/delta $ProjectFileDir$ diff --git a/core/lib/Core/Database/DataBase.php b/core/lib/Core/Database/DataBase.php index 90d6def..ffb5fe7 100644 --- a/core/lib/Core/Database/DataBase.php +++ b/core/lib/Core/Database/DataBase.php @@ -99,7 +99,7 @@ */ public function update(string $table, array $where, array $set): bool { - return $this->db->update($table, $set, $where); + return $this->db->update($table, $where, $set); } /** diff --git a/core/lib/Core/Models/User.class.php b/core/lib/Core/Models/User.class.php index d7f2cf1..20c61a7 100644 --- a/core/lib/Core/Models/User.class.php +++ b/core/lib/Core/Models/User.class.php @@ -676,6 +676,7 @@ if (empty($_SESSION['authorize'])) { self::authorize($arUser['id']); } + $DB->update(self::TABLE, ['id' => $arUser['id']], ['last_active' => time()]); return true; } }