namespace Model.Dto.System { /// /// 文件存储配置 DTO /// public class FileStorageConfigDto { public string Id { get; set; } public string Provider { get; set; } public string Name { get; set; } public string? Endpoint { get; set; } /// 回显时掩码(仅显示前后各 2 字符);写入时若为掩码样式则保留原值不变 public string? AccessKey { get; set; } public string? SecretKey { get; set; } public string? Bucket { get; set; } public string? Region { get; set; } public string? BasePath { get; set; } public int MaxSizeMB { get; set; } public string? AllowedExts { get; set; } public byte IsDefault { get; set; } public byte Status { get; set; } public string? Remark { get; set; } public DateTime? CreateTime { get; set; } } /// /// 文件上传记录 DTO /// public class FileRecordDto { public string Id { get; set; } public string FileName { get; set; } public string? OriginalName { get; set; } public string? Url { get; set; } public long Size { get; set; } public string? Ext { get; set; } public string? Provider { get; set; } public string StorageId { get; set; } public string? Uploader { get; set; } public string? BizType { get; set; } public string? BizId { get; set; } public DateTime? CreateTime { get; set; } } /// /// 上传结果(Provider 返回,Service 写入 sys_file_record 时用) /// public class FileUploadResultDto { /// 存储后的相对文件名(含路径,如 2026/09/18/snowflake.jpg) public string FileName { get; set; } /// 访问 URL public string Url { get; set; } /// 扩展名 public string? Ext { get; set; } /// 文件大小(字节) public long Size { get; set; } public string Provider { get; set; } } }