fix 消费恢复为余额表

This commit is contained in:
2024-11-21 10:27:08 +08:00
parent 2a97798118
commit 484be10fde
8 changed files with 168 additions and 36 deletions

View File

@@ -0,0 +1,27 @@
using Kurisu.AspNetCore.DataAccess.Entity;
using Kurisu.AspNetCore.DataAccess.SqlSugar;
using SqlSugar;
namespace Dlhis.Entity.Canteen.Entities;
/// <summary>
/// 用户余额表
/// </summary>
[SugarTable(TableName = "UserBalances", TableDescription = "用户余额表")]
public class UserBalanceEntity : SugarBaseEntity, IVersion
{
/// <summary>
/// 学工号
/// </summary>
[SugarColumn(IsNullable = false, ColumnDescription = "学工号", UniqueGroupNameList = new[] { "idx_UserBalances_useCode" })]
public string UserCode { get; set; }
/// <summary>
/// 余额
/// </summary>
[SugarColumn(IsNullable = false, ColumnDescription = "余额")]
public decimal Balance { get; set; }
/// <inheritdoc />
public int Version { get; set; }
}

View File

@@ -1,3 +1,4 @@
using Kurisu.AspNetCore.DataAccess.Entity;
using Kurisu.AspNetCore.DataAccess.SqlSugar;
using SqlSugar;
@@ -7,7 +8,7 @@ namespace Dlhis.Entity.Canteen.Entities;
/// 钱包
/// </summary>
[SugarTable(TableName = "Wallets", TableDescription = "钱包")]
public class WalletEntity : SugarBaseEntity
public class WalletEntity : SugarBaseEntity , ISoftDeleted
{
/// <summary>
/// 钱包编码
@@ -26,4 +27,7 @@ public class WalletEntity : SugarBaseEntity
/// </summary>
[SugarColumn(IsNullable = false, UniqueGroupNameList = new[] { "idx_wallets_factry" })]
public string Factory { get; set; }
/// <inheritdoc />
public bool IsDeleted { get; set; }
}