osb/app/Models/ServiceVoip.php
2018-11-21 14:37:17 +11:00

25 lines
481 B
PHP

<?php
namespace App\Models;
use App\Models\Service_Model as Model;
use App\Traits\NextKey;
class ServiceVoip extends Model
{
use NextKey;
protected $table = 'ab_service__voip';
public $timestamps = FALSE;
public function getFullNameAttribute()
{
return ($this->service_number AND $this->service_address)
? sprintf('%s: %s',$this->service_number, $this->service_address)
: $this->name;
}
public function getNameAttribute()
{
return $this->service_number;
}
}