32 $this->db = (
$db != null)
47 "SELECT * FROM wfld_user_setting " .
48 " WHERE user_id = %s " .
50 array(
"integer",
"integer"),
51 array($this->user_id, $wfld_id)
53 $rec =
$db->fetchAssoc($set);
54 return (
int) $rec[
"sortation"];
67 "SELECT * FROM wfld_user_setting " .
68 " WHERE user_id = %s " .
69 " AND " .
$db->in(
"wfld_id", $wfld_ids,
false,
"integer"),
75 while ($rec =
$db->fetchAssoc($set)) {
76 $ret[$rec[
"wfld_id"]] = (int) $rec[
"sortation"];
78 foreach ($wfld_ids as $id) {
79 if (!isset(
$ret[$id])) {
95 $db->replace(
"wfld_user_setting", array(
96 "user_id" => array(
"integer", $this->user_id),
97 "wfld_id" => array(
"integer", $wfld_id)
99 "sortation" => array(
"integer", $sortation)
__construct($user_id, ilDBInterface $db=null)
Constructor.
getSortation(int $wfld_id)
Get Sortation of workspace folder.
Stores user settings per workspace folder Table: wfld_user_setting (rw)
updateSortation(int $wfld_id, int $sortation)
Update sortation for workspace folder.
getSortationMultiple(array $wfld_ids)
Get Sortation of workspace folder.