feat: update commission status handling and UI; enhance status representation with computed properties and improve filtering logic
Build and Deploy / build (push) Successful in 2m20s
Build and Deploy / build (push) Successful in 2m20s
This commit is contained in:
@@ -13,9 +13,31 @@ public class CommissionPayoutDto
|
||||
public int BalancesEarned { get; set; }
|
||||
public long TotalAmount { get; set; }
|
||||
public string AmountFormatted { get; set; } = string.Empty;
|
||||
public string Status { get; set; } = string.Empty;
|
||||
public string StatusBadgeColor { get; set; } = string.Empty;
|
||||
public int Status { get; set; }
|
||||
public string DatePersian { get; set; } = string.Empty;
|
||||
|
||||
// Computed properties for UI
|
||||
public string StatusText => Status switch
|
||||
{
|
||||
0 => "در انتظار",
|
||||
1 => "پرداخت شده",
|
||||
2 => "درخواست برداشت",
|
||||
3 => "برداشت شده",
|
||||
4 => "شکست خورده",
|
||||
5 => "لغو شده",
|
||||
_ => "نامشخص"
|
||||
};
|
||||
|
||||
public string StatusColor => Status switch
|
||||
{
|
||||
0 => "warning",
|
||||
1 => "success",
|
||||
2 => "info",
|
||||
3 => "success",
|
||||
4 => "error",
|
||||
5 => "default",
|
||||
_ => "default"
|
||||
};
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user