Browse Source

ReplaceEmbeddedByPhysical for the AbpAspNetCoreMvcUiThemeSharedDemoModule

pull/2921/head
Halil İbrahim Kalkan 6 years ago
parent
commit
10d8e22e9f
  1. 4
      framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo/Views/Components/Themes/Shared/Demos/ButtonsDemo/Default.cshtml
  2. 19
      framework/test/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo/AbpAspNetCoreMvcUiThemeBasicDemoModule.cs

4
framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo/Views/Components/Themes/Shared/Demos/ButtonsDemo/Default.cshtml

@ -5,4 +5,8 @@
<abp-demo-section name="Buttons.Basic" view-path="@ButtonsDemoViewComponent.ViewPath">
<abp-button button-type="Primary" text="Primary button" />
<abp-button button-type="Secondary" text="Secondary button" />
<abp-button button-type="Info" text="Info button" />
<abp-button button-type="Warning" text="Warning button" />
<abp-button button-type="Dark" text="Dark button" />
<abp-button button-type="Light" text="Light button" />
</abp-demo-section>

19
framework/test/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo/AbpAspNetCoreMvcUiThemeBasicDemoModule.cs

@ -1,8 +1,12 @@
using Microsoft.AspNetCore.Builder;
using System.IO;
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo;
using Volo.Abp.Autofac;
using Volo.Abp.Modularity;
using Volo.Abp.UI;
using Volo.Abp.VirtualFileSystem;
namespace Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo
{
@ -13,6 +17,19 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo
)]
public class AbpAspNetCoreMvcUiThemeBasicDemoModule : AbpModule
{
public override void ConfigureServices(ServiceConfigurationContext context)
{
var env = context.Services.GetHostingEnvironment();
if (env.IsDevelopment())
{
Configure<AbpVirtualFileSystemOptions>(options =>
{
options.FileSets.ReplaceEmbeddedByPhysical<AbpAspNetCoreMvcUiThemeSharedDemoModule>(Path.Combine(env.ContentRootPath, string.Format("..{0}..{0}src{0}Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo", Path.DirectorySeparatorChar)));
});
}
}
public override void OnApplicationInitialization(ApplicationInitializationContext context)
{
var app = context.GetApplicationBuilder();

Loading…
Cancel
Save