前端目录调整
This commit is contained in:
20
app/model/user/Users.php
Normal file
20
app/model/user/Users.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | SentCMS [ WE CAN DO IT JUST THINK IT ]
|
||||
// +----------------------------------------------------------------------
|
||||
// | Copyright (c) 2013 http://www.tensent.cn All rights reserved.
|
||||
// +----------------------------------------------------------------------
|
||||
// | Author: molong <molong@tensent.cn> <http://www.tensent.cn>
|
||||
// +----------------------------------------------------------------------
|
||||
namespace app\model\user;
|
||||
|
||||
use app\model\BaseModel;
|
||||
use xiaodi\JWTAuth\Facade\Jwt;
|
||||
|
||||
class Users extends BaseModel{
|
||||
|
||||
public function getTokenAttr($value, $data){
|
||||
$token = Jwt::store('api')->token($data)->__toString();
|
||||
return $token;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user