Browse Source

CmsKit Configuration for startup template

pull/7992/head
enisn 6 years ago
parent
commit
09a4d70de3
  1. 10
      templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Domain.Shared/MyProjectNameGlobalFeatureConfigurator.cs
  2. 6
      templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore.DbMigrations/EntityFrameworkCore/MyProjectNameMigrationsDbContext.cs

10
templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Domain.Shared/MyProjectNameGlobalFeatureConfigurator.cs

@ -1,4 +1,5 @@
using Volo.Abp.Threading; using Volo.Abp.GlobalFeatures;
using Volo.Abp.Threading;
namespace MyCompanyName.MyProjectName namespace MyCompanyName.MyProjectName
{ {
@ -10,6 +11,13 @@ namespace MyCompanyName.MyProjectName
{ {
OneTimeRunner.Run(() => OneTimeRunner.Run(() =>
{ {
//<TEMPLATE-REMOVE IF-NOT='CMS-KIT'>
GlobalFeatureManager.Instance.Modules.CmsKit(cmsKit =>
{
cmsKit.EnableAll();
});
//</TEMPLATE-REMOVE>
/* You can configure (enable/disable) global features of the used modules here. /* You can configure (enable/disable) global features of the used modules here.
* *
* YOU CAN SAFELY DELETE THIS CLASS AND REMOVE ITS USAGES IF YOU DON'T NEED TO IT! * YOU CAN SAFELY DELETE THIS CLASS AND REMOVE ITS USAGES IF YOU DON'T NEED TO IT!

6
templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore.DbMigrations/EntityFrameworkCore/MyProjectNameMigrationsDbContext.cs

@ -9,6 +9,9 @@ using Volo.Abp.IdentityServer.EntityFrameworkCore;
using Volo.Abp.PermissionManagement.EntityFrameworkCore; using Volo.Abp.PermissionManagement.EntityFrameworkCore;
using Volo.Abp.SettingManagement.EntityFrameworkCore; using Volo.Abp.SettingManagement.EntityFrameworkCore;
using Volo.Abp.TenantManagement.EntityFrameworkCore; using Volo.Abp.TenantManagement.EntityFrameworkCore;
//<TEMPLATE-REMOVE IF-NOT='CMS-KIT'>
using Volo.CmsKit.EntityFrameworkCore;
//</TEMPLATE-REMOVE>
namespace MyCompanyName.MyProjectName.EntityFrameworkCore namespace MyCompanyName.MyProjectName.EntityFrameworkCore
{ {
@ -39,6 +42,9 @@ namespace MyCompanyName.MyProjectName.EntityFrameworkCore
builder.ConfigureIdentityServer(); builder.ConfigureIdentityServer();
builder.ConfigureFeatureManagement(); builder.ConfigureFeatureManagement();
builder.ConfigureTenantManagement(); builder.ConfigureTenantManagement();
//<TEMPLATE-REMOVE IF-NOT='CMS-KIT'>
builder.ConfigureCmsKit();
//</TEMPLATE-REMOVE>
/* Configure your own tables/entities inside the ConfigureMyProjectName method */ /* Configure your own tables/entities inside the ConfigureMyProjectName method */

Loading…
Cancel
Save