设备管理模块Entity添加和controller

This commit is contained in:
2026-08-28 10:40:28 +08:00
parent 9b852e5c95
commit 3e3341dd19
11 changed files with 994 additions and 8 deletions
@@ -0,0 +1,55 @@
using SqlSugar;
namespace Model.Entity.Asset
{
/// <summary>
/// 设备附件(资产附件管理:文件上传,支持按文件类型筛选与预览)
/// </summary>
public class EquipmentAttachmentEntity : BaseEntity
{
/// <summary>
/// 设备Id(关联 EquipmentEntity.Id
/// </summary>
public long EquipmentId { get; set; }
/// <summary>
/// 文件名称
/// </summary>
[SugarColumn(Length = 200)]
public string? FileName { get; set; }
/// <summary>
/// 文件类型(使用说明书/合格证明/校准证书/保养卡/合同扫描件/验收照片等)
/// </summary>
public AttachmentTypeEnum FileType { get; set; }
/// <summary>
/// 文件扩展名(如 .pdf、.jpg
/// </summary>
[SugarColumn(Length = 20)]
public string? FileExt { get; set; }
/// <summary>
/// 文件存储地址(上传后存储的相对路径)
/// </summary>
[SugarColumn(Length = 200)]
public string? FileUrl { get; set; }
/// <summary>
/// 文件大小(字节)
/// </summary>
public long FileSize { get; set; }
/// <summary>
/// 上传人
/// </summary>
[SugarColumn(Length = 50)]
public string? Uploader { get; set; }
/// <summary>
/// 备注
/// </summary>
[SugarColumn(Length = 500)]
public string? Remark { get; set; }
}
}