ClientAssembly selection criteria changed
This commit is contained in:
@ -1,8 +1,10 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using Oqtane.Modules;
|
||||
using Oqtane.Services;
|
||||
using Oqtane.Shared;
|
||||
using Oqtane.Themes;
|
||||
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace System.Reflection
|
||||
@ -74,7 +76,7 @@ namespace System.Reflection
|
||||
public static IEnumerable<Assembly> GetOqtaneClientAssemblies(this AppDomain appDomain)
|
||||
{
|
||||
return appDomain.GetOqtaneAssemblies()
|
||||
.Where(a => a.GetTypes<IClientStartup>().Any());
|
||||
.Where(a => a.GetTypes<IModuleControl>().Any() || a.GetTypes<IThemeControl>().Any() || a.GetTypes<IClientStartup>().Any());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
12
Oqtane.Shared/Interfaces/IModuleControl.cs
Normal file
12
Oqtane.Shared/Interfaces/IModuleControl.cs
Normal file
@ -0,0 +1,12 @@
|
||||
using Oqtane.Shared;
|
||||
|
||||
namespace Oqtane.Modules
|
||||
{
|
||||
public interface IModuleControl
|
||||
{
|
||||
SecurityAccessLevel SecurityAccessLevel { get; } // defines the security access level for this control - defaults to View
|
||||
string Title { get; } // title to display for this control - defaults to module title
|
||||
string Actions { get; } // allows for routing by configuration rather than by convention ( comma delimited ) - defaults to using component file name
|
||||
bool UseAdminContainer { get; } // container for embedding module control - defaults to true
|
||||
}
|
||||
}
|
7
Oqtane.Shared/Interfaces/IThemeControl.cs
Normal file
7
Oqtane.Shared/Interfaces/IThemeControl.cs
Normal file
@ -0,0 +1,7 @@
|
||||
namespace Oqtane.Themes
|
||||
{
|
||||
public interface IThemeControl
|
||||
{
|
||||
string Panes { get; } // identifies all panes in a theme ( delimited by ";" ) - assumed to be a layout if no panes specified
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user