using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace RB_MES_API.Models
{
///
/// 系统文件,包含各种参数定义
///
public class SystemProfile
{
///
/// 自增ID,非主键
///
public int FID { get; set; }
///
/// 主键之一
///
[Required]
[DisplayName("模块分类")]
public int FCategoryID { get; set; } //来源于枚举 ModelGroup
///
/// 主键之一
///
[Required]
[DisplayName("关键字")]
public string FKey { get; set; } = string.Empty;
///
/// 内容格式转换参考FFormatID,如果是子窗体,参数值需要在调用后再计算
///
[DisplayName("参数值")]
[StringLength(200)]
public string FValue { get; set; } = string.Empty;
///
/// 某些参数一经设置不能修改,或者部分由开发人员设计的不能被修改
///
[DisplayName("是否只读")]
public bool FReadonly { get; set; } = false;
///
/// 一些便于用于使用的说明
///
[DisplayName("参数/参数值描述")]
public string FDescription { get; set; } = string.Empty;
///
/// 对主键的翻译
///
[DisplayName("参数名")]
[StringLength(200)]
public string FName { get; set; } = string.Empty;
///
/// 显示分组
///
[DisplayName("级次")]
public int FLevel { get; set; }=1;
///
/// 直接上级ID
///
[DisplayName("上级ID")]
public int FParentID { get; set; }=0;
///
/// 决定展示时控件的逻辑
///
[DisplayName("显示类型")]
public int FFormatID { get; set; } = 1; //来源于枚举 CellViewType
///
/// 只有明细,FReadonly才可能为True
///
[DisplayName("是否明细")]
public bool FDetail { get; set; } = true;
}
}