mirror of
https://gitlab.linphone.org/BC/public/flexisip-account-manager.git
synced 2026-01-17 10:08:05 +00:00
Cleanup the returned Vcard 4.0 formats Implement the recently introducted REST endpoints in the admin panels Add account actions logs to the new Controllers
28 lines
593 B
PHP
28 lines
593 B
PHP
<?php
|
|
|
|
namespace App;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class AccountAction extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
public static $protocols = ['sipinfo' => 'SIPInfo', 'rfc2833' => 'RFC2833'];
|
|
|
|
public static function protocolsRule()
|
|
{
|
|
return implode(',', array_keys(self::$protocols));
|
|
}
|
|
|
|
public function getResolvedProtocolAttribute()
|
|
{
|
|
return self::$protocols[$this->attributes['protocol']];
|
|
}
|
|
|
|
public function account()
|
|
{
|
|
return $this->belongsTo('App\Account');
|
|
}
|
|
}
|