using APT.Infrastructure.Api;
using APT.Infrastructure.Utility;
using System;
using System.ComponentModel;
using APT.Infrastructure.Core;
using APT.BaseData.Domain.Entities.FM;
using APT.MS.Domain.Entities.PF;
using APT.BaseData.Domain.Entities.PF;
using System.Collections.Generic;

namespace APT.BaseData.Domain.Entities
{
    [Description("审批流子表")]
    public partial class T_PF_APPROVE_DETAIL : MesEntityBase
    {
        [DataFieldForeignKey("Nav_Approve", "Nav_ApproveDetails")]
        [Description("主表ID")]
        public Guid APPROVE_ID { get; set; }

        [Description("节点名称")]
        [FormFieldEdit]
        [FormFieldQuery]
        [FormFieldTable]
        [DataFieldLength(50)]
        public string NAME { get; set; }

        [FormFieldEdit]
        [DataFieldLength(10)]
        [Description("顺序")]
        public int NUM { get; set; }

        [DataFieldForeignKey("Nav_ApproveUser")]
        [Description("审批用户")]
        [FormFieldEdit]
        public Guid? APPROVE_USER_ID { get; set; }

        [Description("审批状态")]
        [FormFieldQuery]
        [FormFieldTable]
        [EnumName("NodeApproveStatus")]
        public int NODE_APPROVE_STATUS { get; set; } = 0;

        [Description("审批时间")]
        public DateTime NODE_APPROVE_TIME { get; set; }

        [Description("审批内容")]
        [DataFieldLength(100)]
        public string CONTEXT { get; set; }

        [Description("是否当前审批节点")]
        public bool IS_CURRENT { get; set; }

        [Description("导航：审批主表")]

        public T_PF_APPROVE Nav_Approve { get; set; }


        [Description("导航：审批用户")]

        public T_FM_USER Nav_ApproveUser { get; set; }

        [Description("是否允许修改审批人")]
        public bool IS_ALLOW_UPDATE { get; set; }

        [DataFieldForeignKey("Nav_ApproveRole")]
        [Description("审批角色")]
        [FormFieldEdit]
        public Guid? APPROVE_ROLE_ID { get; set; }

        [Description("导航属性：审批角色")]
        public virtual T_PF_APPROVAL_ROLE Nav_ApproveRole { get; set; }


        /// <summary>
        /// 是否取消
        /// </summary>
        [Description("是否取消")]
        public bool ISCANCEL { get; set; }
    }
}
