Редакция 616 | К новейшей редакции | Весь файл | Учитывать пробелы | Содержимое файла | Авторство | Последнее изменение | Открыть журнал | RSS
Редакция 616 | Редакция 617 | ||
---|---|---|---|
Строка 1903... | Строка 1903... | ||
1903 | * @param string $actor
|
1903 | * @param string $actor
|
1904 | * @param string $format
|
1904 | * @param string $format
|
1905 | * @return string
|
1905 | * @return string
|
1906 | */
|
1906 | */
|
1907 | public function showRepositoriesList($name, $actor, $format = 'list') { |
1907 | public function showRepositoriesList($name, $actor, $format = 'list') { |
1908 | $query = "SELECT * FROM ".$this->prefix."repository r "; |
1908 | $query = "SELECT r.*,rt.*,CONCAT(v.version,' ',v.vname) AS fullname FROM ".$this->prefix."repository r "; |
1909 | $query .= "JOIN ".$this->prefix."rtype rt ON rt.rtype_id=r.rtype_id "; |
1909 | $query .= "JOIN ".$this->prefix."rtype rt ON rt.rtype_id=r.rtype_id "; |
1910 | $query .= "JOIN ".$this->prefix."version v ON v.version_id=r.version"; |
1910 | $query .= "JOIN ".$this->prefix."version v ON v.version_id=r.version"; |
1911 | $rq =& $this->db->query($query); |
1911 | $rq =& $this->db->query($query); |
1912 | $show = "<ul>"; |
1912 | $show = "<ul>"; |
1913 | while ($rq->fetchInto($element)) { |
1913 | while ($rq->fetchInto($element)) { |
1914 | $show .= "<li>[<a href='".$actor."?mode=".$name."&action=edit&uuid=".$this->secure->checkInt($element["rep_id"])."' class='edit'>править</a>][<a href='".$actor."?mode=".$name."&action=delete&uuid=".$this->secure->checkInt($element["rep_id"])."' class='delete'>удалить</a>] ".$this->secure->checkStr($element["repname"],1)." (".$this->secure->checkStr($element["rtype"],1)."; <em>".$this->secure->checkStr($element["vname"],1)."</em>)</li>\n"; |
1914 | $show .= "<li>[<a href='".$actor."?mode=".$name."&action=edit&uuid=".$this->secure->checkInt($element["rep_id"])."' class='edit'>править</a>][<a href='".$actor."?mode=".$name."&action=delete&uuid=".$this->secure->checkInt($element["rep_id"])."' class='delete'>удалить</a>] ".$this->secure->checkStr($element["repname"],1)." (".$this->secure->checkStr($element["fullname"],1)." — ".$this->secure->checkStr($element["rtype"],1).")</li>\n"; |
1915 | }
|
1915 | }
|
1916 | $show .= "</ul>"; |
1916 | $show .= "</ul>"; |
1917 | return $show; |
1917 | return $show; |
1918 | }
|
1918 | }
|
1919 | 1919 |