All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 39s
Docker Build & Deploy / Deploy to Production (push) Successful in 12s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
76 lines
1.6 KiB
C#
76 lines
1.6 KiB
C#
namespace Entity;
|
||
|
||
/// <summary>
|
||
/// 预算管理
|
||
/// </summary>
|
||
public class BudgetRecord : BaseEntity
|
||
{
|
||
/// <summary>
|
||
/// 预算名称
|
||
/// </summary>
|
||
public string Name { get; set; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 统计周期
|
||
/// </summary>
|
||
public BudgetPeriodType Type { get; set; } = BudgetPeriodType.Month;
|
||
|
||
/// <summary>
|
||
/// 预算金额
|
||
/// </summary>
|
||
public decimal Limit { get; set; }
|
||
|
||
/// <summary>
|
||
/// 预算类别
|
||
/// </summary>
|
||
public BudgetCategory Category { get; set; }
|
||
|
||
/// <summary>
|
||
/// 相关分类 (逗号分隔的分类名称)
|
||
/// </summary>
|
||
public string SelectedCategories { get; set; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 开始日期
|
||
/// </summary>
|
||
public DateTime StartDate { get; set; } = DateTime.Now;
|
||
|
||
/// <summary>
|
||
/// 不记额预算(选中后该预算没有预算金额,发生的收入或支出直接在存款中加减)
|
||
/// </summary>
|
||
public bool NoLimit { get; set; } = false;
|
||
|
||
/// <summary>
|
||
/// 硬性消费(固定消费,如房租、水电等。当是当前年月且为硬性消费时,会根据经过的天数累加Current)
|
||
/// </summary>
|
||
public bool IsMandatoryExpense { get; set; } = false;
|
||
}
|
||
|
||
public enum BudgetPeriodType
|
||
{
|
||
/// <summary>
|
||
/// 月
|
||
/// </summary>
|
||
Month = 1,
|
||
/// <summary>
|
||
/// 年
|
||
/// </summary>
|
||
Year = 2
|
||
}
|
||
|
||
public enum BudgetCategory
|
||
{
|
||
/// <summary>
|
||
/// 支出
|
||
/// </summary>
|
||
Expense = 0,
|
||
/// <summary>
|
||
/// 收入
|
||
/// </summary>
|
||
Income = 1,
|
||
/// <summary>
|
||
/// 存款
|
||
/// </summary>
|
||
Savings = 2
|
||
}
|