campus-errand/server/Models/Dtos/EarningDtos.cs
18631081161 681d2b5fe8
All checks were successful
continuous-integration/drone/push Build is passing
提现
2026-04-02 16:55:18 +08:00

75 lines
2.1 KiB
C#
Raw Permalink 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>
public class AdminWithdrawalRequest
{
/// <summary>操作approve通过、reject拒绝、processing处理中</summary>
[Required(ErrorMessage = "操作类型不能为空")]
public string Action { get; set; } = string.Empty;
}