mirror of
https://gitee.com/koogua/course-tencent-cloud.git
synced 2025-07-06 00:41:09 +08:00
* 去除无用的auth_url * 修改readme * 修复计划任务生成sitemap.xml失败问题 * 增加课程推荐 * 增加后台刷新首页缓存小工具 * 调整公众号模板消息 * 增加刷新首页推荐课程缓存逻辑 * 更新课程综合评分算法 * 修复在线用户并发重复记录问题 * 增加限制共享帐号功能 * 修复数据迁移中无符号整型问题 * 更新版本为v1.2.3
73 lines
898 B
PHP
73 lines
898 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
class Online extends Model
|
|
{
|
|
|
|
/**
|
|
* 主键编号
|
|
*
|
|
* @var int
|
|
*/
|
|
public $id;
|
|
|
|
/**
|
|
* 用户编号
|
|
*
|
|
* @var int
|
|
*/
|
|
public $user_id;
|
|
|
|
/**
|
|
* 客户端类型
|
|
*
|
|
* @var int
|
|
*/
|
|
public $client_type;
|
|
|
|
/**
|
|
* 客户端IP
|
|
*
|
|
* @var string
|
|
*/
|
|
public $client_ip;
|
|
|
|
/**
|
|
* 活跃时间
|
|
*
|
|
* @var int
|
|
*/
|
|
public $active_time;
|
|
|
|
/**
|
|
* 创建时间
|
|
*
|
|
* @var int
|
|
*/
|
|
public $create_time;
|
|
|
|
/**
|
|
* 更新时间
|
|
*
|
|
* @var int
|
|
*/
|
|
public $update_time;
|
|
|
|
public function getSource(): string
|
|
{
|
|
return 'kg_online';
|
|
}
|
|
|
|
public function beforeCreate()
|
|
{
|
|
$this->create_time = time();
|
|
}
|
|
|
|
public function beforeUpdate()
|
|
{
|
|
$this->update_time = time();
|
|
}
|
|
|
|
}
|