Documentation

ServiceService
in package

Table of Contents

$likeableFields  : array<string|int, mixed>
$searchableFields  : array<string|int, mixed>
fetchAllByAccountId()  : LengthAwarePaginator
Retrieves all services of Account
fetchAllByProductId()  : LengthAwarePaginator
Retrieves all services of a particular Product
fetchOne()  : Service
Retrieves the whmcs Service with the specified id
find()  : LengthAwarePaginator
Retrieves all WHMCS Services meeting the criteria of the request
compileSelect()  : Builder
Prepare the select statement

Properties

$likeableFields

private array<string|int, mixed> $likeableFields = ['group_name', 'product_name', 'domain']

fields queried with like operator

$searchableFields

private array<string|int, mixed> $searchableFields = ['gid' => 'tblproducts.gid', 'group_name' => 'tblproductgroups.name', 'pid' => 'tblproducts.pid', 'product_name' => 'tblproducts.name', 'domain' => 'tblhosting.domain', 'status' => 'tblhosting.domainstatus', 'client_id' => 'tblhosting.userid']

searchable fields accepted in the request, translated to raw database field

Methods

fetchAllByAccountId()

Retrieves all services of Account

public fetchAllByAccountId(int $accountId) : LengthAwarePaginator
Parameters
$accountId : int

the account id

Return values
LengthAwarePaginator

a paginated result

fetchAllByProductId()

Retrieves all services of a particular Product

public fetchAllByProductId(int $productId) : LengthAwarePaginator
Parameters
$productId : int

the product id

Return values
LengthAwarePaginator

a paginated result of Service

fetchOne()

Retrieves the whmcs Service with the specified id

public fetchOne(int $id) : Service
Parameters
$id : int

whmcs service id

Return values
Service

the service object

find()

Retrieves all WHMCS Services meeting the criteria of the request

public find([array<string|int, mixed> $criteria = [] ]) : LengthAwarePaginator
Parameters
$criteria : array<string|int, mixed> = []

associative array of field and value

Return values
LengthAwarePaginator

a paginated result

compileSelect()

Prepare the select statement

private compileSelect() : Builder
Return values
Builder

the statement

Search results