Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F120833977
Entitlement.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
Entitlement.php
View Options
<?php
namespace
App
;
use
Illuminate\Database\Eloquent\Model
;
/**
* The eloquent definition of an Entitlement.
*
* Owned by a {@link \App\User}, billed to a {@link \App\Wallet}.
*
* @property \App\User $owner The owner of this entitlement (subject).
* @property \App\Sku $sku The SKU to which this entitlement applies.
* @property \App\Wallet $wallet The wallet to which this entitlement is charged.
* @property \App\Domain|\App\User $entitleable The entitled object (receiver of the entitlement).
*/
class
Entitlement
extends
Model
{
/**
* This table does not use auto-increment.
*
* @var boolean
*/
public
$incrementing
=
false
;
/**
* The key type is actually a string.
*
* @var string
*/
protected
$keyType
=
'string'
;
/**
* The fillable columns for this Entitlement
*
* @var array
*/
protected
$fillable
=
[
'sku_id'
,
'owner_id'
,
'wallet_id'
,
'entitleable_id'
,
'entitleable_type'
,
'description'
];
/**
* Principally entitleable objects such as 'Domain' or 'User'.
*
* @return mixed
*/
public
function
entitleable
()
{
return
$this
->
morphTo
();
}
/**
* The SKU concerned.
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public
function
sku
()
{
return
$this
->
belongsTo
(
'App
\S
ku'
);
}
/**
* The owner of this entitlement.
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public
function
owner
()
{
return
$this
->
belongsTo
(
'App
\U
ser'
,
'owner_id'
,
'id'
);
}
/**
* The wallet this entitlement is being billed to
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public
function
wallet
()
{
return
$this
->
belongsTo
(
'App
\W
allet'
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Apr 24, 12:56 PM (1 w, 2 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18807069
Default Alt Text
Entitlement.php (1 KB)
Attached To
Mode
rK kolab
Attached
Detach File
Event Timeline