feat(models): 添加模型类文档注释并实现MarkdownFileVO扩展功能
- 为Grouping、Image、MarkdownFile、RegistrationCode、SystemSetting、User等模型类添加详细的PHP文档注释 - 为各个模型类添加公共属性定义,包括分组、图片、笔记、注册码、系统设置和用户相关字段 - 实现MarkdownFileVO视图对象类,扩展MarkdownFile模型以支持分组名称查询 - 在MarkdownController中使用MarkdownFileVO替代原模型获取包含分组名称的数据 - 添加TrashItemVo视图对象用于回收站项目的展示 - 添加UpdatePasswordBo业务对象用于密码更新请求处理 - 为RegistrationCode模型添加按ID和代码查询的方法及详细验证功能 - 为SystemSetting模型添加带描述的设置获取和设置方法
This commit is contained in:
@@ -5,10 +5,30 @@ namespace App\Models;
|
||||
use App\Utils\Database;
|
||||
use PDO;
|
||||
|
||||
/**
|
||||
* Grouping - 分组模型
|
||||
*
|
||||
* 数据库表: grouping
|
||||
* 主要字段:
|
||||
* - id (Long) - 分组ID,雪花算法生成
|
||||
* - parentId (Long) - 上级分组ID(支持分组嵌套)
|
||||
* - grouping (String) - 分组名称
|
||||
* - is_deleted (Integer) - 逻辑删除标志(0-未删除,1-已删除)
|
||||
* - deleted_at (DateTime) - 删除时间
|
||||
* - deleted_by (Long) - 删除人ID
|
||||
*/
|
||||
class Grouping
|
||||
{
|
||||
private $db;
|
||||
|
||||
// 分组属性
|
||||
public $id;
|
||||
public $parentId;
|
||||
public $grouping;
|
||||
public $isDeleted;
|
||||
public $deletedAt;
|
||||
public $deletedBy;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->db = Database::getInstance()->getConnection();
|
||||
|
||||
Reference in New Issue
Block a user