mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-26 02:03:45 +02:00
Thats enough re-theming for the day...
This commit is contained in:
@@ -29,11 +29,12 @@ use Cache;
|
||||
use Javascript;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Notifications\Notifiable;
|
||||
use Nicolaslopezj\Searchable\SearchableTrait;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
|
||||
class Server extends Model
|
||||
{
|
||||
use Notifiable, SoftDeletes;
|
||||
use Notifiable, SearchableTrait, SoftDeletes;
|
||||
|
||||
/**
|
||||
* The table associated with the model.
|
||||
@@ -85,6 +86,22 @@ class Server extends Model
|
||||
'installed' => 'integer',
|
||||
];
|
||||
|
||||
protected $searchable = [
|
||||
'columns' => [
|
||||
'servers.name' => 10,
|
||||
'servers.username' => 10,
|
||||
'servers.uuidShort' => 9,
|
||||
'servers.uuid' => 8,
|
||||
'users.email' => 6,
|
||||
'users.username' => 6,
|
||||
'nodes.name' => 2,
|
||||
],
|
||||
'joins' => [
|
||||
'users' => ['users.id', 'servers.owner_id'],
|
||||
'nodes' => ['nodes.id', 'servers.node_id'],
|
||||
],
|
||||
];
|
||||
|
||||
/**
|
||||
* Returns a single server specified by UUID.
|
||||
* DO NOT USE THIS TO MODIFY SERVER DETAILS OR SAVE THOSE DETAILS.
|
||||
|
||||
Reference in New Issue
Block a user