mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-03 13:11:10 +00:00
Adds the server-side theme repository and reworks the web theme engine onto it
This commit is contained in:
1 parent
85928f7c3c
commit
bf8faba24d
136 files changed
+6942
-1197
No files matched your search
@@ -0,0 +1,32 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Application.Common.DataAccess.Entities.Themes;
|
||||
using Lumina.Contracts.Responses.Themes;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Application.Common.Mapping.Themes;
|
||||
|
||||
/// <summary>
|
||||
/// Extension methods for converting <see cref="ThemeEntity"/>.
|
||||
/// </summary>
|
||||
public static class ThemeEntityMapping
|
||||
{
|
||||
/// <summary>
|
||||
/// Converts <paramref name="theme"/> to <see cref="ThemeResponse"/>.
|
||||
/// </summary>
|
||||
/// <param name="theme">The repository entity to be converted.</param>
|
||||
/// <returns>The converted response.</returns>
|
||||
public static ThemeResponse ToResponse(this ThemeEntity theme)
|
||||
{
|
||||
return new ThemeResponse(
|
||||
theme.Id,
|
||||
theme.ThemeId,
|
||||
theme.Name,
|
||||
theme.Description,
|
||||
theme.Author,
|
||||
theme.Version,
|
||||
theme.PreviewPath,
|
||||
theme.InstallSource,
|
||||
theme.IsCurrent,
|
||||
theme.InstalledAtUtc);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user