using IamService.Domain.SeedWork;

namespace IamService.Domain.Events;

/// <summary>
/// EN: Domain event raised when a new organization is created.
/// VI: Domain event được raise khi tổ chức mới được tạo.
/// </summary>
public class OrganizationCreatedEvent : IDomainEvent
{
    /// <summary>
    /// EN: The organization ID.
    /// VI: ID tổ chức.
    /// </summary>
    public Guid OrganizationId { get; }

    /// <summary>
    /// EN: The organization name.
    /// VI: Tên tổ chức.
    /// </summary>
    public string Name { get; }

    /// <summary>
    /// EN: The organization slug.
    /// VI: Slug tổ chức.
    /// </summary>
    public string Slug { get; }

    /// <summary>
    /// EN: When the event occurred.
    /// VI: Thời điểm sự kiện xảy ra.
    /// </summary>
    public DateTime OccurredOn { get; }

    public OrganizationCreatedEvent(Guid organizationId, string name, string slug)
    {
        OrganizationId = organizationId;
        Name = name;
        Slug = slug;
        OccurredOn = DateTime.UtcNow;
    }
}
