using DS.Module.Core;
using DS.Module.Core.Data;
using DS.Module.Core.Enums;
using DS.WMS.Core.Fee.Entity;
using DS.WMS.Core.Op.Entity;
using SqlSugar;
namespace DS.WMS.Core.Application.Entity
{
///
/// 费用相关申请明细
///
[SugarTable("application_detail", TableDescription = "费用相关申请明细")]
public class ApplicationDetail : BaseModelV2
{
///
/// 申请单ID
///
[SugarColumn(ColumnDescription = "申请单ID")]
public long ApplicationId { get; set; }
///
/// 业务ID
///
[SugarColumn(ColumnDescription = "业务ID")]
public long BusinessId { get; set; }
///
/// 业务类型
///
[SugarColumn(ColumnDescription = "业务类型")]
public BusinessType BusinessType { get; set; }
///
/// 费用记录ID
///
[SugarColumn(ColumnDescription = "费用记录ID")]
public long RecordId { get; set; }
///
/// 费用记录
///
[Navigate(NavigateType.OneToOne, nameof(RecordId))]
public FeeRecord? Record { get; set; }
///
/// 结算对象名称
///
[SugarColumn(ColumnDescription = "结算对象名称", Length = 200, IsNullable = true)]
public string? CustomerName { get; set; }
///
/// 收付类型(收、付) 1应收 2 应付
///
[SugarColumn(ColumnDescription = "收付类型(收、付)", DefaultValue = "1")]
public FeeType FeeType { get; set; }
///
/// 费用Id
///
[SugarColumn(ColumnDescription = "费用Id")]
public long FeeId { get; set; }
///
/// 费用名称
///
[SugarColumn(ColumnDescription = "费用名称", Length = 100, IsNullable = true)]
public string? FeeName { get; set; }
///
/// 类别(1-付费申请结算 2-收费自由结算 3-发票结算 4-收费申请 5-付费申请 6-发票申请 7-发票开出 8-付费自由结算 9-收费申请结算)
///
[SugarColumn(ColumnDescription = "类别", IsNullable = true)]
public FeeCategory? Category { get; set; }
///
/// 申请金额
///
[SugarColumn(ColumnDescription = "申请金额")]
public decimal ApplyAmount { get; set; }
///
/// 已处理金额
///
[SugarColumn(ColumnDescription = "已处理金额")]
public decimal ProcessedAmount { get; set; }
///
/// 币别
///
[SugarColumn(ColumnDescription = "币别", IsNullable = false, Length = 3)]
public string Currency { get; set; }
///
/// 折算汇率
///
[SugarColumn(ColumnDescription = "折算汇率", IsNullable = true)]
public decimal? ExchangeRate { get; set; }
///
/// 原始币别
///
[SugarColumn(ColumnDescription = "原始币别", IsNullable = false, Length = 3)]
public string OriginalCurrency { get; set; }
///
/// 原始申请金额
///
[SugarColumn(ColumnDescription = "原始申请金额")]
public decimal OriginalAmount { get; set; }
///
/// 原始已处理金额
///
[SugarColumn(ColumnDescription = "原始已处理金额")]
public decimal OriginalProcessedAmount { get; set; }
}
}