Restructured the rest of the features to their own environment

This commit is contained in:
Marcel Baumgartner 2024-01-26 13:53:34 +01:00
parent 63b2b40227
commit 12bc66a95b
91 changed files with 181 additions and 147 deletions

View file

@ -1,5 +1,5 @@
using Moonlight.Core.Database.Entities.Store; using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Core.Models.Abstractions.Services; using Moonlight.Features.ServiceManagement.Models.Abstractions;
namespace Moonlight.Core.Actions.Dummy; namespace Moonlight.Core.Actions.Dummy;

View file

@ -1,7 +1,7 @@
using Moonlight.Core.Actions.Dummy.Layouts; using Moonlight.Core.Actions.Dummy.Layouts;
using Moonlight.Core.Actions.Dummy.Pages; using Moonlight.Core.Actions.Dummy.Pages;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Core.Models.Abstractions.Services; using Moonlight.Features.ServiceManagement.Models.Abstractions;
namespace Moonlight.Core.Actions.Dummy; namespace Moonlight.Core.Actions.Dummy;

View file

@ -1,6 +1,8 @@
using System.ComponentModel; using System.ComponentModel;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Features.Advertisement.Configuration;
using Moonlight.Features.StoreSystem.Configuration; using Moonlight.Features.StoreSystem.Configuration;
using Moonlight.Features.Theming.Configuration;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Moonlight.Core.Configuration; namespace Moonlight.Core.Configuration;
@ -20,17 +22,6 @@ public class ConfigV1
[JsonProperty("Theme")] public ThemeData Theme { get; set; } = new(); [JsonProperty("Theme")] public ThemeData Theme { get; set; } = new();
[JsonProperty("Advertisement")] public AdvertisementData Advertisement { get; set; } = new(); [JsonProperty("Advertisement")] public AdvertisementData Advertisement { get; set; } = new();
public class AdvertisementData
{
[JsonProperty("PreventAdBlockers")]
[Description("This prevents users from using ad blockers while using moonlight. (Note: The detection might not always work)")]
public bool PreventAdBlockers { get; set; }
}
public class ThemeData
{
[JsonProperty("EnableDefault")] public bool EnableDefault { get; set; } = true;
}
public class SecurityData public class SecurityData
{ {
[JsonProperty("Token")] [JsonProperty("Token")]

View file

@ -1,9 +1,10 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Services; using Moonlight.Core.Services;
using Moonlight.Features.Community.Entities; using Moonlight.Features.Community.Entities;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
using Moonlight.Features.Theming.Entities;
using Moonlight.Features.Ticketing.Entities; using Moonlight.Features.Ticketing.Entities;
namespace Moonlight.Core.Database; namespace Moonlight.Core.Database;

View file

@ -1,7 +0,0 @@
namespace Moonlight.Core.Database.Entities.Store;
public class ServiceShare
{
public int Id { get; set; }
public User User { get; set; }
}

View file

@ -1,5 +1,4 @@
using Moonlight.Core.Database.Entities.Store; using Moonlight.Features.StoreSystem.Entities;
using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Core.Database.Entities; namespace Moonlight.Core.Database.Entities;

View file

@ -1,5 +1,4 @@
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Core.Event.Args; namespace Moonlight.Core.Event.Args;

View file

@ -1,7 +1,7 @@
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Event.Args; using Moonlight.Core.Event.Args;
using Moonlight.Features.Community.Entities; using Moonlight.Features.Community.Entities;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.Ticketing.Entities; using Moonlight.Features.Ticketing.Entities;
namespace Moonlight.Core.Event; namespace Moonlight.Core.Event;

View file

@ -1,6 +1,6 @@
using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Core.Services.Sys; using Moonlight.Features.Theming.Services;
namespace Moonlight.Core.Http.Controllers.Api; namespace Moonlight.Core.Http.Controllers.Api;
@ -8,9 +8,9 @@ namespace Moonlight.Core.Http.Controllers.Api;
[Route("api/assetproxy")] [Route("api/assetproxy")]
public class AssetProxyController : Controller public class AssetProxyController : Controller
{ {
private readonly MoonlightThemeService ThemeService; private readonly ThemeService ThemeService;
public AssetProxyController(MoonlightThemeService themeService) public AssetProxyController(ThemeService themeService)
{ {
ThemeService = themeService; ThemeService = themeService;
} }

View file

@ -1,4 +1,4 @@
using Moonlight.Core.Models.Abstractions.Services; using Moonlight.Features.ServiceManagement.Models.Abstractions;
namespace Moonlight.Core.Plugins.Contexts; namespace Moonlight.Core.Plugins.Contexts;

View file

@ -1,7 +1,7 @@
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Event; using Moonlight.Core.Event;
using Moonlight.Core.Event.Args; using Moonlight.Core.Event.Args;
using Moonlight.Features.ServiceManagement.Entities;
namespace Moonlight.Core.Services.Background; namespace Moonlight.Core.Services.Background;

View file

@ -1,6 +1,5 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Exceptions; using Moonlight.Core.Exceptions;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Core.Models.Abstractions; using Moonlight.Core.Models.Abstractions;

View file

@ -2,8 +2,9 @@
using Moonlight.Core.Event; using Moonlight.Core.Event;
using Moonlight.Core.Extensions; using Moonlight.Core.Extensions;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Features.Theming.Services;
namespace Moonlight.Core.Services.Sys; namespace Moonlight.Core.Services;
public class MoonlightService // This service can be used to perform strictly panel specific actions public class MoonlightService // This service can be used to perform strictly panel specific actions
{ {
@ -12,7 +13,7 @@ public class MoonlightService // This service can be used to perform strictly pa
public WebApplication Application { get; set; } // Do NOT modify using a plugin public WebApplication Application { get; set; } // Do NOT modify using a plugin
public string LogPath { get; set; } // Do NOT modify using a plugin public string LogPath { get; set; } // Do NOT modify using a plugin
public MoonlightThemeService Theme => ServiceProvider.GetRequiredService<MoonlightThemeService>(); public ThemeService Theme => ServiceProvider.GetRequiredService<ThemeService>();
public MoonlightService(ConfigService configService, IServiceProvider serviceProvider) public MoonlightService(ConfigService configService, IServiceProvider serviceProvider)
{ {

View file

@ -1,8 +1,8 @@
using System.Reflection; using System.Reflection;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Core.Models.Abstractions.Services;
using Moonlight.Core.Plugins; using Moonlight.Core.Plugins;
using Moonlight.Core.Plugins.Contexts; using Moonlight.Core.Plugins.Contexts;
using Moonlight.Features.ServiceManagement.Models.Abstractions;
namespace Moonlight.Core.Services; namespace Moonlight.Core.Services;

View file

@ -1,10 +1,10 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Core.Services.ServiceManage;
using Moonlight.Features.Community.Entities; using Moonlight.Features.Community.Entities;
using Moonlight.Features.Community.Services; using Moonlight.Features.Community.Services;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.ServiceManagement.Services;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
using Moonlight.Features.Ticketing.Entities; using Moonlight.Features.Ticketing.Entities;

View file

@ -1,10 +1,12 @@
@using Moonlight.Shared.Components.Auth @using Moonlight.Core.Models.Abstractions
@using Moonlight.Core.Models.Abstractions
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Core.Services.Utils @using Moonlight.Core.Services.Utils
@using Moonlight.Core.Event @using Moonlight.Core.Event
@using Moonlight.Core.UI.Components.Auth
@using Moonlight.Features.Advertisement.Services
@using Moonlight.Features.Advertisement.UI.Components
@inherits LayoutComponentBase @inherits LayoutComponentBase
@implements IDisposable @implements IDisposable

View file

@ -1,6 +1,5 @@
@page "/account/payments" @page "/account/payments"
@using BlazorTable @using BlazorTable
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Exceptions @using Moonlight.Core.Exceptions
@using Moonlight.Core.Helpers @using Moonlight.Core.Helpers
@using Moonlight.Core.Models.Abstractions @using Moonlight.Core.Models.Abstractions

View file

@ -1,10 +1,10 @@
@page "/admin/services" @page "/admin/services"
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using BlazorTable @using BlazorTable
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Features.ServiceManagement.Entities
@attribute [RequirePermission(Permission.AdminServices)] @attribute [RequirePermission(Permission.AdminServices)]

View file

@ -1,12 +1,12 @@
@page "/admin/services/view/{Id:int}/{Route?}" @page "/admin/services/view/{Id:int}/{Route?}"
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Models.Abstractions.Services
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Core.Services.ServiceManage @using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.ServiceManagement.Models.Abstractions
@using Moonlight.Features.ServiceManagement.Services
@attribute [RequirePermission(Permission.AdminServices)] @attribute [RequirePermission(Permission.AdminServices)]

View file

@ -1,8 +1,8 @@
@page "/admin/sys/diagnose" @page "/admin/sys/diagnose"
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Services
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Core.Services.Sys
@attribute [RequirePermission(Permission.AdminRoot)] @attribute [RequirePermission(Permission.AdminRoot)]

View file

@ -1,7 +1,7 @@
@page "/admin/sys" @page "/admin/sys"
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Services.Sys @using Moonlight.Core.Services
@attribute [RequirePermission(Permission.AdminRoot)] @attribute [RequirePermission(Permission.AdminRoot)]

View file

@ -3,7 +3,6 @@
@using Mappy.Net @using Mappy.Net
@using BlazorTable @using BlazorTable
@using Moonlight.Core.Database.Entities @using Moonlight.Core.Database.Entities
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Helpers @using Moonlight.Core.Helpers
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@ -12,6 +11,7 @@
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Core.Services.Users @using Moonlight.Core.Services.Users
@using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.StoreSystem.Entities @using Moonlight.Features.StoreSystem.Entities
@attribute [RequirePermission(Permission.AdminUsers)] @attribute [RequirePermission(Permission.AdminUsers)]

View file

@ -1,4 +1,5 @@
@page "/" @page "/"
@using Moonlight.Core.Services @using Moonlight.Core.Services
@inject IdentityService IdentityService @inject IdentityService IdentityService

View file

@ -0,0 +1,11 @@
using System.ComponentModel;
using Newtonsoft.Json;
namespace Moonlight.Features.Advertisement.Configuration;
public class AdvertisementData
{
[JsonProperty("PreventAdBlockers")]
[Description("This prevents users from using ad blockers while using moonlight. (Note: The detection might not always work)")]
public bool PreventAdBlockers { get; set; }
}

View file

@ -1,7 +1,7 @@
using Microsoft.JSInterop; using Microsoft.JSInterop;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
namespace Moonlight.Core.Services.Interop; namespace Moonlight.Features.Advertisement.Services;
public class AdBlockService public class AdBlockService
{ {

View file

@ -1,7 +1,6 @@
using System.Text.RegularExpressions; using System.Text.RegularExpressions;
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Enums;
using Moonlight.Core.Event; using Moonlight.Core.Event;
using Moonlight.Core.Exceptions; using Moonlight.Core.Exceptions;
using Moonlight.Core.Extensions; using Moonlight.Core.Extensions;

View file

@ -1,5 +1,4 @@
@using Moonlight.Core.Database.Enums @using Moonlight.Core.Services
@using Moonlight.Core.Services
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Features.Community.Entities.Enums @using Moonlight.Features.Community.Entities.Enums
@using Moonlight.Features.Community.Models.Forms @using Moonlight.Features.Community.Models.Forms

View file

@ -1,7 +1,6 @@
@page "/community/projects" @page "/community/projects"
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using Moonlight.Core.Database.Enums
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Features.Community.Entities @using Moonlight.Features.Community.Entities
@using Moonlight.Features.Community.Entities.Enums @using Moonlight.Features.Community.Entities.Enums

View file

@ -1,4 +1,4 @@
namespace Moonlight.Core.Database.Enums; namespace Moonlight.Features.ServiceManagement.Entities.Enums;
public enum ServiceType public enum ServiceType
{ {

View file

@ -1,6 +1,7 @@
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Core.Database.Entities.Store; namespace Moonlight.Features.ServiceManagement.Entities;
public class Service public class Service
{ {

View file

@ -0,0 +1,9 @@
using Moonlight.Core.Database.Entities;
namespace Moonlight.Features.ServiceManagement.Entities;
public class ServiceShare
{
public int Id { get; set; }
public User User { get; set; }
}

View file

@ -1,6 +1,6 @@
using Moonlight.Core.Database.Entities.Store; using Moonlight.Features.ServiceManagement.Entities;
namespace Moonlight.Core.Models.Abstractions.Services; namespace Moonlight.Features.ServiceManagement.Models.Abstractions;
public abstract class ServiceActions public abstract class ServiceActions
{ {

View file

@ -1,4 +1,4 @@
namespace Moonlight.Core.Models.Abstractions.Services; namespace Moonlight.Features.ServiceManagement.Models.Abstractions;
public abstract class ServiceDefinition public abstract class ServiceDefinition
{ {

View file

@ -1,6 +1,6 @@
using Microsoft.AspNetCore.Components; using Microsoft.AspNetCore.Components;
namespace Moonlight.Core.Models.Abstractions.Services; namespace Moonlight.Features.ServiceManagement.Models.Abstractions;
public class ServiceUiPage public class ServiceUiPage
{ {

View file

@ -1,10 +1,10 @@
using Microsoft.AspNetCore.Components; using Microsoft.AspNetCore.Components;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Core.Models.Abstractions.Services; namespace Moonlight.Features.ServiceManagement.Models.Abstractions;
public class ServiceViewContext public class ServiceViewContext
{ {

View file

@ -1,6 +1,6 @@
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
namespace Moonlight.Core.Models.Forms.Services; namespace Moonlight.Features.ServiceManagement.Models.Forms;
public class AddUserToServiceForm public class AddUserToServiceForm
{ {

View file

@ -1,11 +1,11 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Exceptions; using Moonlight.Core.Exceptions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Core.Services.ServiceManage; namespace Moonlight.Features.ServiceManagement.Services;
public class ServiceAdminService public class ServiceAdminService
{ {

View file

@ -1,11 +1,11 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Database.Enums;
using Moonlight.Core.Models.Abstractions.Services;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.ServiceManagement.Entities.Enums;
using Moonlight.Features.ServiceManagement.Models.Abstractions;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Core.Services.ServiceManage; namespace Moonlight.Features.ServiceManagement.Services;
public class ServiceDefinitionService public class ServiceDefinitionService
{ {

View file

@ -1,11 +1,11 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Models.Abstractions; using Moonlight.Core.Models.Abstractions;
using Moonlight.Core.Models.Enums; using Moonlight.Core.Models.Enums;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Features.ServiceManagement.Entities;
namespace Moonlight.Core.Services.ServiceManage; namespace Moonlight.Features.ServiceManagement.Services;
public class ServiceManageService public class ServiceManageService
{ {

View file

@ -1,10 +1,10 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Exceptions; using Moonlight.Core.Exceptions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Features.ServiceManagement.Entities;
namespace Moonlight.Core.Services.ServiceManage; namespace Moonlight.Features.ServiceManagement.Services;
public class ServiceService // This service is used for managing services and create the connection to the actual logic behind a service type public class ServiceService // This service is used for managing services and create the connection to the actual logic behind a service type
{ {

View file

@ -1,8 +1,8 @@
@using BlazorTable @using BlazorTable
@using Moonlight.Core.Database.Entities @using Moonlight.Core.Database.Entities
@using Moonlight.Core.Database.Entities.Store @using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Core.Models.Forms.Services @using Moonlight.Features.ServiceManagement.Models.Forms
@using Moonlight.Core.Services.ServiceManage @using Moonlight.Features.ServiceManagement.Services
@inject ServiceService ServiceService @inject ServiceService ServiceService

View file

@ -1,10 +1,9 @@
@using Moonlight.Shared.Components.Modals @using Moonlight.Core.Exceptions
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Exceptions
@using Moonlight.Core.Helpers @using Moonlight.Core.Helpers
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Core.Services.ServiceManage @using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.ServiceManagement.Services
@using Moonlight.Features.StoreSystem.Services @using Moonlight.Features.StoreSystem.Services
@inject ConfigService ConfigService @inject ConfigService ConfigService

View file

@ -1,9 +1,10 @@
@page "/services" @page "/services"
@using Moonlight.Shared.Components.Service
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Helpers @using Moonlight.Core.Helpers
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Core.Services.ServiceManage @using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.ServiceManagement.Services
@using Moonlight.Features.ServiceManagement.UI.Components
@inject ServiceService ServiceService @inject ServiceService ServiceService
@inject IdentityService IdentityService @inject IdentityService IdentityService

View file

@ -1,11 +1,11 @@
@page "/service/{Id:int}/{Route?}" @page "/service/{Id:int}/{Route?}"
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Models.Abstractions.Services
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Core.Services.ServiceManage @using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.ServiceManagement.Models.Abstractions
@using Moonlight.Features.ServiceManagement.Services
@inject Repository<Service> ServiceRepository @inject Repository<Service> ServiceRepository
@inject ServiceService ServiceService @inject ServiceService ServiceService

View file

@ -1,4 +1,4 @@
using Moonlight.Core.Database.Enums; using Moonlight.Features.ServiceManagement.Entities.Enums;
namespace Moonlight.Features.StoreSystem.Entities; namespace Moonlight.Features.StoreSystem.Entities;

View file

@ -1,8 +1,7 @@
using System.ComponentModel; using System.ComponentModel;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Database.Enums;
using Moonlight.Core.Extensions.Attributes; using Moonlight.Core.Extensions.Attributes;
using Moonlight.Features.ServiceManagement.Entities.Enums;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Features.StoreSystem.Models.Forms; namespace Moonlight.Features.StoreSystem.Models.Forms;

View file

@ -1,6 +1,5 @@
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using Moonlight.Core.Database.Entities.Store; using Moonlight.Features.ServiceManagement.Entities.Enums;
using Moonlight.Core.Database.Enums;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Features.StoreSystem.Models.Forms; namespace Moonlight.Features.StoreSystem.Models.Forms;

View file

@ -1,8 +1,8 @@
using Moonlight.Core.Database.Entities.Store; using Moonlight.Core.Exceptions;
using Moonlight.Core.Database.Enums;
using Moonlight.Core.Exceptions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Core.Services.ServiceManage; using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.ServiceManagement.Entities.Enums;
using Moonlight.Features.ServiceManagement.Services;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
using Newtonsoft.Json; using Newtonsoft.Json;

View file

@ -1,6 +1,5 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Exceptions; using Moonlight.Core.Exceptions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;

View file

@ -1,11 +1,11 @@
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Event; using Moonlight.Core.Event;
using Moonlight.Core.Exceptions; using Moonlight.Core.Exceptions;
using Moonlight.Core.Extensions; using Moonlight.Core.Extensions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Core.Services.ServiceManage; using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.ServiceManagement.Services;
using Moonlight.Features.StoreSystem.Entities; using Moonlight.Features.StoreSystem.Entities;
namespace Moonlight.Features.StoreSystem.Services; namespace Moonlight.Features.StoreSystem.Services;

View file

@ -1,5 +1,4 @@
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store;
using Moonlight.Core.Event; using Moonlight.Core.Event;
using Moonlight.Core.Extensions; using Moonlight.Core.Extensions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;

View file

@ -1,8 +1,7 @@
@using Mappy.Net @using Mappy.Net
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Database.Enums
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Features.ServiceManagement.Entities.Enums
@using Moonlight.Features.StoreSystem.Entities @using Moonlight.Features.StoreSystem.Entities
@using Moonlight.Features.StoreSystem.Models.Forms @using Moonlight.Features.StoreSystem.Models.Forms
@using Moonlight.Features.StoreSystem.Services @using Moonlight.Features.StoreSystem.Services

View file

@ -2,11 +2,11 @@
@using BlazorTable @using BlazorTable
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using Moonlight.Core.Database.Entities.Store
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Helpers @using Moonlight.Core.Helpers
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.StoreSystem.UI.Components @using Moonlight.Features.StoreSystem.UI.Components
@attribute [RequirePermission(Permission.AdminStore)] @attribute [RequirePermission(Permission.AdminStore)]

View file

@ -0,0 +1,8 @@
using Newtonsoft.Json;
namespace Moonlight.Features.Theming.Configuration;
public class ThemeData
{
[JsonProperty("EnableDefault")] public bool EnableDefault { get; set; } = true;
}

View file

@ -1,4 +1,4 @@
namespace Moonlight.Core.Database.Entities; namespace Moonlight.Features.Theming.Entities;
public class Theme public class Theme
{ {

View file

@ -1,4 +1,4 @@
namespace Moonlight.Core.Models.Abstractions; namespace Moonlight.Features.Theming.Models.Abstractions;
public class ApplicationTheme public class ApplicationTheme
{ {

View file

@ -1,7 +1,7 @@
using System.ComponentModel; using System.ComponentModel;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
namespace Moonlight.Core.Models.Forms.Admin.Sys.Themes; namespace Moonlight.Features.Theming.Models.Forms;
public class AddThemeForm public class AddThemeForm
{ {

View file

@ -1,7 +1,7 @@
using System.ComponentModel; using System.ComponentModel;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
namespace Moonlight.Core.Models.Forms.Admin.Sys.Themes; namespace Moonlight.Features.Theming.Models.Forms;
public class EditThemeForm public class EditThemeForm
{ {

View file

@ -1,4 +1,4 @@
namespace Moonlight.Core.Models.Json.Theme; namespace Moonlight.Features.Theming.Models;
public class ThemeExport public class ThemeExport
{ {

View file

@ -1,4 +1,4 @@
namespace Moonlight.Core.Models.Json.Theme; namespace Moonlight.Features.Theming.Models;
public class ThemeImport public class ThemeImport
{ {

View file

@ -1,16 +1,18 @@
using Mappy.Net; using Mappy.Net;
using Moonlight.Core.Database.Entities;
using Moonlight.Core.Models.Abstractions; using Moonlight.Core.Models.Abstractions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Core.Services;
using Moonlight.Features.Theming.Entities;
using Moonlight.Features.Theming.Models.Abstractions;
namespace Moonlight.Core.Services.Sys; namespace Moonlight.Features.Theming.Services;
public class MoonlightThemeService public class ThemeService
{ {
private readonly IServiceProvider ServiceProvider; private readonly IServiceProvider ServiceProvider;
private readonly ConfigService ConfigService; private readonly ConfigService ConfigService;
public MoonlightThemeService(IServiceProvider serviceProvider, ConfigService configService) public ThemeService(IServiceProvider serviceProvider, ConfigService configService)
{ {
ServiceProvider = serviceProvider; ServiceProvider = serviceProvider;
ConfigService = configService; ConfigService = configService;

View file

@ -1,15 +1,16 @@
@page "/admin/sys/themes" @page "/admin/sys/themes"
@using BlazorTable @using BlazorTable
@using Mappy.Net @using Mappy.Net
@using Microsoft.AspNetCore.Components.Forms @using Microsoft.AspNetCore.Components.Forms
@using Moonlight.Core.Database.Entities
@using Moonlight.Core.Exceptions @using Moonlight.Core.Exceptions
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@using Moonlight.Core.Models.Forms.Admin.Sys.Themes
@using Moonlight.Core.Models.Json.Theme
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Core.Services.Interop @using Moonlight.Core.Services.Interop
@using Moonlight.Features.Theming.Entities
@using Moonlight.Features.Theming.Models
@using Moonlight.Features.Theming.Models.Forms
@using Newtonsoft.Json @using Newtonsoft.Json
@attribute [RequirePermission(Permission.AdminRoot)] @attribute [RequirePermission(Permission.AdminRoot)]

View file

@ -1,5 +1,5 @@
using Moonlight.Core.Database.Entities; using Moonlight.Core.Database.Entities;
using Moonlight.Core.Database.Entities.Store; using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.Ticketing.Entities.Enums; using Moonlight.Features.Ticketing.Entities.Enums;
namespace Moonlight.Features.Ticketing.Entities; namespace Moonlight.Features.Ticketing.Entities;

View file

@ -1,5 +1,5 @@
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using Moonlight.Core.Database.Entities.Store; using Moonlight.Features.ServiceManagement.Entities;
namespace Moonlight.Features.Ticketing.Models.Forms; namespace Moonlight.Features.Ticketing.Models.Forms;

View file

@ -1,8 +1,8 @@
using Moonlight.Core.Database.Entities.Store; using Moonlight.Core.Event;
using Moonlight.Core.Event;
using Moonlight.Core.Extensions; using Moonlight.Core.Extensions;
using Moonlight.Core.Repositories; using Moonlight.Core.Repositories;
using Moonlight.Core.Services; using Moonlight.Core.Services;
using Moonlight.Features.ServiceManagement.Entities;
using Moonlight.Features.Ticketing.Entities; using Moonlight.Features.Ticketing.Entities;
using Moonlight.Features.Ticketing.Entities.Enums; using Moonlight.Features.Ticketing.Entities.Enums;

View file

@ -1,7 +1,7 @@
@using Moonlight.Core.Database.Entities.Store @using Moonlight.Core.Exceptions
@using Moonlight.Core.Exceptions
@using Moonlight.Core.Repositories @using Moonlight.Core.Repositories
@using Moonlight.Core.Services @using Moonlight.Core.Services
@using Moonlight.Features.ServiceManagement.Entities
@using Moonlight.Features.Ticketing.Models.Forms @using Moonlight.Features.Ticketing.Models.Forms
@using Moonlight.Features.Ticketing.Services @using Moonlight.Features.Ticketing.Services

View file

@ -2,7 +2,6 @@
@using BlazorTable @using BlazorTable
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using Moonlight.Core.Database.Enums
@using Moonlight.Core.Event @using Moonlight.Core.Event
@using Moonlight.Core.Event.Args @using Moonlight.Core.Event.Args
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes

View file

@ -2,7 +2,6 @@
@using System.Text.RegularExpressions @using System.Text.RegularExpressions
@using Microsoft.EntityFrameworkCore @using Microsoft.EntityFrameworkCore
@using Moonlight.Core.Database.Enums
@using Moonlight.Core.Extensions.Attributes @using Moonlight.Core.Extensions.Attributes
@using Moonlight.Core.Helpers @using Moonlight.Core.Helpers
@using Moonlight.Core.Models.Enums @using Moonlight.Core.Models.Enums
@ -11,6 +10,7 @@
@using Moonlight.Features.Ticketing.Entities @using Moonlight.Features.Ticketing.Entities
@using Moonlight.Features.Ticketing.Entities.Enums @using Moonlight.Features.Ticketing.Entities.Enums
@using Moonlight.Features.Ticketing.Services @using Moonlight.Features.Ticketing.Services
@using Moonlight.Features.Ticketing.UI.Components
@attribute [RequirePermission(Permission.AdminTickets)] @attribute [RequirePermission(Permission.AdminTickets)]

View file

@ -19,7 +19,6 @@
<Folder Include="Core\Http\Requests\" /> <Folder Include="Core\Http\Requests\" />
<Folder Include="Core\Http\Resources\" /> <Folder Include="Core\Http\Resources\" />
<Folder Include="Core\UI\Components\" /> <Folder Include="Core\UI\Components\" />
<Folder Include="Core\UI\Views\" />
<Folder Include="Features\Dummy\Configuration\" /> <Folder Include="Features\Dummy\Configuration\" />
<Folder Include="Features\Dummy\Entities\" /> <Folder Include="Features\Dummy\Entities\" />
<Folder Include="Features\Dummy\Exceptions\" /> <Folder Include="Features\Dummy\Exceptions\" />
@ -34,21 +33,7 @@
<Folder Include="Features\Dummy\Services\" /> <Folder Include="Features\Dummy\Services\" />
<Folder Include="Features\Dummy\UI\Components\" /> <Folder Include="Features\Dummy\UI\Components\" />
<Folder Include="Features\Dummy\UI\Views\" /> <Folder Include="Features\Dummy\UI\Views\" />
<Folder Include="Features\StoreSystem\Exceptions\" />
<Folder Include="Features\StoreSystem\Extensions\" />
<Folder Include="Features\StoreSystem\Helpers\" /> <Folder Include="Features\StoreSystem\Helpers\" />
<Folder Include="Features\StoreSystem\Http\Controllers\" />
<Folder Include="Features\StoreSystem\Http\Middleware\" />
<Folder Include="Features\StoreSystem\Http\Requests\" />
<Folder Include="Features\StoreSystem\Http\Resources\" />
<Folder Include="Features\Ticketing\Configuration\" />
<Folder Include="Features\Ticketing\Exceptions\" />
<Folder Include="Features\Ticketing\Extensions\" />
<Folder Include="Features\Ticketing\Helpers\" />
<Folder Include="Features\Ticketing\Http\Controllers\" />
<Folder Include="Features\Ticketing\Http\Middleware\" />
<Folder Include="Features\Ticketing\Http\Requests\" />
<Folder Include="Features\Ticketing\Http\Resources\" />
<Folder Include="Features\Ticketing\Models\Abstractions\" /> <Folder Include="Features\Ticketing\Models\Abstractions\" />
</ItemGroup> </ItemGroup>
@ -78,10 +63,16 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<AdditionalFiles Include="Core\UI\Components\Alerts\NotFoundAlert.razor" />
<AdditionalFiles Include="Core\UI\Components\Alerts\RestartAlert.razor" />
<AdditionalFiles Include="Core\UI\Components\Auth\ChangePassword.razor" />
<AdditionalFiles Include="Core\UI\Components\Auth\Login.razor" />
<AdditionalFiles Include="Core\UI\Components\Auth\MailVerify.razor" />
<AdditionalFiles Include="Core\UI\Components\Auth\PasswordReset.razor" />
<AdditionalFiles Include="Core\UI\Components\Auth\Register.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\AutoCrud.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\AutoCrud.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\AutoForm.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\AutoForm.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\AutoProperty.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\AutoProperty.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\ChatFileSelect.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\ConfirmButton.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\ConfirmButton.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\DynamicTypedAutoForm.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\DynamicTypedAutoForm.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\SmartCustomFileSelect.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\SmartCustomFileSelect.razor" />
@ -92,6 +83,9 @@
<AdditionalFiles Include="Core\UI\Components\Forms\SmartSelect.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\SmartSelect.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\TextEditor.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\TextEditor.razor" />
<AdditionalFiles Include="Core\UI\Components\Forms\WButton.razor" /> <AdditionalFiles Include="Core\UI\Components\Forms\WButton.razor" />
<AdditionalFiles Include="Core\UI\Components\Navigations\AccountNavigation.razor" />
<AdditionalFiles Include="Core\UI\Components\Navigations\AdminSysNavigation.razor" />
<AdditionalFiles Include="Core\UI\Components\Navigations\AdminUsersNavigation.razor" />
<AdditionalFiles Include="Core\UI\Components\Partials\ConnectionIndicator.razor" /> <AdditionalFiles Include="Core\UI\Components\Partials\ConnectionIndicator.razor" />
<AdditionalFiles Include="Core\UI\Components\Partials\LazyLoader.razor" /> <AdditionalFiles Include="Core\UI\Components\Partials\LazyLoader.razor" />
<AdditionalFiles Include="Core\UI\Components\Partials\PageHeader.razor" /> <AdditionalFiles Include="Core\UI\Components\Partials\PageHeader.razor" />
@ -103,6 +97,18 @@
<AdditionalFiles Include="Core\UI\Layouts\DefaultLayout.razor" /> <AdditionalFiles Include="Core\UI\Layouts\DefaultLayout.razor" />
<AdditionalFiles Include="Core\UI\Layouts\MainLayout.razor" /> <AdditionalFiles Include="Core\UI\Layouts\MainLayout.razor" />
<AdditionalFiles Include="Core\UI\Layouts\OverlayLayout.razor" /> <AdditionalFiles Include="Core\UI\Layouts\OverlayLayout.razor" />
<AdditionalFiles Include="Core\UI\Views\Account\Index.razor" />
<AdditionalFiles Include="Core\UI\Views\Account\Payments.razor" />
<AdditionalFiles Include="Core\UI\Views\Account\Security.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Index.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Services\Index.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Services\View.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Sys\Diagnose.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Sys\Index.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Sys\Settings.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Users\Index.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Users\Sessions.razor" />
<AdditionalFiles Include="Core\UI\Views\Admin\Users\View.razor" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
@ -123,5 +129,24 @@
<_ContentIncludedByDefault Remove="Shared\Layouts\DefaultLayout.razor" /> <_ContentIncludedByDefault Remove="Shared\Layouts\DefaultLayout.razor" />
<_ContentIncludedByDefault Remove="Shared\Layouts\MainLayout.razor" /> <_ContentIncludedByDefault Remove="Shared\Layouts\MainLayout.razor" />
<_ContentIncludedByDefault Remove="Shared\Layouts\OverlayLayout.razor" /> <_ContentIncludedByDefault Remove="Shared\Layouts\OverlayLayout.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Auth\ChangePassword.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Auth\Login.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Auth\MailVerify.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Auth\PasswordReset.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Auth\Register.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Alerts\NotFoundAlert.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Alerts\RestartAlert.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Navigations\AccountNavigation.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Navigations\AdminSysNavigation.razor" />
<_ContentIncludedByDefault Remove="Shared\Components\Navigations\AdminUsersNavigation.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Index.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Services\Index.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Services\View.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Sys\Diagnose.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Sys\Index.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Sys\Settings.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Users\Index.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Users\Sessions.razor" />
<_ContentIncludedByDefault Remove="Shared\Views\Admin\Users\View.razor" />
</ItemGroup> </ItemGroup>
</Project> </Project>

View file

@ -1,13 +1,13 @@
@page "/" @page "/"
@using Microsoft.AspNetCore.Components.Web @using Microsoft.AspNetCore.Components.Web
@using Moonlight.Core.Services.Sys @using Moonlight.Features.Theming.Services
@namespace Moonlight.Pages @namespace Moonlight.Pages
@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers
@inject MoonlightThemeService MoonlightThemeService @inject ThemeService ThemeService
@{ @{
var themes = await MoonlightThemeService.GetEnabled(); var themes = await ThemeService.GetEnabled();
} }
<!DOCTYPE html> <!DOCTYPE html>

View file

@ -2,7 +2,6 @@ using BlazorTable;
using Moonlight.Core.Database; using Moonlight.Core.Database;
using Moonlight.Core.Actions.Dummy; using Moonlight.Core.Actions.Dummy;
using Moonlight.Core.Database; using Moonlight.Core.Database;
using Moonlight.Core.Database.Enums;
using Moonlight.Core.Extensions; using Moonlight.Core.Extensions;
using Moonlight.Core.Helpers; using Moonlight.Core.Helpers;
using Moonlight.Core.Helpers.LogMigrator; using Moonlight.Core.Helpers.LogMigrator;
@ -10,12 +9,14 @@ using Moonlight.Core.Repositories;
using Moonlight.Core.Services; using Moonlight.Core.Services;
using Moonlight.Core.Services.Background; using Moonlight.Core.Services.Background;
using Moonlight.Core.Services.Interop; using Moonlight.Core.Services.Interop;
using Moonlight.Core.Services.ServiceManage;
using Moonlight.Core.Services.Sys;
using Moonlight.Core.Services.Users; using Moonlight.Core.Services.Users;
using Moonlight.Core.Services.Utils; using Moonlight.Core.Services.Utils;
using Moonlight.Features.Advertisement.Services;
using Moonlight.Features.Community.Services; using Moonlight.Features.Community.Services;
using Moonlight.Features.ServiceManagement.Entities.Enums;
using Moonlight.Features.ServiceManagement.Services;
using Moonlight.Features.StoreSystem.Services; using Moonlight.Features.StoreSystem.Services;
using Moonlight.Features.Theming.Services;
using Moonlight.Features.Ticketing.Services; using Moonlight.Features.Ticketing.Services;
using Serilog; using Serilog;
@ -105,7 +106,7 @@ builder.Services.AddSingleton<SessionService>();
builder.Services.AddSingleton<BucketService>(); builder.Services.AddSingleton<BucketService>();
builder.Services.AddSingleton<MailService>(); builder.Services.AddSingleton<MailService>();
builder.Services.AddSingleton<MoonlightService>(); builder.Services.AddSingleton<MoonlightService>();
builder.Services.AddSingleton<MoonlightThemeService>(); builder.Services.AddSingleton<ThemeService>();
builder.Services.AddRazorPages(); builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor(); builder.Services.AddServerSideBlazor();

View file

@ -4,5 +4,5 @@
@using Moonlight.Core.UI.Components.Partials @using Moonlight.Core.UI.Components.Partials
@using Moonlight.Core.UI.Components.Forms @using Moonlight.Core.UI.Components.Forms
@using Moonlight.Shared.Components.Navigations @using Moonlight.Core.UI.Components.Navigations
@using Moonlight.Shared.Components.Alerts @using Moonlight.Core.UI.Components.Alerts