@ -44,6 +44,19 @@ public class AbpAspNetCoreMvcTestModule : AbpModule
typeof ( AbpAspNetCoreMvcTestModule ) . Assembly
) ;
} ) ;
context . Services . PreConfigure < AbpAspNetCoreMvcOptions > ( options = >
{
options . ConventionalControllers . Create ( typeof ( TestAppModule ) . Assembly , opts = >
{
opts . UrlActionNameNormalizer = urlActionNameNormalizerContext = >
string . Equals ( urlActionNameNormalizerContext . ActionNameInUrl , "phone" , StringComparison . OrdinalIgnoreCase )
? "phones"
: urlActionNameNormalizerContext . ActionNameInUrl ;
} ) ;
options . ExposeIntegrationServices = true ;
} ) ;
}
public override void ConfigureServices ( ServiceConfigurationContext context )
@ -79,19 +92,6 @@ public class AbpAspNetCoreMvcTestModule : AbpModule
} ) ;
} ) ;
Configure < AbpAspNetCoreMvcOptions > ( options = >
{
options . ConventionalControllers . Create ( typeof ( TestAppModule ) . Assembly , opts = >
{
opts . UrlActionNameNormalizer = urlActionNameNormalizerContext = >
string . Equals ( urlActionNameNormalizerContext . ActionNameInUrl , "phone" , StringComparison . OrdinalIgnoreCase )
? "phones"
: urlActionNameNormalizerContext . ActionNameInUrl ;
} ) ;
options . ExposeIntegrationServices = true ;
} ) ;
Configure < AbpVirtualFileSystemOptions > ( options = >
{
options . FileSets . AddEmbedded < AbpAspNetCoreMvcTestModule > ( ) ;