Esempio n. 1
0
 function remove($host, $port)
 {
     $service = new \DedicatedManager\Services\ServerService();
     $service->delete($host, $port);
     $this->request->redirectArgList('/');
 }
Esempio n. 2
0
 /**
  * @redirect
  */
 function stop()
 {
     if (!$this->isAdmin) {
         $this->session->set('error', _('You need to be an admin to do this'));
         $this->request->redirectToReferer();
     }
     $this->server->connection->stopServer();
     $service = new \DedicatedManager\Services\ServerService();
     $service->delete($this->server->rpcHost, $this->server->rpcPort);
     $this->session->set('success', _('Server has been stopped'));
     $this->request->redirectArgList('/');
 }