135 lines
3.4 KiB
C#
135 lines
3.4 KiB
C#
using System;
|
|
|
|
namespace Zxd.Entity.Zxd
|
|
{
|
|
[Table("t_finished_product")]
|
|
public class FinishedProduct
|
|
{
|
|
public FinishedProduct()
|
|
{
|
|
}
|
|
|
|
[Key]
|
|
public int Id { get; set; }
|
|
|
|
[Column("standard_product_id")]
|
|
public int StandardProductId { get; set; }
|
|
|
|
[Column("product_type_id")]
|
|
public int ProductTypeId { get; set; }
|
|
|
|
[Column("product_series_id")]
|
|
public int ProductSeriesId { get; set; }
|
|
|
|
[Column("product_category_id")]
|
|
public int ProductCategoryId { get; set; }
|
|
|
|
[Column("product_code")]
|
|
public string? ProductCode { get; set; }
|
|
|
|
[Column("product_name")]
|
|
public string? ProductName { get; set; }
|
|
|
|
[Column("deptid")]
|
|
public int Deptid { get; set; }
|
|
|
|
[Column("product_price")]
|
|
public decimal ProducPrice { get; set; }
|
|
|
|
public string? Day { get; set; }
|
|
|
|
public int Coefficient { get; set; }
|
|
|
|
[Column("product_server_type")]
|
|
public ProductServerType ProductServerType { get; set; }
|
|
|
|
[Column("auto_open")]
|
|
public bool AutoOpen { get; set; }
|
|
|
|
[Column("open_coendition")]
|
|
public int OpenCondition { get; set; }
|
|
|
|
[Column("status")]
|
|
public ProductStatus Status { get; set; }
|
|
|
|
[Column("give")]
|
|
public bool Give { get; set; }
|
|
|
|
[Column("discount")]
|
|
public bool Discount { get; set; }
|
|
|
|
public bool Custom { get; set; }
|
|
|
|
[Column("discoun_sections")]
|
|
public string? DiscounSections { get; set; }
|
|
|
|
[Column("give_products")]
|
|
public string? GiveProducts { get; set; }
|
|
|
|
[Column("custom_prices")]
|
|
public string? CustomPrices { get; set; }
|
|
|
|
[Column("upgrade")]
|
|
public bool Upgrade { get; set; }
|
|
|
|
[Column("other_classify")]
|
|
public bool OtherClassify { get; set; }
|
|
|
|
[Column("buy_online")]
|
|
public bool BuyOnline { get; set; }
|
|
|
|
public string? Remark { get; set; }
|
|
|
|
public string? Module { get; set; }
|
|
|
|
public virtual StandardProduct? StandardProduct { get; set; }
|
|
|
|
[NotMapped]
|
|
public List<FinishedGiveProduct>? GiveProductList
|
|
{
|
|
get
|
|
{
|
|
return string.IsNullOrEmpty(GiveProducts) ? null
|
|
: JsonSerializer.Deserialize<List<FinishedGiveProduct>>(GiveProducts);
|
|
}
|
|
}
|
|
|
|
[NotMapped]
|
|
public List<string>? DiscounSectionList
|
|
{
|
|
get
|
|
{
|
|
return string.IsNullOrEmpty(DiscounSections) ? null
|
|
: JsonSerializer.Deserialize<List<string>>(DiscounSections);
|
|
}
|
|
}
|
|
|
|
[NotMapped]
|
|
public List<FinishedCustomPrice>? CustomPriceList
|
|
{
|
|
get
|
|
{
|
|
return string.IsNullOrEmpty(CustomPrices) ? null
|
|
: JsonSerializer.Deserialize<List<FinishedCustomPrice>>(CustomPrices);
|
|
}
|
|
}
|
|
}
|
|
|
|
public class FinishedGiveProduct
|
|
{
|
|
public string? ProductCode { get; set; }
|
|
|
|
public bool? OrderPaymentPresenter { get; set; }
|
|
|
|
public bool? AfterPaymentPresenter { get; set; }
|
|
|
|
public int? Sort { get; set; }
|
|
}
|
|
|
|
public class FinishedCustomPrice
|
|
{
|
|
public decimal? Max { get; set; }
|
|
|
|
public decimal? Min { get; set; }
|
|
}
|
|
} |