feat: add forChild and forLazy static methods

pull/4377/head
Arman Ozak 5 years ago
parent ef9e911649
commit 03d71d7875

@ -1,13 +1,13 @@
import { CoreModule } from '@abp/ng.core';
import { CoreModule, LazyModuleFactory } from '@abp/ng.core';
import { FeatureManagementModule } from '@abp/ng.feature-management';
import { ThemeSharedModule } from '@abp/ng.theme.shared';
import { NgModule, Provider } from '@angular/core';
import { ModuleWithProviders, NgModule, NgModuleFactory } from '@angular/core';
import { NgbDropdownModule } from '@ng-bootstrap/ng-bootstrap';
import { NgxValidateCoreModule } from '@ngx-validate/core';
import { NgxsModule } from '@ngxs/store';
import { TenantsComponent } from './components/tenants/tenants.component';
import { TenantManagementState } from './states/tenant-management.state';
import { TenantManagementRoutingModule } from './tenant-management-routing.module';
import { FeatureManagementModule } from '@abp/ng.feature-management';
import { NgxValidateCoreModule } from '@ngx-validate/core';
@NgModule({
declarations: [TenantsComponent],
@ -22,4 +22,15 @@ import { NgxValidateCoreModule } from '@ngx-validate/core';
FeatureManagementModule,
],
})
export class TenantManagementModule {}
export class TenantManagementModule {
static forChild(): ModuleWithProviders<TenantManagementModule> {
return {
ngModule: TenantManagementModule,
providers: [],
};
}
static forLazy(): NgModuleFactory<TenantManagementModule> {
return new LazyModuleFactory(TenantManagementModule.forChild());
}
}

Loading…
Cancel
Save