1. 重构用户、宠物模板、勋章、管理员状态更新接口,移除冗余参数改为自动切换状态 2. 重命名宠物背景枚举为宠物皮肤,调整商品状态字段为枚举类型 3. 新增商品上下架状态管理接口与对应逻辑 4. 新增勋章规则配置系统,支持动态加载可用表和字段 5. 优化商品查询与展示逻辑,适配新的状态字段
74 lines
1.8 KiB
C#
74 lines
1.8 KiB
C#
using SqlSugar;
|
|
using QYZH.InteractiveMagazine.Models.Enum;
|
|
|
|
namespace QYZH.InteractiveMagazine.Models.Entity
|
|
{
|
|
///<summary>
|
|
///虚拟商品表
|
|
///</summary>
|
|
[SugarTable("Product")]
|
|
public partial class Product : SqlSugarBaseEntity
|
|
{
|
|
public Product(){
|
|
|
|
|
|
}
|
|
|
|
/// <summary>
|
|
/// Desc:商品名称
|
|
/// Default:
|
|
/// Nullable:False
|
|
/// </summary>
|
|
public string Name {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:描述
|
|
/// Default:
|
|
/// Nullable:True
|
|
/// </summary>
|
|
public string Description {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:商品图片
|
|
/// Default:
|
|
/// Nullable:True
|
|
/// </summary>
|
|
public string ImageUrl {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:所需积分
|
|
/// Default:
|
|
/// Nullable:False
|
|
/// </summary>
|
|
public int Price {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:商品类型: MakeUpCard, PetBg
|
|
/// Default:
|
|
/// Nullable:False
|
|
/// </summary>
|
|
public ProductTypeEnum Type {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:扩展数据
|
|
/// Default:
|
|
/// Nullable:True
|
|
/// </summary>
|
|
public string MetaData {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:是否上架
|
|
/// Default:b'1'
|
|
/// Nullable:False
|
|
/// </summary>
|
|
public bool IsActive {get;set;}
|
|
|
|
/// <summary>
|
|
/// Desc:库存(-1无限)
|
|
/// Default:-1
|
|
/// Nullable:False
|
|
/// </summary>
|
|
public int Stock {get;set;}
|
|
}
|
|
}
|