using System.ComponentModel.DataAnnotations;
namespace RB_MES_API.Models.Cloud
{
    /// <summary>
    /// 生产挪料单
    /// </summary>
    public class PRD_MOVEMTRL
    {
        /// <summary>
        /// 实体主键（无需填写，保存时自动添加）
        /// </summary>
        public int FID { get; set; } 
        /// <summary>
        /// 单据编号   
        /// </summary>
        [StringLength(36)]
        public string FBillNo { get; set; } 
        /// <summary>
        /// 单据类型   (必填项)
        /// </summary>
        public Dictionary<string, string> FBillType { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
        /// <summary>
        /// 单据日期  (必填项)
        /// </summary>
        public DateTime FDate { get; set; }
        /// <summary>
        /// 生产组织   (必填项)
        /// </summary>
        public Dictionary<string, string> FPrdOrgId { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
        /// <summary>
        /// 生产车间   
        /// </summary>
        public Dictionary<string, string> FWORKSHOPID { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
        /// <summary>
        /// 业务类型     (必填项）
        /// </summary>
        [StringLength(36)]
        public string FBUSINESSTYPE { get; set; } 
        /// <summary>
        /// 转出类型    (必填项）
        /// </summary>
        [StringLength(36)]
        public string FMOVEOUTTYPE { get; set; } 
        /// <summary>
        /// 转入类型    (必填项）
        /// </summary>
        [StringLength(36)]
        public string FMOVEINTYPE { get; set; } 
        /// <summary>
        /// 单据状态    (必填项）
        /// </summary>
        [StringLength(36)]
        public string FDocumentStatus { get; set; } 
        /// <summary>
        /// 备注    
        /// </summary>
        [StringLength(36)]
        public string FDescription { get; set; } 
        /// <summary>
        /// 挪料套数        
        /// </summary>
        public int FMOVESETQTY { get; set; }
        /// <summary>
        /// 中转仓库   (必填项)   
        /// </summary>
        public Dictionary<string, string> FStockId { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
        /// <summary>
        /// 中转仓位     
        /// </summary>
        public class FStockLocId 
        {
            public Dictionary<string, string> FSTOCKLOCID__FF100001 { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
            public Dictionary<string, string> FSTOCKLOCID__FF100002 { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
        }

        public List<FEntity> Entity { get; set; } = new List<FEntity>();
        /// <summary>
        /// 子项明细
        /// </summary>
        public class FEntity
        {
            /// <summary>
            /// 实体主键（无需填写，保存时自动添加）
            /// </summary>
            public int FEntryID { get; set; } 
            /// <summary>
            /// 行类型    
            /// </summary>
            [StringLength(36)]
            public string FROWTYPE { get; set; } 
            /// <summary>
            /// 生产订单    (必填项)   
            /// </summary>
            [StringLength(36)]
            public string FMOBILLNO { get; set; }
            /// <summary>
            /// 行号
            /// </summary>
            public int FMOENTRYSEQ { get; set; } 
            /// <summary>
            /// 产品编码   
            /// </summary>
            public Dictionary<string, string> FMATERIALID { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
            /// <summary>
            /// 子项编码   
            /// </summary>
            public Dictionary<string, string> FMATERIALCHILDID { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
            /// <summary>
            /// 子项单位   
            /// </summary>
            public Dictionary<string, string> FUnitID { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
            /// <summary>
            /// 应发数量
            /// </summary>
            public int FMUSTQTY { get; set; }
            /// <summary>
            /// 已领数量
            /// </summary>
            public int FPICKEDQTY { get; set; } 
            /// <summary>
            /// 退料数量
            /// </summary>
            public int FRETURNQTY { get; set; } 
            /// <summary>
            /// 在制材料数量
            /// </summary>
            public int FWIPQTY { get; set; }
            /// <summary>
            /// 可挪料数量
            /// </summary>
            public int FCANMOVEQTY { get; set; } 
            /// <summary>
            /// 挪料数量    
            /// </summary>
            public int FMOVEQTY { get; set; } 
            /// <summary>
            /// 生产订单内码
            /// </summary>
            public int FMOID { get; set; } 
            /// <summary>
            /// 生产订单分录内码
            /// </summary>
            public int FMOENTRYID { get; set; } 
            /// <summary>
            /// 生产用料清单编号    
            /// </summary>
            [StringLength(36)]
            public string FPPBOMBILLNO { get; set; } 
            /// <summary>
            /// 生产用料清单内码
            /// </summary>
            public int FPPBOMID { get; set; }
            /// <summary>
            /// 生产用料清单分录内码
            /// </summary>
            public int FPPBOMENTRYID { get; set; }
            /// <summary>
            /// 生产用料清单分录行号
            /// </summary>
            public int FPPBOMENTRYSEQ { get; set; } 
            /// <summary>
            /// 生产领料单编号    
            /// </summary>
            [StringLength(36)]
            public string FPICKBILLNO { get; set; } 
            /// <summary>
            /// 生产领料单内码
            /// </summary>
            public int FPICKMTRLID { get; set; } 
            /// <summary>
            /// 生产退料单编号    
            /// </summary>
            [StringLength(36)]
            public string FRETURNBILLNO { get; set; }
            /// <summary>
            /// 生产退料单内码
            /// </summary>
            public int FRETURNMTRLID { get; set; } 
            /// <summary>
            /// 基本单位   
            /// </summary>
            public Dictionary<string, string> FBASEUNITID { get; set; } = new Dictionary<string, string>() {
            { "FNUMBER",""}
        };
            /// <summary>
            /// 基本单位应发数量
            /// </summary>
            public int FBASEMUSTQTY { get; set; } 
            /// <summary>
            /// 基本单位已领数量
            /// </summary>
            public int FBASEPICKEDQTY { get; set; } 
            /// <summary>
            /// 基本单位在制材料数量
            /// </summary>
            public int FBASEWIPQTY { get; set; } 
            /// <summary>
            /// 基本单位可挪料数量
            /// </summary>
            public int FBASECANMOVEQTY { get; set; } 
            /// <summary>
            /// 生产退料单行号    
            /// </summary>
            [StringLength(36)]
            public string FRETURNENTRYSEQ { get; set; } 
            /// <summary>
            /// 基本单位挪料数量
            /// </summary>
            public int FBASEMOVEQTY { get; set; } 
            /// <summary>
            /// 生产领料单行号    
            /// </summary>
            [StringLength(36)]
            public string FPICKENTRYSEQ { get; set; } 
            /// <summary>
            /// 父极行主键    
            /// </summary>
            [StringLength(36)]
            public string FPARENTROWID { get; set; } 
            /// <summary>
            /// 转入超发控制    
            /// </summary>
            [StringLength(36)]
            public string FOverControlMode { get; set; } 
            /// <summary>
            /// 行标识    
            /// </summary>
            [StringLength(36)]
            public string FROWID { get; set; } 
            /// <summary>
            /// 源单类型    
            /// </summary>
            [StringLength(36)]
            public string FSourceBillType { get; set; } 
            /// <summary>
            /// 源单编号    
            /// </summary>
            [StringLength(36)]
            public string FSourceBillNo { get; set; } 
        }
    }
}
