lasthourcloud/app/Http/Livewire/Server/Proxy.php
Joao Patricio 931664c0c0 wip
2023-05-12 19:15:36 +01:00

46 lines
896 B
PHP

<?php
namespace App\Http\Livewire\Server;
use App\Actions\Proxy\InstallProxy;
use App\Enums\ActivityTypes;
use App\Models\Server;
use Livewire\Component;
class Proxy extends Component
{
public Server $server;
protected string $selectedProxy = '';
public $is_proxy_installed;
public $is_check_proxy_complete = false;
public $is_proxy_settings_in_sync = false;
public function mount(Server $server)
{
$this->server = $server;
}
public function runInstallProxy()
{
$activity = resolve(InstallProxy::class)($this->server);
$this->emit('newMonitorActivity', $activity->id);
}
public function checkProxySettingsInSync()
{
$this->is_check_proxy_complete = true;
$this->is_proxy_settings_in_sync = true;
}
public function render()
{
return view('livewire.server.proxy');
}
}