]> mop.ddnsfree.com - git repositories - brisk.git/commitdiff
statadm.php: check if users are enabled, add bidirectionality to sql column renaming...
authorMatteo Nastasi (mop) <nastasi@alternativeoutput.it>
Mon, 13 Jan 2014 18:24:25 +0000 (19:24 +0100)
committerMatteo Nastasi (mop) <nastasi@alternativeoutput.it>
Mon, 13 Jan 2014 18:24:25 +0000 (19:24 +0100)
TODO.txt
sql/sql.d/052-user-rename-tsusp.sql
web/briskin5/statadm.php

index a3488462b5b4781013349706566f6e4b8f1fd1cd..107969d315a9c4087b5abb295b6130cdf65091eb 100644 (file)
--- a/TODO.txt
+++ b/TODO.txt
@@ -4,7 +4,7 @@
   FEATURES |
  ----------+
    - AUTO-MAINTENANCE
-     . Terms Of Service acceptance
+     DONE . Terms Of Service acceptance
        DONE . print date of hard switch
        DONE . TOS version
        DONE . user TOS acceptance (db field)
index e21998334cffd1e002b5e09dbc69b8310a259a26..25a8896019b9e17702e6ddd6bc1e6c4bfb88f056 100644 (file)
@@ -1 +1,3 @@
-ALTER TABLE #PFX#users RENAME COLUMN tsusp TO lintm;
+ALTER TABLE #PFX#users RENAME COLUMN lintm TO tsusp; --MB
+ALTER TABLE #PFX#users RENAME COLUMN tsusp TO lintm; --MF
+
index f6d40b3d7eeb292b5f4257318f09ce6558793f33..f1c7bfcfae1cf83479494811131084eee1365891 100644 (file)
@@ -339,6 +339,7 @@ function main_pgsql($curtime)
             $pla_sql = sprintf("SELECT (float4(sum(p.pts)) * 100.0 ) /  float4(count(p.pts)) as score, sum(p.pts) as points, count(p.pts) as games, u.code as ucode, u.login as login
                                 FROM %sbin5_points as p, %sbin5_games as g, %sbin5_matches as m, %susers as u 
                                 WHERE m.tcode = %d AND m.code = g.mcode AND
+                                      ( (u.type & (CAST (X'ff0000' as integer))) <> (CAST (X'800000' as integer)) ) AND
                                       g.tstamp > to_timestamp(%d) AND g.tstamp <= to_timestamp(%d) AND
                                       p.ucode = u.code AND p.gcode = g.code
                                 GROUP BY u.code, u.login