function invalidateSimulations() { require_once R3_LIB_DIR . 'eco_simulator.php'; R3Simulator::invalidateAllSimulations($_SESSION['do_id']); }
static function getSummaryTotals($sw_id, array $idList = array(), array $percList = array(), $factor = 1, $returnAsLocale = false, $returnGlobalData = false, $efe1 = null, $efe2 = null) { //, $efe=null) { //, $efe2=null) { $simulator = new R3Simulator(); $simulator->loadDataFromSimulation($sw_id); $simulationNo = 0; foreach ($idList as $ac_id) { $simulator->loadSimulationData($ac_id, $percList[$simulationNo]); $simulationNo++; } $simulator->calculate(); self::$log = $simulator->getLog(); if ($returnGlobalData) { // Qui per generazione paes $data = $simulator->getGlobalSimulationData(); } else { $data = $simulator->getData($factor, $returnAsLocale); } return $data; }