$ev = new Eventos("RestoreConfig", 1, $am); $ev->reconfigure(); break; case "saveConfig": $am->access(PERMS_ADMIN); $config = Config::getInstance(); $result = $config->saveConfig(); $ev = new Eventos("SaveConfig", 1, $am); $ev->reconfigure(); break; case "defaultConfig": $am->access(PERMS_ADMIN); $config = Config::getInstance(); $result = $config->defaultConfig(); $ev = new Eventos("DefaultConfig", 1, $am); $ev->reconfigure(); break; case "printerCheck": $am->access(PERMS_OPERATOR); $config = Config::getInstance(); $pname = http_request("event_printer", "s", ""); $pwide = http_request("wide_printer", "i", -1); $printer = new RawPrinter($pname, $pwide); $printer->rawprinter_check(); break; default: throw new Exception("adminFunctions:: invalid operation: '{$operation}' provided"); } if ($result === null) { throw new Exception($adm->errormsg); }