diff --git a/src/app/commons/component/sidebar/menu-element.ts b/src/app/commons/component/sidebar/menu-element.ts index 07fdc7e..aa7c163 100644 --- a/src/app/commons/component/sidebar/menu-element.ts +++ b/src/app/commons/component/sidebar/menu-element.ts @@ -20,7 +20,7 @@ export const menus = [ }, { 'name': 'Sensors', - 'link': '', + 'link': '/sensors', 'icon': 'indeterminate_check_box', 'chip': false, 'open': false, diff --git a/src/app/pages/pages-routing.module.ts b/src/app/pages/pages-routing.module.ts index 1492318..80e5982 100644 --- a/src/app/pages/pages-routing.module.ts +++ b/src/app/pages/pages-routing.module.ts @@ -11,6 +11,7 @@ const routes: Routes = [ { path: 'home', loadChildren: './home/home-page.module#HomePageModule' }, { path: 'probes', loadChildren: './probes/probes-page.module#ProbesPageModule' }, { path: 'probe', loadChildren: './probe/probe-page.module#ProbePageModule' }, + { path: 'sensors', loadChildren: './sensors/sensors-page.module#SensorsPageModule' }, { path: 'discovery', loadChildren: './discovery/discovery-page.module#DiscoveryPageModule' }, { path: 'map', loadChildren: './infra/infra-page.module#InfraPageModule' }, { path: 'sensor-setting', loadChildren: './sensor-setting/sensor-setting-page.module#SensorSettingPageModule' }, diff --git a/src/app/pages/sensors/sensors-page-routing.module.ts b/src/app/pages/sensors/sensors-page-routing.module.ts new file mode 100644 index 0000000..2c60e9c --- /dev/null +++ b/src/app/pages/sensors/sensors-page-routing.module.ts @@ -0,0 +1,19 @@ +import { NgModule } from '@angular/core'; +import { Routes, RouterModule } from '@angular/router'; +import { SensorsPageComponent } from './sensors-page.component'; + +const routes: Routes = [ + { + path: '', + component: SensorsPageComponent, + children: [ + // { path: '', component: SensorListComponent }, + ] + } +]; + +@NgModule({ + imports: [RouterModule.forChild(routes)], + exports: [RouterModule] +}) +export class SensorsPageRoutingModule { } diff --git a/src/app/pages/sensors/sensors-page.component.html b/src/app/pages/sensors/sensors-page.component.html new file mode 100644 index 0000000..33ea338 --- /dev/null +++ b/src/app/pages/sensors/sensors-page.component.html @@ -0,0 +1,3 @@ +

+ sensors works! +

diff --git a/src/app/pages/sensors/sensors-page.component.scss b/src/app/pages/sensors/sensors-page.component.scss new file mode 100644 index 0000000..e69de29 diff --git a/src/app/pages/sensors/sensors-page.component.spec.ts b/src/app/pages/sensors/sensors-page.component.spec.ts new file mode 100644 index 0000000..8120231 --- /dev/null +++ b/src/app/pages/sensors/sensors-page.component.spec.ts @@ -0,0 +1,25 @@ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { SensorsPageComponent } from './sensors-page.component'; + +describe('SensorsComponent', () => { + let component: SensorsPageComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ SensorsPageComponent ] + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(SensorsPageComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/src/app/pages/sensors/sensors-page.component.ts b/src/app/pages/sensors/sensors-page.component.ts new file mode 100644 index 0000000..91bfb42 --- /dev/null +++ b/src/app/pages/sensors/sensors-page.component.ts @@ -0,0 +1,21 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'of-pages-sensors', + templateUrl: './sensors-page.component.html', + styleUrls: ['./sensors-page.component.scss'] +}) +export class SensorsPageComponent implements OnInit { + + tabs = [ + { label: 'Overview', path: '/sensors' }, + { label: 'History', path: '/sensors/history' }, + { label: 'Settings', path: '/sensors/setting' }, + ]; + + constructor() { } + + ngOnInit() { + } + +} diff --git a/src/app/pages/sensors/sensors-page.module.ts b/src/app/pages/sensors/sensors-page.module.ts new file mode 100644 index 0000000..7192a9d --- /dev/null +++ b/src/app/pages/sensors/sensors-page.module.ts @@ -0,0 +1,17 @@ +import { NgModule } from '@angular/core'; +import { CommonModule } from '@angular/common'; +import { MaterialModule } from '../../commons/ui/material/material.module'; +import { SensorsPageComponent } from './sensors-page.component'; +import { SensorsPageRoutingModule } from './sensors-page-routing.module'; + +@NgModule({ + imports: [ + CommonModule, + MaterialModule, + SensorsPageRoutingModule + ], + declarations: [ + SensorsPageComponent + ] +}) +export class SensorsPageModule { }