feat(admin): improve payments and server settings
This commit is contained in:
@@ -16,6 +16,7 @@ class DnsServer extends Model
|
||||
protected $fillable = [
|
||||
'name',
|
||||
'ip_address',
|
||||
'domain',
|
||||
'panel_port',
|
||||
'password',
|
||||
'username',
|
||||
@@ -31,6 +32,11 @@ class DnsServer extends Model
|
||||
return in_array($type, [ServerType::HOSTING->value, ServerType::BOTH->value], true);
|
||||
}
|
||||
|
||||
public function publicHost(): string
|
||||
{
|
||||
return $this->domain ?: $this->ip_address;
|
||||
}
|
||||
|
||||
protected function scopeIsActive($query)
|
||||
{
|
||||
return $query->where('status', 'activated');
|
||||
|
||||
Reference in New Issue
Block a user