diff --git a/config/rollover.php b/config/rollover.php index 149367b..5c93ee7 100644 --- a/config/rollover.php +++ b/config/rollover.php @@ -232,8 +232,10 @@ $q=mysql_query("SELECT * FROM schools WHERE year='$currentfairyear'"); echo mysql_error(); while($r=mysql_fetch_object($q)) - mysql_query("INSERT INTO schools (school,phone,fax,address,city,province_code,postalcode,sciencehead,scienceheademail,scienceheadphone,accesscode,lastlogin,junior,intermediate,senior,registration_password,year) VALUES ( + mysql_query("INSERT INTO schools (school,board,district,phone,fax,address,city,province_code,postalcode,sciencehead,scienceheademail,scienceheadphone,accesscode,lastlogin,junior,intermediate,senior,registration_password,projectlimit,projectlimitper,year) VALUES ( '".mysql_escape_string($r->school)."', + '".mysql_escape_string($r->board)."', + '".mysql_escape_string($r->district)."', '".mysql_escape_string($r->phone)."', '".mysql_escape_string($r->fax)."', '".mysql_escape_string($r->address)."', @@ -249,6 +251,8 @@ '".mysql_escape_string($r->intermediate)."', '".mysql_escape_string($r->senior)."', '".mysql_escape_string($r->registration_password)."', + '".mysql_escape_string($r->projectlimit)."', + '".mysql_escape_string($r->projectlimitper)."', '".mysql_escape_string($newfairyear)."')"); echo i18n("Rolling questions")."
"; diff --git a/db/db.code.version.txt b/db/db.code.version.txt index 3c03207..d6b2404 100644 --- a/db/db.code.version.txt +++ b/db/db.code.version.txt @@ -1 +1 @@ -18 +19 diff --git a/db/db.update.19.sql b/db/db.update.19.sql new file mode 100644 index 0000000..03887a3 --- /dev/null +++ b/db/db.update.19.sql @@ -0,0 +1 @@ +ALTER TABLE `schools` CHANGE `lastlogin` `lastlogin` DATETIME NULL;