Changeset View
Changeset View
Standalone View
Standalone View
src/app/Entitlement.php
Show First 20 Lines • Show All 113 Lines • ▼ Show 20 Lines | class Entitlement extends Model | ||||
{ | { | ||||
if ($this->entitleable instanceof \App\User) { | if ($this->entitleable instanceof \App\User) { | ||||
return $this->entitleable->email; | return $this->entitleable->email; | ||||
} | } | ||||
if ($this->entitleable instanceof \App\Domain) { | if ($this->entitleable instanceof \App\Domain) { | ||||
return $this->entitleable->namespace; | return $this->entitleable->namespace; | ||||
} | } | ||||
return null; | |||||
} | } | ||||
/** | /** | ||||
* The SKU concerned. | * The SKU concerned. | ||||
* | * | ||||
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo | ||||
*/ | */ | ||||
public function sku() | public function sku() | ||||
Show All 22 Lines |