feat: 添加记录操作日志功能
This commit is contained in:
35
app/admin/model/v1/SysOperateLog.php
Normal file
35
app/admin/model/v1/SysOperateLog.php
Normal file
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
declare (strict_types = 1);
|
||||
|
||||
namespace app\admin\model\v1;
|
||||
|
||||
use think\Model;
|
||||
|
||||
/**
|
||||
* @mixin \think\Model
|
||||
*/
|
||||
class SysOperateLog extends Model
|
||||
{
|
||||
// 表名
|
||||
protected $name = 'sys_operate_log';
|
||||
|
||||
// 主键
|
||||
protected $pk = 'id';
|
||||
|
||||
// 字段信息
|
||||
protected $schema = [
|
||||
'id' => 'int',
|
||||
'user_id' => 'int',
|
||||
'title' => 'string',
|
||||
'version' => 'string',
|
||||
'method' => 'string',
|
||||
'controller' => 'string',
|
||||
'action' => 'string',
|
||||
'url' => 'string',
|
||||
'ip' => 'string',
|
||||
'params' => 'string',
|
||||
'status' => 'int',
|
||||
'message' => 'string',
|
||||
'created_at' => 'datetime'
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user