using System;
using System.Collections.Generic;
using Lada.Framework.Data.Enums;
using Lada.Framework.DTO;
using Lada.Framework.Infrastructures.Helpers;
using Ladaer.BackEnd.Infrastructures.DTO.Items.Orders;

namespace Ladaer.BackEnd.Infrastructures.DTO.Items.DriverApp
{
    public class DriverOrderHistoryItem : BaseItem<int>
    {
        public string Code { get; set; }
        public int OrderId { get; set; }

        #region Thông tin Tài xế
        public string PickedupByUserName { get; set; }
        public string PickedupByFullName { get; set; }
        public string DeliveredByUserName { get; set; }
        public string DeliveredByFullName { get; set; }
        #endregion

        #region Thông tin Người gửi
        public string SenderName { get; set; }
        public string SenderPhone { get; set; }
        public string SenderAddress { get; set; }

        [System.Text.Json.Serialization.JsonIgnore]
        [Newtonsoft.Json.JsonIgnore]
        public List<Ladaer.BackEnd.Infrastructures.DTO.Items.Orders.OrderAddressItem> Addresses { get; set; }
        #endregion

        #region Thông tin Người nhận
        public string ReceiverName { get; set; }
        public string ReceiverPhone { get; set; }
        public string ReceiverAddress { get; set; }
        #endregion

        #region Thông tin Hàng hóa
        public string PackageContent { get; set; }
        public int TotalPackages { get; set; }
        public double TotalWeight { get; set; }

        [System.Text.Json.Serialization.JsonIgnore]
        [Newtonsoft.Json.JsonIgnore]
        public List<Ladaer.BackEnd.Infrastructures.DTO.Items.Orders.OrderPackageItem> Packages { get; set; }
        #endregion

        #region Thời gian
        public DateTimeOffset? PickupTime { get; set; }
        public DateTimeOffset? DeliveryDate { get; set; }
        #endregion

        #region Thông tin Tài chính
        public double TotalFee { get; set; }
        public double CollectAmount { get; set; }
        public OrderFinEnum.PayFeeType PayFeeType { get; set; }
        public string PayFeeTypeStr => PayFeeType.GetDescription();
        #endregion

        #region Trạng thái
        public OrderStatus OrderStatus { get; set; }
        public OrderPhysicalStatus OrderPhysicalStatus { get; set; }
        public string OrderStatusStr => OrderStatus.GetDescription();
        public string OrderPhysicalStatusStr => OrderPhysicalStatus.GetDescription();
        #endregion

        #region Hình ảnh liên quan
        public List<string> MediaUrls { get; set; } = new List<string>();
        #endregion
    }
}
