function FindUIDs() { $res = array(); $flags = 0; if ($this->control) { $flags |= REQUEST::CONTROL; } $req = new REQUEST($tmp = array()); $groups = $req->GetGroups($flags); foreach ($groups as $greq) { $list = $greq->GetItemList($flags); foreach ($list as $id => &$item) { if (isset($item["uid"])) { $uid = $item["uid"]; $res[$uid] = $greq->GetProps(); $res[$uid]['db_mask'] = $id; } } } return $res; }
?><div class="header"><? foreach ($list as $sreq) { ?><a href="download.php?<?echo GetQueryString($sreq);?>"><?echo $sreq->props['db_server'];?>.<?echo $sreq->props['db_name'];?></a> <? } ?><a href="csvmerge.php">Merge Groups</a></div><? if ($nodata) exit; ?><h3>Server: <?echo $req->props['db_server'];?>, DataBase: <?echo $req->props['db_name'];?></h3><? //$props = array("db_server"=>"katrin", "db_name"=>"HS"); $reader = $req->CreateReader(); $groups = $reader->GetGroupList(REQUEST::NEED_INFO); $list = $req->GetGroups(); foreach ($list as $gid => $greq) { $group = $groups[$gid]; ?><div style="background-color: grey"> <h3><?echo $group["name"];?></h3> <?echo $group["comment"];?> <br/><br/> <? $first = $group["first"]; $last = $group["last"]; $first = floor($first); $last = ceil($last); $first_day = $first - ($first % $period); if ($last%$period) $last_day = $last + $period - ($last % $period);
function GetGroups(READER $rdr = NULL, $flags = 0) { if ($flags & REQUEST::LIST_ALL) { return REQUEST::GetGroups($flags); } $list = array(); if (isset($this->props['db_group'])) { $gid = $this->props['db_group']; $list[$gid] = array('db_group' => $gid); } else { if ($rdr) { $reader = $rdr; } else { $reader = $this->CreateReader(); } $list = $reader->GetGroupList($flags); foreach (array_keys($list) as $gid) { $list[$gid] = array('db_group' => $gid); } } return new REQUESTList($this->props, $list, "GROUPRequest"); }