Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F120825192
Distlist.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
Distlist.php
View Options
<?php
namespace
App\Handlers
;
class
Distlist
extends
Beta\Base
{
/**
* The entitleable class for this handler.
*
* @return string
*/
public
static
function
entitleableClass
():
string
{
return
\App\User
::
class
;
}
/**
* Check if the SKU is available to the user.
*
* @param \App\Sku $sku The SKU object
* @param \App\User $user The user object
*
* @return bool
*/
public
static
function
isAvailable
(
\App\Sku
$sku
,
\App\User
$user
):
bool
{
// This SKU must be:
// - already assigned, or active and a 'beta' entitlement must exist
// - and this is a group account owner (custom domain)
if
(
parent
::
isAvailable
(
$sku
,
$user
))
{
return
$user
->
wallet
()->
entitlements
()
->
where
(
'entitleable_type'
,
\App\Domain
::
class
)->
count
()
>
0
;
}
return
false
;
}
/**
* The priority that specifies the order of SKUs in UI.
* Higher number means higher on the list.
*
* @return int
*/
public
static
function
priority
():
int
{
return
10
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Apr 24, 10:34 AM (14 m, 21 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18760479
Default Alt Text
Distlist.php (1 KB)
Attached To
Mode
rK kolab
Attached
Detach File
Event Timeline