using Lada.Framework.Data.Domains.BaseEntities;
using Lada.Framework.Data.Domains.Medias;
using Lada.Framework.Data.Enums;

namespace Lada.Framework.Data.Domains.Trucks;

/// <summary>
/// Liên kết giữa Truck và Media (ảnh đăng ký, đăng kiểm)
/// </summary>
public class TruckMedia : BaseEntityWithKey<int>
{
    /// <summary>
    /// ID xe tải
    /// </summary>
    public int TruckId { get; set; }

    /// <summary>
    /// ID media
    /// </summary>
    public Guid MediaId { get; set; }

    /// <summary>
    /// Loại media (RegistrationPhoto, InspectionPhoto)
    /// </summary>
    public TruckMediaType MediaType { get; set; }

    /// <summary>
    /// Thứ tự hiển thị
    /// </summary>
    public int DisplayOrder { get; set; }

    #region Navigation Properties

    /// <summary>
    /// Xe tải
    /// </summary>
    public virtual Truck Truck { get; set; } = null!;

    /// <summary>
    /// Media
    /// </summary>
    public virtual Media Media { get; set; } = null!;

    #endregion
}
