Page MenuHomePhorge

GroupMember.php
No OneTemporary

Authored By
Unknown
Size
958 B
Referenced Files
None
Subscribers
None

GroupMember.php

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
/**
* A collection of group members.
*
* @property int $id
* @property int $group_id
* @property string $email
*/
class GroupMember extends Model
{
/** @var list<string> The attributes that are mass assignable */
protected $fillable = ['group_id', 'email'];
/** @var bool Indicates if the model should be timestamped. */
public $timestamps = false;
/**
* The group to which this member belongs.
*
* @return BelongsTo<Group, $this>
*/
public function group()
{
return $this->belongsTo(Group::class, 'group_id', 'id');
}
/**
* Ensure the email address is appropriately cased.
*
* @param string $email Email address
*/
public function setEmailAttribute(string $email)
{
$this->attributes['email'] = \strtolower($email);
}
}

File Metadata

Mime Type
text/x-php
Expires
Sat, Apr 4, 12:40 AM (4 w, 4 h ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
cd/ac/742ddfc39a99113dec4dee108a7e
Default Alt Text
GroupMember.php (958 B)

Event Timeline