<?
//FIXME: I just ripped these out of the fair year rollover since they are no longer tied to the fair year, they are now tied to the FISCAL year, we'll need to implement a new fiscal year rollover mechanism similar to the fairyear rollover
//FIXME: The table names are also wrong since i've now renamed htem all, will fix when the fiscal rollover is implemented
		echo i18n("Rolling fundraising goals")." <br />";
        roll($currentfairyear, $newfairyear, "fundraising",
            array("type","name","description","system","goal"));

		echo i18n("Rolling sponsorship levels")." <br />";
        roll($currentfairyear, $newfairyear, "sponsorships_levels",
            array("level","min","max","description"));

		echo i18n("Rolling sponsorships")." <br />";
        roll($currentfairyear, $newfairyear, "sponsorships",
            array("sponsors_id","fundraising_type","value")); //no need to roll status or probability, because we're about to reset them..
        mysql_query("UPDATE sponsorships SET status='pending', probability=25 WHERE year='$newfairyear'");
        $q=mysql_query("SELECT * FROM sponsorships WHERE year='$newfairyear'");
        while($r=mysql_fetch_object($q)) {
            mysql_query("INSERT INTO sponsors_logs (sponsors_id,dt,users_id,log) VALUES ('$r->sponsors_id',NOW(),'{$_SESSION['auth_user_id']}','Fair year rollover - reset status=pending, probability=25\%')");
        }


?>
