FEATURE: style menu
This commit adds some markup to sidebars in admin.
This commit is contained in:
+15
-4
@@ -3,7 +3,6 @@
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Auth\Authenticatable;
|
||||
use Illuminate\Auth\Passwords\CanResetPassword;
|
||||
use Illuminate\Contracts\Auth\Authenticatable as AuthenticableInterface;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Foundation\Auth\Access\Authorizable;
|
||||
@@ -14,7 +13,6 @@ use Illuminate\Foundation\Auth\Access\Authorizable;
|
||||
class User extends Model implements AuthenticableInterface
|
||||
{
|
||||
use Authenticatable, Authorizable;
|
||||
|
||||
public $timestamps = false;
|
||||
protected $fillable = [
|
||||
'email',
|
||||
@@ -32,11 +30,24 @@ class User extends Model implements AuthenticableInterface
|
||||
'password',
|
||||
'remember_token',
|
||||
];
|
||||
|
||||
const STATE_DELETED = 'deleted';
|
||||
const STATE_BLOCKED = 'blocked';
|
||||
const STATE_ACTIVE = 'active';
|
||||
const ROLE_VISITOR = 'visitor';
|
||||
const ROLE_EDITOR = 'editor';
|
||||
const ROLE_ADMIN = 'admin';
|
||||
}
|
||||
|
||||
/**
|
||||
* Getter for Gravatar URL
|
||||
*
|
||||
* This method returns full path (url) to user's Gravatar. It accepts optional parameter for setting size.
|
||||
*
|
||||
* @param int $size size of rendered gravatar
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function gravatar($size = 50)
|
||||
{
|
||||
return "http://www.gravatar.com/avatar/" . md5(strtolower(trim($this->email))) . "?s=" . $size;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user