Optimising product category and category names
This commit is contained in:
@@ -149,6 +149,11 @@ class Account extends Model implements IDs
|
||||
return $this->company ?: ($this->user_id ? $this->user->getSurFirstNameAttribute() : 'LID:'.$this->id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the type of account this is - if it has a company name, then its a business account.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getTypeAttribute()
|
||||
{
|
||||
return $this->company ? 'Business' : 'Private';
|
||||
|
Reference in New Issue
Block a user