Move location service to match other services
This commit is contained in:
parent
a8560b720a
commit
a498bbc7d5
14 changed files with 414 additions and 149 deletions
|
@ -28,17 +28,6 @@ use Pterodactyl\Contracts\Repository\Attributes\SearchableInterface;
|
|||
|
||||
interface LocationRepositoryInterface extends RepositoryInterface, SearchableInterface
|
||||
{
|
||||
/**
|
||||
* Delete a location only if there are no nodes attached to it.
|
||||
*
|
||||
* @param $id
|
||||
* @return bool|mixed|null
|
||||
*
|
||||
* @throws \Pterodactyl\Exceptions\DisplayException
|
||||
* @throws \Pterodactyl\Exceptions\Repository\RecordNotFoundException
|
||||
*/
|
||||
public function deleteIfNoNodes($id);
|
||||
|
||||
/**
|
||||
* Return locations with a count of nodes and servers attached to it.
|
||||
*
|
||||
|
@ -62,4 +51,14 @@ interface LocationRepositoryInterface extends RepositoryInterface, SearchableInt
|
|||
* @throws \Pterodactyl\Exceptions\Repository\RecordNotFoundException
|
||||
*/
|
||||
public function getWithNodes($id);
|
||||
|
||||
/**
|
||||
* Return a location and the count of nodes in that location.
|
||||
*
|
||||
* @param int $id
|
||||
* @return mixed
|
||||
*
|
||||
* @throws \Pterodactyl\Exceptions\Repository\RecordNotFoundException
|
||||
*/
|
||||
public function getWithNodeCount($id);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue