using Hotline.Share.Requests;
using Hotline.Share.Tools;
using System.ComponentModel.DataAnnotations;

namespace Hotline.Share.Dtos.Snapshot;
public class SnapshotUserInfoOutDto
{
    /// <summary>
    /// 电话号码
    /// </summary>
    public string PhoneNumber { get; set; }

    /// <summary>
    /// 电话号码脱敏
    /// </summary>
    public string PhoneNumberMask => PhoneNumber.MaskPhoneNumber();

    /// <summary>
    /// 当日奖励(单位:元)
    /// </summary>
    public double DayAmount { get; set; }

    /// <summary>
    /// 当日奖励(单位:元)
    /// </summary>
    public string DayAmountTxt => DayAmount.ToYuanFinance();

    /// <summary>
    /// 总奖励(单位:元)
    /// </summary>
    public double TotalAmount { get; set; }

    /// <summary>
    /// 总奖励(单位:元)
    /// </summary>
    public string TotalAmountTxt => TotalAmount.ToYuanFinance();

    /// <summary>
    /// 未回复数量
    /// </summary>
    public int NoReplyCount { get; set; }

    /// <summary>
    /// 已回复数量
    /// </summary>
    public int ReplyCount { get; set; }

    /// <summary>
    /// 已评论
    /// </summary>
    public int AppraiseCount { get; set; }
}

public record CitizenRelationSafetyTypeInDto : PagedRequest
{
    /// <summary>
    /// 志愿者类型
    /// </summary>
    public string? SafetyTypeId { get; set; }

    /// <summary>
    /// 名字
    /// </summary>
    public string? Name { get; set; }

    /// <summary>
    /// 手机号码
    /// </summary>
    public string? PhoneNumber { get; set; }
}

public class CitizenRelationSafetyTypeOutDto
{
    /// <summary>
    /// Id
    /// </summary>
    public string CitizenId { get; set; }

    /// <summary>
    /// 用户名
    /// </summary>
    public string? CitizenName { get; set; }

    /// <summary>
    /// 志愿者类型名称
    /// </summary>
    public string SafetyTypeName { get; set; }

    /// <summary>
    /// id
    /// </summary>
    public string SafetyTypeId { get; set; }

    /// <summary>
    /// 电话号码
    /// </summary>
    public string PhoneNumber { get; set; }
}

public class AddCitizenRelationSafetyTypeInDto
{
    /// <summary>
    /// 志愿者类型
    /// </summary>
    [Required(ErrorMessage = "请选择志愿者类型")]
    public string SafetyTypeId { get; set; }

    /// <summary>
    /// 市民Id
    /// </summary>
    [Required]
    public IList<string> CitizenIds { get; set; }
}


public class DeleteCitizenRelationSafetyTypeInDto
{
    /// <summary>
    /// 市民和志愿者类型集合
    /// </summary>
    public IList<CitizenIdRelationSafetyTypeId> Items { get; set; }
}

public class CitizenIdRelationSafetyTypeId
{
    /// <summary>
    /// 市民Id
    /// </summary>
    [Required]
    public string CitizenId { get; set; }

    /// <summary>
    /// 志愿者类型Id
    /// </summary>
    public string SafetyTypeId { get; set; }
}

public record GetThirdCitizenInDto : PagedRequest
{
    /// <summary>
    /// 志愿者类型Id
    /// </summary>
    public string? SafetyTypeId { get; set; }

    /// <summary>
    /// 电话号码
    /// </summary>
    public string? PhoneNumber { get; set; }
}

public class GetThirdCitizenOutDto
{
    /// <summary>
    /// Id
    /// </summary>
    public string CitizenId { get; set; }

    /// <summary>
    /// Name
    /// </summary>
    public string Name { get; set; }

    /// <summary>
    /// 电话
    /// </summary>
    public string PhoneNumber { get; set; }
}
