using SqlSugar; namespace Model.Entity.Asset { /// /// 设备台账(资产台账) /// public class EquipmentEntity : BaseEntity { #region 基础信息(设备信息录入) /// /// 设备编号(唯一) /// [SugarColumn(Length = 50, IsNullable = true)] public string? Code { get; set; } /// /// 设备名称 /// [SugarColumn(Length = 100, IsNullable = true)] public string? Name { get; set; } /// /// 设备分类Id(关联 EquipmentCategoryEntity.Id) /// public long CategoryId { get; set; } /// /// 设备类型(实验室/楼层/部门/位置/产品/自定义等分类维度下的类型名称,冗余便于展示) /// [SugarColumn(Length = 100, IsNullable = true)] public string? Type { get; set; } /// /// 设备品牌 /// [SugarColumn(Length = 100, IsNullable = true)] public string? Brand { get; set; } /// /// 设备型号 /// [SugarColumn(Length = 100, IsNullable = true)] public string? Model { get; set; } /// /// 规格参数 /// [SugarColumn(Length = 200, IsNullable = true)] public string? Specifications { get; set; } /// /// 制造商(设备制造商) /// [SugarColumn(Length = 100, IsNullable = true)] public string? Manufacturer { get; set; } /// /// 供应商(资产供应商) /// [SugarColumn(Length = 100, IsNullable = true)] public string? Supplier { get; set; } /// /// 设备图片地址(图片上传后存储的相对路径) /// [SugarColumn(Length = 200, IsNullable = true)] public string? ImageUrl { get; set; } /// /// 二维码编号(一物一码) /// [SugarColumn(Length = 50, IsNullable = true)] public string? QrCode { get; set; } /// /// 设备描述 /// [SugarColumn(ColumnDataType = "text", IsNullable = true)] public string? Description { get; set; } #endregion #region 权属与使用信息(设备分类管理:实验室/楼层/部门/位置) /// /// 使用部门名称(资产使用部门) /// [SugarColumn(Length = 100, IsNullable = true)] public string? Department { get; set; } /// /// 存放位置(实验室/楼层/房间等位置信息) /// [SugarColumn(Length = 200, IsNullable = true)] public string? Location { get; set; } /// /// 责任人(资产责任人) /// [SugarColumn(Length = 50, IsNullable = true)] public string? ResponsiblePerson { get; set; } /// /// 责任人联系电话(资产责任人电话) /// [SugarColumn(Length = 30, IsNullable = true)] public string? ContactPhone { get; set; } /// /// 保管人 /// [SugarColumn(Length = 50, IsNullable = true)] public string? Custodian { get; set; } #endregion #region 购置与财务信息(资产全生命周期:采购阶段) /// /// 购置日期 /// [SugarColumn(IsNullable = true)] public DateTime? PurchaseDate { get; set; } /// /// 购置价格(资产购置价格) /// [SugarColumn(DecimalDigits = 2, Length = 18, IsNullable = true)] public decimal? PurchasePrice { get; set; } /// /// 保修到期日期(资产保修到期) /// [SugarColumn(IsNullable = true)] public DateTime? WarrantyExpireDate { get; set; } #endregion #region 生命周期信息(资产全生命周期:验收/使用/报废阶段) /// /// 验收日期(资产验收日期) /// [SugarColumn(IsNullable = true)] public DateTime? AcceptanceDate { get; set; } /// /// 启用日期(资产启用日期) /// [SugarColumn(IsNullable = true)] public DateTime? EnableDate { get; set; } /// /// 使用年限(资产使用年限,单位:年) /// [SugarColumn(IsNullable = true)] public int? ServiceLifeYears { get; set; } /// /// 报废日期(资产报废日期) /// [SugarColumn(IsNullable = true)] public DateTime? ScrapDate { get; set; } #endregion #region 状态信息(设备状态管理:待验收→使用中→已借出→闲置→维修中→已停用→待处置→已处置→入库) /// /// 设备当前状态(状态流转记录见 EquipmentStatusRecordEntity) /// public EquipmentStatusEnum Status { get; set; } = EquipmentStatusEnum.PendingAcceptance; #endregion #region 合规信息(设备合规管理:校准/检定/保养) /// /// 校准状态(正常/超期) /// public ComplianceStatusEnum CalibrationStatus { get; set; } = ComplianceStatusEnum.Normal; /// /// 上次校准日期(校准日期) /// [SugarColumn(IsNullable = true)] public DateTime? LastCalibrationDate { get; set; } /// /// 下次校准到期日期(用于判断是否超期) /// [SugarColumn(IsNullable = true)] public DateTime? NextCalibrationDate { get; set; } /// /// 检定日期 /// [SugarColumn(IsNullable = true)] public DateTime? InspectionDate { get; set; } /// /// 下次检定到期日期(用于判断是否超期) /// [SugarColumn(IsNullable = true)] public DateTime? NextInspectionDate { get; set; } /// /// 保养状态(正常/超期) /// public ComplianceStatusEnum MaintenanceStatus { get; set; } = ComplianceStatusEnum.Normal; /// /// 上次保养日期(保养日期) /// [SugarColumn(IsNullable = true)] public DateTime? LastMaintenanceDate { get; set; } /// /// 下次保养到期日期(保养周期到期,用于判断是否超期) /// [SugarColumn(IsNullable = true)] public DateTime? NextMaintenanceDate { get; set; } #endregion #region 审计信息 /// /// 备注 /// [SugarColumn(Length = 500, IsNullable = true)] public string? Remark { get; set; } /// /// 创建人 /// [SugarColumn(Length = 50, IsNullable = true)] public string? CreateBy { get; set; } /// /// 更新人(修改人) /// [SugarColumn(Length = 50, IsNullable = true)] public string? UpdateBy { get; set; } /// /// 更新时间(修改时间) /// [SugarColumn(IsNullable = true)] public DateTime? UpdateTime { get; set; } #endregion } }