功能添加
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 20s
Docker Build & Deploy / Deploy to Production (push) Successful in 5s

This commit is contained in:
孙诚
2025-12-26 15:21:31 +08:00
parent 7dfb6a5902
commit cb11d80d1f
26 changed files with 2208 additions and 841 deletions

View File

@@ -1,4 +1,6 @@
namespace Entity;
using System.Security.Cryptography;
namespace Entity;
/// <summary>
/// 邮件消息实体
@@ -29,4 +31,14 @@ public class EmailMessage : BaseEntity
/// 邮件接收时间
/// </summary>
public DateTime ReceivedDate { get; set; }
public string Md5 { get; set; } = string.Empty;
public string ComputeBodyHash()
{
using var md5 = MD5.Create();
var inputBytes = System.Text.Encoding.UTF8.GetBytes(Body + HtmlBody);
var hashBytes = md5.ComputeHash(inputBytes);
return Convert.ToHexString(hashBytes);
}
}

View File

@@ -1,7 +1,7 @@
namespace Entity;
/// <summary>
/// 交易分类(层级结构:类型 -> 分类 -> 子分类)
/// 交易分类
/// </summary>
public class TransactionCategory : BaseEntity
{
@@ -10,38 +10,8 @@ public class TransactionCategory : BaseEntity
/// </summary>
public string Name { get; set; } = string.Empty;
/// <summary>
/// 父分类ID0表示顶级分类
/// </summary>
public long ParentId { get; set; }
/// <summary>
/// 交易类型(支出/收入)
/// </summary>
public TransactionType Type { get; set; }
/// <summary>
/// 层级1=类型级, 2=分类级, 3=子分类级)
/// </summary>
public int Level { get; set; }
/// <summary>
/// 排序号
/// </summary>
public int SortOrder { get; set; }
/// <summary>
/// 图标(可选)
/// </summary>
public string? Icon { get; set; }
/// <summary>
/// 是否启用
/// </summary>
public bool IsEnabled { get; set; } = true;
/// <summary>
/// 备注
/// </summary>
public string? Remark { get; set; }
}

View File

@@ -50,11 +50,6 @@ public class TransactionRecord : BaseEntity
/// </summary>
public string Classify { get; set; } = string.Empty;
/// <summary>
/// 交易子分类
/// </summary>
public string SubClassify { get; set; } = string.Empty;
/// <summary>
/// 导入编号
/// </summary>