namespace CMSMicroservice.Application.NetworkMembershipCQ.Queries.GetNetworkStatistics;
public class GetNetworkStatisticsResponseDto
{
/// مجموع اعضای فعال باشگاه در پای چپ و راست (= LeftLegCount + RightLegCount)
public int TotalMembers { get; set; }
/// همان TotalMembers — اعضای فعال باشگاه در شبکه کاربر
public int ActiveMembers { get; set; }
/// تعداد اعضای فعال باشگاه در زیردرخت پای چپ
public int LeftLegCount { get; set; }
/// تعداد اعضای فعال باشگاه در زیردرخت پای راست
public int RightLegCount { get; set; }
public double LeftPercentage { get; set; }
public double RightPercentage { get; set; }
public double AverageDepth { get; set; }
public int MaxDepth { get; set; }
public List LevelDistribution { get; set; } = new();
public List MonthlyGrowth { get; set; } = new();
public List TopUsers { get; set; } = new();
/// تعداد اعضای فعال باشگاه با پکیج طلایی جاری در پای چپ
public int GoldLeftLegTotal { get; set; }
/// تعداد اعضای فعال باشگاه با پکیج طلایی جاری در پای راست
public int GoldRightLegTotal { get; set; }
/// تعداد اعضای فعال باشگاه با پکیج نقرهای جاری در پای چپ
public int SilverLeftLegTotal { get; set; }
/// تعداد اعضای فعال باشگاه با پکیج نقرهای جاری در پای راست
public int SilverRightLegTotal { get; set; }
public string WeakerLeg => LeftLegCount <= RightLegCount ? "Left" : "Right";
}
public class LevelDistributionModel
{
public int Level { get; set; }
public int Count { get; set; }
}
public class MonthlyGrowthModel
{
public string Month { get; set; } = string.Empty;
public int NewMembers { get; set; }
}
public class TopNetworkUserModel
{
public int Rank { get; set; }
public long UserId { get; set; }
public string UserName { get; set; } = string.Empty;
public int TotalChildren { get; set; }
public int LeftCount { get; set; }
public int RightCount { get; set; }
}