WIP: posting shiai to the wkKalendar via api

This commit is contained in:
marko
2024-01-07 18:36:43 +01:00
parent 4bf364c83b
commit 14108660f9
6 changed files with 150 additions and 24 deletions

View File

@@ -75,6 +75,26 @@ class User
return dbConnector::getLastInsertId();
}
public static function dbSelectWithAttribute(int $attributeId)
{
$query =
"SELECT DISTINCT" .
" `wkParticipo_Users`.* " .
" FROM `wkParticipo_Users`" .
" JOIN `wkParticipo_user<=>userAttributes`" .
" ON `wkParticipo_user<=>userAttributes`.`userId` = `wkParticipo_Users`.`id`" .
" WHERE `wkParticipo_user<=>userAttributes`.`attributeId` = :attributeId".
" ORDER BY `wkParticipo_Users`.`id` ASC;";
$params = [
':attributeId' => ['value' => $attributeId, 'data_type' => PDO::PARAM_INT]
];
$response = dbConnector::query($query, $params);
return $response;
}
/** Name of the table with all the Users
*
* @var string