mirror of
https://github.com/DrizzleTime/Foxel.git
synced 2026-06-01 13:40:22 +08:00
Initial commit
This commit is contained in:
17
Models/BaseResult.cs
Normal file
17
Models/BaseResult.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
namespace Foxel.Models;
|
||||
|
||||
public class BaseResult<T>
|
||||
{
|
||||
public string Message { get; set; } = string.Empty;
|
||||
public bool Success { get; set; } = true;
|
||||
public T? Data { get; set; }
|
||||
public int StatusCode { get; set; } = 200;
|
||||
}
|
||||
|
||||
public class BaseResult
|
||||
{
|
||||
public string Message { get; set; } = string.Empty;
|
||||
public bool Success { get; set; } = true;
|
||||
public int Data { get; set; }
|
||||
public int StatusCode { get; set; } = 200;
|
||||
}
|
||||
18
Models/DataBase/Album.cs
Normal file
18
Models/DataBase/Album.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class Album : BaseModel
|
||||
{
|
||||
[Required]
|
||||
[StringLength(100)]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(500)]
|
||||
public string Description { get; set; } = string.Empty;
|
||||
public int UserId { get; set; }
|
||||
[Required]
|
||||
public User User { get; set; }
|
||||
|
||||
public ICollection<Picture>? Pictures { get; set; }
|
||||
}
|
||||
12
Models/DataBase/AlbumPicture.cs
Normal file
12
Models/DataBase/AlbumPicture.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class AlbumPicture
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public int AlbumId { get; set; }
|
||||
public int PictureId { get; set; }
|
||||
|
||||
// 导航属性
|
||||
public Album? Album { get; set; }
|
||||
public Picture? Picture { get; set; }
|
||||
}
|
||||
12
Models/DataBase/BaseModel.cs
Normal file
12
Models/DataBase/BaseModel.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public abstract class BaseModel
|
||||
{
|
||||
[Key] public int Id { get; set; }
|
||||
|
||||
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
||||
|
||||
public DateTime UpdatedAt { get; set; } = DateTime.UtcNow;
|
||||
}
|
||||
17
Models/DataBase/Config.cs
Normal file
17
Models/DataBase/Config.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class Config : BaseModel
|
||||
{
|
||||
[Required]
|
||||
[StringLength(50)]
|
||||
public string Key { get; set; } = string.Empty;
|
||||
|
||||
[Required]
|
||||
[StringLength(255)]
|
||||
public string Value { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(255)]
|
||||
public string Description { get; set; } = string.Empty;
|
||||
}
|
||||
18
Models/DataBase/Favorite.cs
Normal file
18
Models/DataBase/Favorite.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class Favorite
|
||||
{
|
||||
[Key]
|
||||
public int Id { get; set; }
|
||||
|
||||
public User User { get; set; }
|
||||
|
||||
public int PictureId { get; set; }
|
||||
[ForeignKey("PictureId")]
|
||||
public Picture Picture { get; set; }
|
||||
|
||||
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
||||
}
|
||||
69
Models/DataBase/Picture.cs
Normal file
69
Models/DataBase/Picture.cs
Normal file
@@ -0,0 +1,69 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using System.Text.Json;
|
||||
using Vector = Pgvector.Vector;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public enum StorageType
|
||||
{
|
||||
Local = 0,
|
||||
Telegram = 1,
|
||||
}
|
||||
|
||||
public class Picture : BaseModel
|
||||
{
|
||||
[StringLength(255)] public string Name { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(1024)] public string Path { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(1024)] public string? ThumbnailPath { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(2000)] public string Description { get; set; } = string.Empty;
|
||||
[Column(TypeName = "vector(1024)")] public Vector? Embedding { get; set; }
|
||||
|
||||
public DateTime? TakenAt { get; set; }
|
||||
|
||||
[Column(TypeName = "jsonb")] public string? ExifInfoJson { get; set; }
|
||||
|
||||
[NotMapped]
|
||||
public ExifInfo? ExifInfo
|
||||
{
|
||||
get => ExifInfoJson != null ? JsonSerializer.Deserialize<ExifInfo>(ExifInfoJson) : null;
|
||||
set => ExifInfoJson = value != null ? JsonSerializer.Serialize(value) : null;
|
||||
}
|
||||
|
||||
public StorageType StorageType { get; set; } = StorageType.Local;
|
||||
|
||||
public ICollection<Tag>? Tags { get; set; }
|
||||
public int? UserId { get; set; }
|
||||
|
||||
public User? User { get; set; }
|
||||
|
||||
public int? AlbumId { get; set; }
|
||||
public Album? Album { get; set; }
|
||||
|
||||
public ICollection<Favorite>? Favorites { get; set; }
|
||||
|
||||
public bool ContentWarning { get; set; } = false;
|
||||
public PermissionType Permission { get; set; } = PermissionType.Public;
|
||||
|
||||
public ProcessingStatus ProcessingStatus { get; set; } = ProcessingStatus.Pending;
|
||||
public string? ProcessingError { get; set; }
|
||||
public int ProcessingProgress { get; set; } = 0;
|
||||
}
|
||||
|
||||
public enum PermissionType
|
||||
{
|
||||
Public = 0,
|
||||
Friends = 1,
|
||||
Private = 2
|
||||
}
|
||||
|
||||
public enum ProcessingStatus
|
||||
{
|
||||
Pending, // 等待处理
|
||||
Processing, // 处理中
|
||||
Completed, // 处理完成
|
||||
Failed // 处理失败
|
||||
}
|
||||
15
Models/DataBase/Role.cs
Normal file
15
Models/DataBase/Role.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class Role : BaseModel
|
||||
{
|
||||
[Required]
|
||||
[StringLength(50)]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(200)]
|
||||
public string Description { get; set; } = string.Empty;
|
||||
|
||||
public ICollection<User>? Users { get; set; }
|
||||
}
|
||||
14
Models/DataBase/Tag.cs
Normal file
14
Models/DataBase/Tag.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class Tag : BaseModel
|
||||
{
|
||||
[Required] [StringLength(50)] public string Name { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(200)] public string Description { get; set; } = string.Empty;
|
||||
|
||||
public ICollection<Picture>? Pictures { get; set; }
|
||||
|
||||
public ICollection<User>? Users { get; set; }
|
||||
}
|
||||
26
Models/DataBase/User.cs
Normal file
26
Models/DataBase/User.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.DataBase;
|
||||
|
||||
public class User : BaseModel
|
||||
{
|
||||
[Required] [StringLength(50)] public required string UserName { get; set; }
|
||||
|
||||
[Required]
|
||||
[EmailAddress]
|
||||
[StringLength(100)]
|
||||
public required string Email { get; set; }
|
||||
|
||||
[Required] [StringLength(255)] public required string PasswordHash { get; set; }
|
||||
|
||||
[StringLength(255)] public string? GithubId { get; set; }
|
||||
public int? RoleId { get; set; }
|
||||
|
||||
public Role? Role { get; set; }
|
||||
|
||||
public ICollection<Favorite>? Favorites { get; set; }
|
||||
|
||||
public ICollection<Tag>? Tags { get; set; }
|
||||
|
||||
public ICollection<Album>? Albums { get; set; }
|
||||
}
|
||||
35
Models/ExifInfo.cs
Normal file
35
Models/ExifInfo.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace Foxel.Models;
|
||||
|
||||
public class ExifInfo
|
||||
{
|
||||
// 基本图像信息
|
||||
public int Width { get; set; }
|
||||
public int Height { get; set; }
|
||||
|
||||
// 相机信息
|
||||
public string? CameraMaker { get; set; }
|
||||
public string? CameraModel { get; set; }
|
||||
public string? Software { get; set; }
|
||||
|
||||
// 拍摄参数
|
||||
public string? ExposureTime { get; set; }
|
||||
public string? Aperture { get; set; }
|
||||
public string? IsoSpeed { get; set; }
|
||||
public string? FocalLength { get; set; }
|
||||
public string? Flash { get; set; }
|
||||
public string? MeteringMode { get; set; }
|
||||
public string? WhiteBalance { get; set; }
|
||||
|
||||
// 时间信息
|
||||
public string? DateTimeOriginal { get; set; }
|
||||
|
||||
// 位置信息
|
||||
public string? GpsLatitude { get; set; }
|
||||
public string? GpsLongitude { get; set; }
|
||||
|
||||
// 错误信息
|
||||
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
|
||||
public string? ErrorMessage { get; set; }
|
||||
}
|
||||
13
Models/PaginatedResult.cs
Normal file
13
Models/PaginatedResult.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
namespace Foxel.Models;
|
||||
|
||||
public class PaginatedResult<T> : BaseResult<List<T>>
|
||||
{
|
||||
|
||||
|
||||
public int Page { get; set; } = 1;
|
||||
public int PageSize { get; set; } = 10;
|
||||
public int TotalCount { get; set; }
|
||||
public int TotalPages => (int)Math.Ceiling(TotalCount / (double)PageSize);
|
||||
public bool HasPreviousPage => Page > 1;
|
||||
public bool HasNextPage => Page < TotalPages;
|
||||
}
|
||||
7
Models/Request/Album/AlbumPictureRequest.cs
Normal file
7
Models/Request/Album/AlbumPictureRequest.cs
Normal file
@@ -0,0 +1,7 @@
|
||||
namespace Foxel.Models.Request.Album;
|
||||
|
||||
public class AlbumPictureRequest
|
||||
{
|
||||
public int AlbumId { get; set; }
|
||||
public int PictureId { get; set; }
|
||||
}
|
||||
7
Models/Request/Album/AlbumPicturesRequest.cs
Normal file
7
Models/Request/Album/AlbumPicturesRequest.cs
Normal file
@@ -0,0 +1,7 @@
|
||||
namespace Foxel.Models.Request.Album;
|
||||
|
||||
public class AlbumPicturesRequest
|
||||
{
|
||||
public int AlbumId { get; set; }
|
||||
public List<int> PictureIds { get; set; } = new();
|
||||
}
|
||||
13
Models/Request/Album/CreateAlbumRequest.cs
Normal file
13
Models/Request/Album/CreateAlbumRequest.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.Request.Album;
|
||||
|
||||
public class CreateAlbumRequest
|
||||
{
|
||||
[Required]
|
||||
[StringLength(100)]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(500)]
|
||||
public string? Description { get; set; }
|
||||
}
|
||||
6
Models/Request/Album/UpdateAlbumRequest.cs
Normal file
6
Models/Request/Album/UpdateAlbumRequest.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace Foxel.Models.Request.Album;
|
||||
|
||||
public class UpdateAlbumRequest : CreateAlbumRequest
|
||||
{
|
||||
public int Id { get; set; }
|
||||
}
|
||||
7
Models/Request/Auth/LoginRequest.cs
Normal file
7
Models/Request/Auth/LoginRequest.cs
Normal file
@@ -0,0 +1,7 @@
|
||||
namespace Foxel.Models.Request.Auth;
|
||||
|
||||
public class LoginRequest
|
||||
{
|
||||
public string Email { get; set; } = string.Empty;
|
||||
public string Password { get; set; } = string.Empty;
|
||||
}
|
||||
8
Models/Request/Auth/RegisterRequest.cs
Normal file
8
Models/Request/Auth/RegisterRequest.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace Foxel.Models.Request.Auth;
|
||||
|
||||
public class RegisterRequest
|
||||
{
|
||||
public string UserName { get; set; } = string.Empty;
|
||||
public string Email { get; set; } = string.Empty;
|
||||
public string Password { get; set; } = string.Empty;
|
||||
}
|
||||
15
Models/Request/Config/SetConfigRequest.cs
Normal file
15
Models/Request/Config/SetConfigRequest.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.Request.Config;
|
||||
|
||||
public class SetConfigRequest
|
||||
{
|
||||
[Required(ErrorMessage = "配置键不能为空")]
|
||||
[StringLength(50, ErrorMessage = "配置键长度不能超过50个字符")]
|
||||
public string Key { get; set; } = string.Empty;
|
||||
|
||||
public string? Value { get; set; }
|
||||
|
||||
[StringLength(255, ErrorMessage = "描述长度不能超过255个字符")]
|
||||
public string? Description { get; set; }
|
||||
}
|
||||
6
Models/Request/Picture/DeleteMultiplePicturesRequest.cs
Normal file
6
Models/Request/Picture/DeleteMultiplePicturesRequest.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class DeleteMultiplePicturesRequest
|
||||
{
|
||||
public List<int> PictureIds { get; set; } = new();
|
||||
}
|
||||
6
Models/Request/Picture/DeletePictureRequest.cs
Normal file
6
Models/Request/Picture/DeletePictureRequest.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class DeletePictureRequest
|
||||
{
|
||||
public int Id { get; set; }
|
||||
}
|
||||
6
Models/Request/Picture/FavoriteRequest.cs
Normal file
6
Models/Request/Picture/FavoriteRequest.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class FavoriteRequest
|
||||
{
|
||||
public int PictureId { get; set; }
|
||||
}
|
||||
39
Models/Request/Picture/FilteredPicturesRequest.cs
Normal file
39
Models/Request/Picture/FilteredPicturesRequest.cs
Normal file
@@ -0,0 +1,39 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.Request.Picture
|
||||
{
|
||||
public class FilteredPicturesRequest
|
||||
{
|
||||
[Range(1, int.MaxValue, ErrorMessage = "页码必须大于0")]
|
||||
public int Page { get; set; } = 1;
|
||||
|
||||
[Range(1, 100, ErrorMessage = "每页数量必须在1-100之间")]
|
||||
public int PageSize { get; set; } = 8;
|
||||
|
||||
public string? SearchQuery { get; set; }
|
||||
|
||||
public string? Tags { get; set; }
|
||||
|
||||
public DateTime? StartDate { get; set; }
|
||||
|
||||
public DateTime? EndDate { get; set; }
|
||||
|
||||
public string? SortBy { get; set; } = "newest";
|
||||
|
||||
public bool OnlyWithGps { get; set; } = false;
|
||||
|
||||
public bool UseVectorSearch { get; set; } = false;
|
||||
|
||||
public double SimilarityThreshold { get; set; } = 0.36;
|
||||
|
||||
public int? ExcludeAlbumId { get; set; }
|
||||
|
||||
public int? AlbumId { get; set; }
|
||||
|
||||
public bool OnlyFavorites { get; set; } = false;
|
||||
|
||||
public int? OwnerId { get; set; }
|
||||
|
||||
public bool IncludeAllPublic { get; set; } = false;
|
||||
}
|
||||
}
|
||||
9
Models/Request/Picture/SearchPicturesByTextRequest.cs
Normal file
9
Models/Request/Picture/SearchPicturesByTextRequest.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class SearchPicturesByTextRequest
|
||||
{
|
||||
public string Query { get; set; } = string.Empty;
|
||||
public int Page { get; set; } = 1;
|
||||
public int PageSize { get; set; } = 8;
|
||||
public double SimilarityThreshold { get; set; } = 0.36;
|
||||
}
|
||||
8
Models/Request/Picture/UpdatePictureRequest.cs
Normal file
8
Models/Request/Picture/UpdatePictureRequest.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class UpdatePictureRequest
|
||||
{
|
||||
public string? Name { get; set; }
|
||||
public string? Description { get; set; }
|
||||
public List<string>? Tags { get; set; }
|
||||
}
|
||||
6
Models/Request/Picture/UpdatePictureRequestWithId.cs
Normal file
6
Models/Request/Picture/UpdatePictureRequestWithId.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class UpdatePictureRequestWithId : UpdatePictureRequest
|
||||
{
|
||||
public int Id { get; set; }
|
||||
}
|
||||
13
Models/Request/Picture/UploadPictureRequest.cs
Normal file
13
Models/Request/Picture/UploadPictureRequest.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using Foxel.Models.DataBase;
|
||||
|
||||
namespace Foxel.Models.Request.Picture;
|
||||
|
||||
public class UploadPictureRequest
|
||||
{
|
||||
[Required] public IFormFile File { get; set; } = null!;
|
||||
|
||||
public int? Permission { get; set; } = 1;
|
||||
|
||||
public int? AlbumId { get; set; } = null;
|
||||
}
|
||||
13
Models/Request/Tag/CreateTagRequest.cs
Normal file
13
Models/Request/Tag/CreateTagRequest.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.Request.Tag;
|
||||
|
||||
public class CreateTagRequest
|
||||
{
|
||||
[Required]
|
||||
[StringLength(50)]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
[StringLength(200)]
|
||||
public string? Description { get; set; }
|
||||
}
|
||||
21
Models/Request/Tag/FilteredTagsRequest.cs
Normal file
21
Models/Request/Tag/FilteredTagsRequest.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Foxel.Models.Request.Tag
|
||||
{
|
||||
public class FilteredTagsRequest
|
||||
{
|
||||
[Range(1, int.MaxValue, ErrorMessage = "页码必须大于0")]
|
||||
public int Page { get; set; } = 1;
|
||||
|
||||
[Range(1, 100, ErrorMessage = "每页数量必须在1-100之间")]
|
||||
public int PageSize { get; set; } = 20;
|
||||
|
||||
public string? SearchQuery { get; set; }
|
||||
|
||||
// 排序方式:name, pictureCount, createdAt
|
||||
public string? SortBy { get; set; } = "pictureCount";
|
||||
|
||||
// 排序方向:asc, desc
|
||||
public string? SortDirection { get; set; } = "desc";
|
||||
}
|
||||
}
|
||||
6
Models/Request/Tag/UpdateTagRequest.cs
Normal file
6
Models/Request/Tag/UpdateTagRequest.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace Foxel.Models.Request.Tag;
|
||||
|
||||
public class UpdateTagRequest : CreateTagRequest
|
||||
{
|
||||
public int Id { get; set; }
|
||||
}
|
||||
15
Models/Response/Album/AlbumResponse.cs
Normal file
15
Models/Response/Album/AlbumResponse.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using Foxel.Models.Response.Picture;
|
||||
|
||||
namespace Foxel.Models.Response.Album;
|
||||
|
||||
public class AlbumResponse
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string Description { get; set; } = string.Empty;
|
||||
public int PictureCount { get; set; } = 0;
|
||||
public int UserId { get; set; }
|
||||
public string? Username { get; set; }
|
||||
public DateTime CreatedAt { get; set; }
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
}
|
||||
15
Models/Response/Auth/AuthResponse.cs
Normal file
15
Models/Response/Auth/AuthResponse.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
namespace Foxel.Models.Response.Auth;
|
||||
|
||||
public class UserProfile
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string UserName { get; set; } = string.Empty;
|
||||
public string Email { get; set; } = string.Empty;
|
||||
public string? RoleName { get; set; }
|
||||
}
|
||||
|
||||
public class AuthResponse
|
||||
{
|
||||
public string Token { get; set; } = string.Empty;
|
||||
public UserProfile User { get; set; } = new();
|
||||
}
|
||||
26
Models/Response/Picture/PictureResponse.cs
Normal file
26
Models/Response/Picture/PictureResponse.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using Foxel.Models.DataBase;
|
||||
|
||||
namespace Foxel.Models.Response.Picture;
|
||||
|
||||
public class PictureResponse
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Path { get; set; }
|
||||
public string? ThumbnailPath { get; set; }
|
||||
public string Description { get; set; } = string.Empty;
|
||||
public DateTime CreatedAt { get; set; }
|
||||
public List<string>? Tags { get; set; }
|
||||
public DateTime? TakenAt { get; set; }
|
||||
public ExifInfo? ExifInfo { get; set; }
|
||||
public int? UserId { get; set; }
|
||||
public string? Username { get; set; }
|
||||
public bool IsFavorited { get; set; }
|
||||
public int FavoriteCount { get; set; }
|
||||
public int? AlbumId { get; set; }
|
||||
public string? AlbumName { get; set; }
|
||||
public PermissionType Permission { get; set; } = PermissionType.Public;
|
||||
public ProcessingStatus ProcessingStatus { get; set; }
|
||||
public string? ProcessingError { get; set; }
|
||||
public int ProcessingProgress { get; set; }
|
||||
}
|
||||
19
Models/Response/Tag/TagResponse.cs
Normal file
19
Models/Response/Tag/TagResponse.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
namespace Foxel.Models.Response.Tag;
|
||||
|
||||
public class TagResponse
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string Description { get; set; } = string.Empty;
|
||||
public int PictureCount { get; set; } = 0;
|
||||
public DateTime CreatedAt { get; set; }
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
}
|
||||
|
||||
public class TagWithCount
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string Description { get; set; } = string.Empty;
|
||||
public int Count { get; set; } = 0;
|
||||
}
|
||||
Reference in New Issue
Block a user