using APT.BaseData.Domain.Entities;
using APT.Infrastructure.Core;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace APT.MS.Domain.Entities.PC
{
    /// <summary>
    /// 四色图 有序坐标点
    /// </summary>
    [Description("安全检查文件")]
    public class T_PC_INFO_COLOR : MesEntityBase
    {
        /// <summary>
        /// 名称
        /// </summary>
        [Description("名称")]
        [DataFieldLength(100)]
        public string NAME { get; set; }

        /// <summary>
        /// 图层
        /// </summary>
        [Description("图层")]
        public int ZNDEX { get; set; }

        /// <summary>
        /// 四色图配置信息
        /// </summary>
        [Description("四色图配置信息")]
        [DataFieldForeignKey("Nav_Info", "Nav_Colors")]
        public Guid INFO_ID { get; set; }

        /// <summary>
        /// 四色图配置信息
        /// </summary>
        [Description("四色图配置信息")]
        public T_PC_INFO Nav_Info { get; set; }

        /// <summary>
        /// 是否手动数据
        /// </summary>
        [Description("是否手动数据")]
        public bool ISDIY { get; set; } = false;

        /// <summary>
        /// 填充色 颜色 或者rgb  非手动的话 API得自助更新值
        /// </summary>
        [Description("填充色")]
        [FormFieldTable]
        [FormFieldEdit]
        [FormFieldQuery]
        public string RGBCOLOR { get; set; }

        /// <summary>
        /// 透明度（例：0.2）
        /// </summary>
        [Description("透明度")]
        [FormFieldTable]
        [FormFieldEdit]
        [FormFieldQuery]
        public decimal OPACITY { get; set; }

        /// <summary>
        /// 描述
        /// </summary>
        [Description("描述")]
        [DataFieldLength(350)]
        [FormFieldTable]
        [FormFieldEdit]
        [FormFieldQuery]
        public string DESCRIBE { get; set; }
        /// <summary>
        /// 描述
        /// </summary>
        [Description("描述")]
        [DataFieldIngore]
        public string DESCRIBE_TITLE { get; set; }


        /// <summary>
        /// 色块顺序
        /// </summary>
        [Description("色块顺序")]
        [FormFieldEdit]
        public int NUM { get; set; }

        /// <summary>
        /// 关联区域
        /// </summary>
        [Description("关联区域")]
        [FormFieldEdit]
        public virtual ICollection<T_PC_INFO_COLOR_AREA> Nav_Areas { get; set; }

        /// <summary>
        /// 色块有序坐标点
        /// </summary>
        [Description("色块有序坐标点")]
        [FormFieldEdit]
        public virtual ICollection<T_PC_INFO_COLOR_POINT> Nav_ColorPoints { get; set; }
    }
}
