Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 17 additions & 11 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "firefox",
"request": "launch",
"reAttach": true,
"name": "Launch localhost",
"url": "http://localhost:4200",
"webRoot": "${workspaceFolder}"
}
]
"version": "0.2.0",
"configurations": [{
"type": "firefox",
"request": "launch",
"reAttach": true,
"name": "Launch localhost with Firefox",
"url": "http://localhost:4200",
"webRoot": "${workspaceFolder}"
},
{
"name": "Launch localhost with Chrome",
"type": "chrome",
"request": "launch",
"url": "http://localhost:4200",
"webRoot": "${workspaceFolder}"
},
]
}
83 changes: 83 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@
"@fortawesome/free-solid-svg-icons": "^5.13.0",
"@ng-bootstrap/ng-bootstrap": "^6.1.0",
"@ng-bootstrap/schematics": "^2.0.0-alpha.1",
"@ngrx/effects": "^10.0.0",
"@ngrx/router-store": "^10.0.0",
"@ngrx/store": "^10.0.0",
"@ngx-translate/core": "^13.0.0",
"@ngx-translate/http-loader": "^6.0.0",
"all": "0.0.0",
Expand All @@ -43,6 +46,7 @@
"@angular-devkit/build-angular": "^0.901.9",
"@angular/cli": "~9.1.9",
"@angular/compiler-cli": "~9.1.11",
"@ngrx/store-devtools": "^10.0.0",
"@types/jasmine": "~3.5.0",
"@types/jasminewd2": "~2.0.3",
"@types/node": "^12.11.1",
Expand All @@ -55,9 +59,11 @@
"karma-coverage-istanbul-reporter": "~2.1.0",
"karma-jasmine": "~3.0.1",
"karma-jasmine-html-reporter": "^1.4.2",
"ngrx-store-freeze": "^0.2.4",
"prettier": "^2.0.5",
"protractor": "~7.0.0",
"ts-node": "~8.3.0",
"tslint-angular": "^3.0.3",
"tslint-config-prettier": "^1.18.0",
"typescript": "~3.8.3"
}
Expand Down
164 changes: 86 additions & 78 deletions src/app/app-routing.module.ts
Original file line number Diff line number Diff line change
@@ -1,78 +1,86 @@
import { NgModule, Component } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { DashboardComponent } from './views/dashboard/dashboard/dashboard.component';
import { MineApplikationerComponent } from './views/mine-applikationer/mine-applikationer/mine-applikationer.component';
import { EditApplicationComponent } from './views/mine-applikationer/edit-application/edit-application.component';
import { ListApplicationsComponent } from './views/mine-applikationer/list-applications/list-applications.component';
import { ApplicationComponent } from './views/mine-applikationer/application/application.component';
import { IoTDeviceComponent } from './views/alle-iot-enheder/iot-device/iot-device.component';
import { EditIotDeviceComponent } from './views/alle-iot-enheder/edit-iot-device/edit-iot-device.component';
import { MineLoraGatewaysComponent } from './views/administration-gateway/mine-lora-gateways/mine-lora-gateways.component';
import { ListLoraGatewayComponent } from './views/administration-gateway/list-lora-gateway/list-lora-gateway.component';
import { EditGatewayComponent } from './views/administration-gateway/edit-gateway/edit-gateway.component';
import { GatewayComponent } from './views/administration-gateway/gateway/gateway.component';
import { DatatargetListComponent } from './views/datatarget/datatarget-list/datatarget-list.component';
import { DatatargetEditComponent } from './views/datatarget/datatarget-edit/datatarget-edit.component';
import { DatatargetComponent } from './views/datatarget/datatarget/datatarget.component';

const routes: Routes = [
{ path: 'home', component: DashboardComponent },
{ path: 'mine-applikationer', component: MineApplikationerComponent,
children: [
{ path: '', component: ListApplicationsComponent },
{ path: 'application/:id',
children: [
{ path: '', component: ApplicationComponent },
{ path: 'edit-iot-device', component: EditIotDeviceComponent,},
{ path: 'edit-iot-device/:deviceId', component: EditIotDeviceComponent,},
{ path: 'iot-device/:deviceId', component: IoTDeviceComponent, },
{ path: '', component: ApplicationComponent,

},
{
path: 'edit-iot-device',
component: EditIotDeviceComponent,
},
{
path: 'edit-iot-device/:deviceId',
component: EditIotDeviceComponent,
},
{
path: 'iot-device/:deviceId',
component: IoTDeviceComponent,
},
{
path: 'datatarget-list/:name',
children: [
{ path: '', component: DatatargetListComponent},
{ path: 'datatarget-edit', component: DatatargetEditComponent},
{ path: 'datatarget-edit/:datatargetId', component: DatatargetEditComponent},
{ path: 'datatarget/:datatargetId', component: DatatargetComponent}
]

}
],
},
{ path: 'edit-application', component: EditApplicationComponent,},
{ path: 'edit-application/:id', component: EditApplicationComponent,},
],
},
{ path: 'mine-lora-gateways', component: MineLoraGatewaysComponent,
children: [
{ path: '', component: ListLoraGatewayComponent},
{ path: 'edit-gateway/:id', component: EditGatewayComponent},
{ path: 'edit-gateway', component: EditGatewayComponent},
{ path: 'gateway/:id', component: GatewayComponent}
],

},
{ path: 'datatarget', component: DatatargetListComponent },
{ path: '', redirectTo: '/home', pathMatch: 'full' },
{ path: '**', redirectTo: '/home', pathMatch: 'full' },
];

@NgModule({
imports: [RouterModule.forRoot(routes)],
exports: [RouterModule],
})
export class AppRoutingModule {}
import { NgModule, Component } from '@angular/core';
import { Routes, RouterModule, PreloadAllModules } from '@angular/router';
import { DashboardComponent } from './views/dashboard/dashboard/dashboard.component';
import { EditApplicationComponent } from './my-applications/edit-application/edit-application.component';
import { ListApplicationsComponent } from './my-applications/list-applications/list-applications.component';
import { ApplicationComponent } from './my-applications/application/application.component';
import { IoTDeviceComponent } from './views/alle-iot-enheder/iot-device/iot-device.component';
import { EditIotDeviceComponent } from './views/alle-iot-enheder/edit-iot-device/edit-iot-device.component';
import { MineLoraGatewaysComponent } from './views/administration-gateway/mine-lora-gateways/mine-lora-gateways.component';
import { ListLoraGatewayComponent } from './views/administration-gateway/list-lora-gateway/list-lora-gateway.component';
import { EditGatewayComponent } from './views/administration-gateway/edit-gateway/edit-gateway.component';
import { GatewayComponent } from './views/administration-gateway/gateway/gateway.component';
import { DatatargetListComponent } from './views/datatarget/datatarget-list/datatarget-list.component';
import { DatatargetEditComponent } from './views/datatarget/datatarget-edit/datatarget-edit.component';
import { DatatargetComponent } from './views/datatarget/datatarget/datatarget.component';
import { ProfilesComponent } from './profiles/profiles.component';
import { AlleIotEnhederComponent } from './views/alle-iot-enheder/alle-iot-enheder/alle-iot-enheder.component';
import { MyApplicationsComponent } from './my-applications/my-applications.component';

const routes: Routes = [
{ path: 'home', component: DashboardComponent },
{
path: 'my-applications', component: MyApplicationsComponent,
children: [
{ path: '', component: ListApplicationsComponent },
{
path: 'application/:id',
children: [
{ path: '', component: ApplicationComponent },
{ path: 'edit-iot-device', component: EditIotDeviceComponent, },
{ path: 'edit-iot-device/:deviceId', component: EditIotDeviceComponent, },
{ path: 'iot-device/:deviceId', component: IoTDeviceComponent, },
{
path: '', component: ApplicationComponent,

},
{
path: 'edit-iot-device',
component: EditIotDeviceComponent,
},
{
path: 'edit-iot-device/:deviceId',
component: EditIotDeviceComponent,
},
{
path: 'iot-device/:deviceId',
component: IoTDeviceComponent,
},
{
path: 'datatarget-list/:name',
children: [
{ path: '', component: DatatargetListComponent },
{ path: 'datatarget-edit', component: DatatargetEditComponent },
{ path: 'datatarget-edit/:datatargetId', component: DatatargetEditComponent },
{ path: 'datatarget/:datatargetId', component: DatatargetComponent }
]

}
],
},
{ path: 'edit-application', component: EditApplicationComponent, },
{ path: 'edit-application/:id', component: EditApplicationComponent, },
],
},
{
path: 'mine-lora-gateways', component: MineLoraGatewaysComponent,
children: [
{ path: '', component: ListLoraGatewayComponent },
{ path: 'edit-gateway/:id', component: EditGatewayComponent },
{ path: 'edit-gateway', component: EditGatewayComponent },
{ path: 'gateway/:id', component: GatewayComponent }
],

},
{ path: 'datatarget', component: DatatargetListComponent },
{ path: 'iot-devices', component: AlleIotEnhederComponent },
{ path: 'profiles', loadChildren: () => import('./profiles/profiles.module').then(m => m.ProfilesModule) },
{ path: '', redirectTo: '/home', pathMatch: 'full' },
{ path: '**', redirectTo: '/home', pathMatch: 'full' },
];

@NgModule({
imports: [RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules })],
exports: [RouterModule],
})
export class AppRoutingModule { }
Loading