U:调整所有代码格式
This commit is contained in:
1 parent
d133bacf55
commit
155b67e831
342 files changed
+9431
-9868
No files matched your search
@@ -177,6 +177,7 @@ public class MyEntity
|
||||
### AuditableEntity<TKey> - 审计实体(可选)
|
||||
|
||||
如果继承此基类,会自动管理以下字段:
|
||||
|
||||
- `Id` - 主键
|
||||
- `CreatedAt` - 创建时间
|
||||
- `CreatedBy` - 创建人
|
||||
@@ -361,6 +362,7 @@ builder.Services.AddHttpContextAccessor();
|
||||
### 与 Sharp.Common 集成(已内置)
|
||||
|
||||
Data 模块已经引用了 Common 模块,可以直接使用:
|
||||
|
||||
- `PagedResult<T>` - 分页结果
|
||||
- `Result<T>` - 错误处理(可选)
|
||||
- 各种扩展方法
|
||||
@@ -409,6 +411,7 @@ catch
|
||||
### Q: 我必须使用 Entity/AuditableEntity 基类吗?
|
||||
|
||||
**不是!** 基类是**完全可选**的。你可以:
|
||||
|
||||
- 使用自己的实体定义
|
||||
- 实现 `IAuditableEntity` 或 `ISoftDeletable` 接口
|
||||
- 完全不使用审计和软删除功能
|
||||
|
||||
Reference in new issue
Block a user