
using Microsoft.EntityFrameworkCore;
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace  Models
{

    /// <summary>
    /// 记录所有设备的信息列表，供配置工具调用   设备信息列表
    /// </summary>
    [Table("TBL_DEV_INFO"), Comment("设备信息列表 记录所有设备的信息列表，供配置工具调用")]

    public class TBL_DEV_INFO
    {
        /// <summary>
        /// 自增id
        /// </summary>
        [Key, Column(TypeName = "int"), Comment("id,自增长"), DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public int DEV_ID { get; set; }

        /// <summary>
        /// ERP对应的料号
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("ERP对应的料号 ")]
        public string ERP_PN { get; set; }


        /// <summary>
        /// 设备类型
        /// </summary>
        [Column(TypeName = "int"), Comment("设备类型 ")]
        public int DEV_TYPE { get; set; }


        /// <summary>
        /// 设备名称
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备名称 ")]
        public string DEV_NAME { get; set; }

        /// <summary>
        /// 设备类型数据编码
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备类型数据编码 ")]
        public string DEV_TYPE_DATA { get; set; }


        /// <summary>
        /// 设备协议
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备协议 ")]
        public string PROTOCOL { get; set; }

        /// <summary>
        /// 设备协议数据编码
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备协议数据编码 ")]
        public string PROTOCOL_DATA { get; set; }

        /// <summary>
        /// 协议版本
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("协议版本 ")]
        public string PROTOCOL_VER { get; set; }


        /// <summary>
        /// 设备接口类型
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备接口类型 ")]
        public string DEV_INTERFACE { get; set; }






        /// <summary>
        /// 设备厂牌
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备厂牌 ")]
        public string DEV_BRAND { get; set; }


        /// <summary>
        /// 设备型号
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备型号 ")]
        public string DEV_MN { get; set; }


        /// <summary>
        /// 设备详细描述
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备详细描述 ")]
        public string DEV_DESCRIPTION { get; set; }

        /// <summary>
        /// 数据模型（XML格式的文件） 
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("数据模型（XML格式的文件）  ")]
        public string DEV_DATA_MODEL { get; set; }


        /// <summary>
        /// 数据模型版本 
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("数据模型版本 ")]
        public string DEV_DATA_MODEL_VER { get; set; }

        /// <summary>
        /// 设备状态 
        /// </summary>
        [Column(TypeName = "int"), Comment("设备状态 ")]
        public int DEV_STATUS { get; set; }


        /// <summary>
        /// 设备单位 
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("设备单位 ")]
        public string DEV_UNIT { get; set; }



        /// <summary>
        /// 设备重量 
        /// </summary>
        [Column(TypeName = "int"), Comment("设备重量 ")]
        public int DEV_NET_WEIGHT { get; set; }


        /// <summary>
        /// 价格币种 
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("价格币种 ")]
        public string DEV_REF_PRICE_CURR { get; set; }

        /// <summary>
        /// 参考价格 
        /// </summary>
        [Column(TypeName = "decimal(18, 2)"), Comment("参考价格 ")]
        public decimal DEV_REF_PRICE { get; set; }


        /// <summary>
        /// 录入人 
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("录入人 ")]
        public string CREATE_BY { get; set; }


        /// <summary>
        /// 录入时间
        /// </summary>

        [Required, Column(TypeName = "datetime"), Comment("录入时间")]

        public DateTime CREATE_DATETIME { get; set; }



        /// <summary>
        /// 批准人 
        /// </summary>
        [Column(TypeName = "nvarchar(100)"), Comment("批准人 ")]
        public string APP_BY { get; set; }



        /// <summary>
        /// 批准时间
        /// </summary>

        [  Column(TypeName = "datetime"), Comment("批准时间")]

        public DateTime? APP_DATETIME { get; set; }


        /// <summary>
        /// 备注
        /// </summary>

        [Column(TypeName = "nvarchar(520)"), Comment("备注")]

        public string REMARK { get; set; }

    }
}
