mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
@@ -67,9 +67,9 @@ namespace Orchard.Setup.Services {
|
||||
|
||||
public string Setup(SetupContext context) {
|
||||
string executionId = null;
|
||||
|
||||
// The vanilla Orchard distibution has the following features enabled.
|
||||
if (context.EnabledFeatures == null || context.EnabledFeatures.Count() == 0) {
|
||||
string[] hardcoded = {
|
||||
string[] hardcoded = {
|
||||
// Framework
|
||||
"Orchard.Framework",
|
||||
// Core
|
||||
@@ -79,7 +79,8 @@ namespace Orchard.Setup.Services {
|
||||
"PackagingServices", "Orchard.Packaging", "Gallery", "Orchard.Recipes",
|
||||
};
|
||||
|
||||
context.EnabledFeatures = hardcoded;
|
||||
if (context.EnabledFeatures != null) {
|
||||
context.EnabledFeatures = hardcoded.Union(context.EnabledFeatures).Distinct();
|
||||
}
|
||||
|
||||
var shellSettings = new ShellSettings(_shellSettings);
|
||||
|
@@ -62,7 +62,7 @@ namespace Orchard.Setup {
|
||||
builder.RegisterType<DataServicesProviderFactory>().As<IDataServicesProviderFactory>().InstancePerLifetimeScope();
|
||||
builder.RegisterType<DefaultCommandManager>().As<ICommandManager>().InstancePerLifetimeScope();
|
||||
builder.RegisterType<HelpCommand>().As<ICommandHandler>().InstancePerLifetimeScope();
|
||||
builder.RegisterType<WorkContextAccessor>().As<IWorkContextAccessor>().InstancePerMatchingLifetimeScope("shell");
|
||||
//builder.RegisterType<WorkContextAccessor>().As<IWorkContextAccessor>().InstancePerMatchingLifetimeScope("shell");
|
||||
builder.RegisterType<ResourceManager>().As<IResourceManager>().InstancePerLifetimeScope();
|
||||
builder.RegisterType<ResourceFilter>().As<IFilterProvider>().InstancePerLifetimeScope();
|
||||
builder.RegisterType<DefaultOrchardShell>().As<IOrchardShell>().InstancePerMatchingLifetimeScope("shell");
|
||||
|
Reference in New Issue
Block a user