campus-errand/server/Models/Dtos/EarningDtos.cs
2026-03-01 05:01:47 +08:00

69 lines
2.0 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System.ComponentModel.DataAnnotations;
namespace CampusErrand.Models.Dtos;
/// <summary>
/// 收益概览响应
/// </summary>
public class EarningsOverviewResponse
{
/// <summary>冻结中金额</summary>
public decimal FrozenAmount { get; set; }
/// <summary>待提现金额</summary>
public decimal AvailableAmount { get; set; }
/// <summary>提现中金额</summary>
public decimal WithdrawingAmount { get; set; }
/// <summary>已提现金额</summary>
public decimal WithdrawnAmount { get; set; }
}
/// <summary>
/// 收益记录响应
/// </summary>
public class EarningRecordResponse
{
public int Id { get; set; }
public int OrderId { get; set; }
public string OrderNo { get; set; } = string.Empty;
public string OrderType { get; set; } = string.Empty;
public decimal? GoodsAmount { get; set; }
public decimal Commission { get; set; }
public decimal PlatformFee { get; set; }
public decimal NetEarning { get; set; }
public string Status { get; set; } = string.Empty;
public DateTime? CompletedAt { get; set; }
public DateTime CreatedAt { get; set; }
}
/// <summary>
/// 提现记录响应
/// </summary>
public class WithdrawalRecordResponse
{
public int Id { get; set; }
public decimal Amount { get; set; }
public string PaymentMethod { get; set; } = string.Empty;
public string Status { get; set; } = string.Empty;
public DateTime CreatedAt { get; set; }
}
/// <summary>
/// 申请提现请求
/// </summary>
public class WithdrawRequest
{
/// <summary>提现金额(最低 1 元,小数点后最多 2 位)</summary>
public decimal Amount { get; set; }
/// <summary>收款方式WeChat 或 Alipay</summary>
[Required(ErrorMessage = "收款方式不能为空")]
public string PaymentMethod { get; set; } = string.Empty;
/// <summary>收款二维码图片</summary>
[Required(ErrorMessage = "收款二维码不能为空")]
public string QrCodeImage { get; set; } = string.Empty;
}