Changeset View
Changeset View
Standalone View
Standalone View
src/app/Group.php
<?php | <?php | ||||
namespace App; | namespace App; | ||||
use App\Traits\UuidIntKeyTrait; | |||||
use App\Wallet; | use App\Wallet; | ||||
use Illuminate\Database\Eloquent\Model; | use Illuminate\Database\Eloquent\Model; | ||||
use Illuminate\Database\Eloquent\SoftDeletes; | use Illuminate\Database\Eloquent\SoftDeletes; | ||||
/** | /** | ||||
* The eloquent definition of a Group. | * The eloquent definition of a Group. | ||||
* | * | ||||
* @property int $id The group identifier | * @property int $id The group identifier | ||||
* @property string $email An email address | * @property string $email An email address | ||||
* @property string $members A comma-separated list of email addresses | * @property string $members A comma-separated list of email addresses | ||||
* @property int $status The group status | * @property int $status The group status | ||||
* @property int $tenant_id Tenant identifier | * @property int $tenant_id Tenant identifier | ||||
*/ | */ | ||||
class Group extends Model | class Group extends Model | ||||
{ | { | ||||
use UuidIntKeyTrait; | |||||
use SoftDeletes; | use SoftDeletes; | ||||
// we've simply never heard of this domain | // we've simply never heard of this domain | ||||
public const STATUS_NEW = 1 << 0; | public const STATUS_NEW = 1 << 0; | ||||
// it's been activated | // it's been activated | ||||
public const STATUS_ACTIVE = 1 << 1; | public const STATUS_ACTIVE = 1 << 1; | ||||
// domain has been suspended. | // domain has been suspended. | ||||
public const STATUS_SUSPENDED = 1 << 2; | public const STATUS_SUSPENDED = 1 << 2; | ||||
// domain has been deleted | // domain has been deleted | ||||
public const STATUS_DELETED = 1 << 3; | public const STATUS_DELETED = 1 << 3; | ||||
// domain has been created in LDAP | // domain has been created in LDAP | ||||
public const STATUS_LDAP_READY = 1 << 4; | public const STATUS_LDAP_READY = 1 << 4; | ||||
public $incrementing = false; | |||||
protected $keyType = 'bigint'; | |||||
protected $fillable = [ | protected $fillable = [ | ||||
'email', | 'email', | ||||
'status', | 'status', | ||||
'members' | 'members' | ||||
]; | ]; | ||||
/** | /** | ||||
* Assign the group to a wallet. | * Assign the group to a wallet. | ||||
▲ Show 20 Lines • Show All 248 Lines • Show Last 20 Lines |