I'm working on an already working website which was built using Smart Admin template.
I'm trying to add a component to the dashboard as a first step.
Here are the commands and steps I followed:
-Command line:
ng g module test --routing
cd test
ng g component test --flat
-Added in file app.routing.ts:
{path: 'test',loadChildren:'app/test/test.module#TestModule'}
-Added in file test-routing.module.ts:
import { TestComponent } from './test.component';
const routes: Routes = [
{
path:'',
component:TestComponent
}
];
-Added in file test-routing.module.ts
import { SmartadminModule } from '../shared/smartadmin.module';
and
SmartadminModule inside imports:[]
The test.component.html only contains:
<p>
test works!
</p>
When i call the page I'm getting the dashboard,header, footer... However in other modules in the project, the dashboard ... are included explicitly by adding :
<sa-header></sa-header>
<sa-navigation></sa-navigation>
<div id="main" role="main">
<sa-ribbon></sa-ribbon>
<router-outlet></router-outlet>
</div>
<sa-footer></sa-footer>
<sa-shortcut></sa-shortcut>
I hope someone can help me solve this problem.
Thank you