mirror of
https://github.com/usetrmnl/byos_laravel.git
synced 2026-01-13 15:07:49 +00:00
feat(#36): add Mail notification on Low Battery
This commit is contained in:
parent
1122764333
commit
33e1f99fad
11 changed files with 375 additions and 0 deletions
|
|
@ -15,6 +15,7 @@ class Device extends Model
|
|||
protected $guarded = ['id'];
|
||||
|
||||
protected $casts = [
|
||||
'battery_notification_sent' => 'boolean',
|
||||
'proxy_cloud' => 'boolean',
|
||||
'last_log_request' => 'json',
|
||||
'proxy_cloud_response' => 'json',
|
||||
|
|
@ -179,4 +180,9 @@ class Device extends Model
|
|||
{
|
||||
return $this->hasMany(DeviceLog::class);
|
||||
}
|
||||
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(User::class);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue