/*
 * File: D:\shadowed-realms-mobile\ShadowedRealmsMobile\src\server\ShadowedRealms.Shared\DTOs\Alliance\AllianceVotingRequestDto.cs
 * Created: 2025-10-22
 * Last Modified: 2025-10-22
 * Description: Request DTO for alliance voting operations and ballot creation
 * Last Edit Notes: Initial creation following established Alliance DTO patterns
 */

using System.ComponentModel.DataAnnotations;

namespace ShadowedRealms.Shared.DTOs.Alliance
{
    /// <summary>
    /// Request DTO for alliance voting operations and ballot creation
    /// </summary>
    public class AllianceVotingRequestDto
    {
        /// <summary>
        /// Vote action (CreateVote, CastVote, ModifyVote, CancelVote)
        /// </summary>
        [Required]
        [StringLength(50)]
        public string Action { get; set; } = string.Empty;

        /// <summary>
        /// Subject of the vote
        /// </summary>
        [Required]
        [StringLength(200)]
        public string VoteSubject { get; set; } = string.Empty;

        /// <summary>
        /// Type of vote (Policy, Leadership, War, Alliance, Coalition)
        /// </summary>
        [Required]
        [StringLength(50)]
        public string VoteType { get; set; } = string.Empty;

        /// <summary>
        /// Available voting options
        /// </summary>
        public List<string> VotingOptions { get; set; } = new();

        /// <summary>
        /// Vote choice (for casting votes)
        /// </summary>
        public int? VoteChoice { get; set; }

        /// <summary>
        /// Detailed description of the vote
        /// </summary>
        [StringLength(2000)]
        public string? VoteDescription { get; set; }

        /// <summary>
        /// Voting duration in hours
        /// </summary>
        [Range(24, 168)]
        public int VotingDurationHours { get; set; } = 48;

        /// <summary>
        /// Minimum participation required (percentage)
        /// </summary>
        [Range(25, 100)]
        public int MinimumParticipation { get; set; } = 50;

        /// <summary>
        /// Roles eligible to vote
        /// </summary>
        public List<string> EligibleRoles { get; set; } = new();

        /// <summary>
        /// Vote parameters and special conditions
        /// </summary>
        public Dictionary<string, object>? VoteParameters { get; set; }
    }
}