| 1 |
<?/* |
<?/* |
| 2 |
|
|
| 3 |
Originally written by Stefano Fabri <bluefuture@nospam@email.it> |
Originally written by Stefano Fabri <bluefuture@nospam@email.it> |
| 4 |
Copyright 2004, Stefano Fabri |
Copyright 2004, Stefano Fabri |
| 5 |
|
|
| 6 |
This program is free software; you can redistribute it and/or modify |
This program is free software; you can redistribute it and/or modify |
| 7 |
it under the terms of the GNU General Public License as published by |
it under the terms of the GNU General Public License as published by |
| 8 |
the Free Software Foundation; either version 2 of the License, or |
the Free Software Foundation; either version 2 of the License, or |
| 9 |
(at your option) any later version. |
(at your option) any later version. |
| 10 |
|
|
| 11 |
This program is distributed in the hope that it will be useful, |
This program is distributed in the hope that it will be useful, |
| 12 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 |
GNU General Public License for more details. |
GNU General Public License for more details. |
| 15 |
|
|
| 16 |
You should have received a copy of the GNU General Public License |
You should have received a copy of the GNU General Public License |
| 17 |
along with this program; if not, write to the Free Software |
along with this program; if not, write to the Free Software |
| 18 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 32 |
<? |
<? |
| 33 |
require("config_www.inc"); |
require("config_www.inc"); |
| 34 |
$rsql=pg_exec($db, |
$rsql=pg_exec($db, |
| 35 |
"Select id,mpop_inst,name,version,bytes, tot_up_error,tot_avg_error_date,pkgs.dist,up_version,watch_warn, up_changes from pkgs |
"Select id,mpop_inst,name,version,bytes, tot_up_error,tot_avg_error_date,pkgs.dist,up_version,watch_warn, up_changes from pkgs |
| 36 |
INNER join (Select max(pop_inst) as mpop_inst,SUM(up_error) as tot_up_error,AVG(avg_error_date) as tot_avg_error_date,name,dist FROM binpkgs GROUP BY name,dist) as binpkgs using(name,dist) |
INNER join (Select max(pop_inst) as mpop_inst,SUM(up_error) as tot_up_error,AVG(avg_error_date) as tot_avg_error_date,name,dist FROM binpkgs GROUP BY name,dist) as binpkgs using(name,dist) |
| 37 |
where updated='1' AND up_version!='' |
where updated='1' AND up_version!='' |
| 38 |
order by mpop_inst desc;") OR Die("Error on query");; |
order by mpop_inst desc;") OR Die("Error on query");; |
| 39 |
$rsql2=pg_exec($db, "SELECT count(name) from pkgs WHERE up_version IS NOT NULL") OR Die("Errore on query"); |
$rsql2=pg_exec($db, "SELECT count(name) from pkgs WHERE up_version IS NOT NULL") OR Die("Errore on query"); |
| 40 |
$totnowatch=pg_numrows($rsql); |
$totnowatch=pg_numrows($rsql); |
| 41 |
$totpkgs=pg_fetch_array($rsql2,0); |
$totpkgs=pg_fetch_array($rsql2,0); |
| 42 |
print "<b>Total Packages need to be get in sync</b>: $totnowatch |
print "<b>Total packages needing to be synced</b>: $totnowatch |
| 43 |
<b>Total with upstream found:</b> $totpkgs[0] <b>Percentage: </b> " . number_format ( $totnowatch/$totpkgs[0] * 100, 2, ",",".") . "%" ; |
<b>Total with upstream found:</b> $totpkgs[0] <b>Percentage: </b> " . number_format ( $totnowatch/$totpkgs[0] * 100, 2, ",",".") . "%" ; |
| 44 |
?> |
?> |
| 45 |
<table |
<table |
| 58 |
<td style="vertical-align: top; text-align: center; font-weight: bold;">Distrib</td> |
<td style="vertical-align: top; text-align: center; font-weight: bold;">Distrib</td> |
| 59 |
<td style="vertical-align: top;text-align: center; font-weight: bold;">Uscan Errors processing Watch File</td> |
<td style="vertical-align: top;text-align: center; font-weight: bold;">Uscan Errors processing Watch File</td> |
| 60 |
</tr> |
</tr> |
| 61 |
<? |
<? |
| 62 |
while ($res_array=pg_fetch_array($rsql)) { |
while ($res_array=pg_fetch_array($rsql)) { |
| 63 |
?> |
?> |
| 64 |
<tr> |
<tr> |
| 71 |
<a href="<? print "wwiz_detail.php?id=$res_array[id]&type=up_changes";?>"> |
<a href="<? print "wwiz_detail.php?id=$res_array[id]&type=up_changes";?>"> |
| 72 |
<? print htmlentities($res_array["up_version"]); ?></a><br> |
<? print htmlentities($res_array["up_version"]); ?></a><br> |
| 73 |
<?} |
<?} |
| 74 |
else print $res_array["up_version"].'<br>';?> |
else print $res_array["up_version"].'<br>';?> |
| 75 |
</td> |
</td> |
| 76 |
<td style="vertical-align: top;"><? print $res_array["version"]; ?><br> |
<td style="vertical-align: top;"><? print $res_array["version"]; ?><br> |
| 77 |
</td> |
</td> |
| 85 |
<td style="vertical-align: top;"><? print htmlentities($res_array["watch_warn"]); ?><br> |
<td style="vertical-align: top;"><? print htmlentities($res_array["watch_warn"]); ?><br> |
| 86 |
</td> |
</td> |
| 87 |
</tr> |
</tr> |
| 88 |
<? |
<? |
| 89 |
} |
} |
| 90 |
pg_close($db); |
pg_close($db); |
| 91 |
?> |
?> |
| 92 |
</tbody> |
</tbody> |
| 93 |
</table> |
</table> |
| 94 |
<br> |
<br> |