2 $CALL_ME_FUNCTIONS["repoadmin"] = "gwvp_RepoAdminCallMe";
4 $MENU_ITEMS["20repos"]["text"] = "Repo Admin";
5 $MENU_ITEMS["20repos"]["link"] = "$BASE_URL/admin/repos";
7 function gwvp_RepoAdminCallMe()
9 if(isset($_REQUEST["q"])) {
10 $query = $_REQUEST["q"];
11 $qspl = explode("/", $query);
12 if(isset($qspl[0]) && isset($qspl[1])) {
13 if($qspl[0] == "admin" && $qspl[1] == "repos") {
17 return "gwvp_CreateRepoPage";
20 return "gwvp_RepoAdminPage";
23 return "gwvp_RepoAdminPage";
33 function gwvp_RepoAdminPage()
35 gwvp_goMainPage("gwvp_RepoAdminPageBody");
39 function gwvp_RepoAdminPageBody()
41 // first we need a menu
44 echo "<h2>Repo Management</h2>";
45 echo "<a href=\"$BASE_URL/admin/repos/create\">Create a Repo</a><br>";
48 // next we need a repo list - with perms checking - ug
49 $rlist = gwvp_GetRepoList();
50 echo "<table border=\"1\"><tr><th>Repo Name</th><th>Repo Description</th><th>Repo Owner</th></tr>";
51 foreach($rlist as $u_res) {
52 $rname = $u_res["name"];
53 $rdesc = $u_res["description"];
54 $rown = $u_res["owner"];
55 echo "<tr><td>$rname</td><td>$rdesc</td><td>$rown</td></tr>";