diff --git a/Ombi/Ombi/wwwroot/app/settings/settings.module.ts b/Ombi/Ombi/wwwroot/app/settings/settings.module.ts
index 29665748b..10df7055f 100644
--- a/Ombi/Ombi/wwwroot/app/settings/settings.module.ts
+++ b/Ombi/Ombi/wwwroot/app/settings/settings.module.ts
@@ -6,6 +6,7 @@ import { RouterModule, Routes } from '@angular/router';
import { AuthService } from '../auth/auth.service';
import { AuthGuard } from '../auth/auth.guard';
import { AuthModule } from '../auth/auth.module';
+import { SonarrService } from '../services/applications/sonarr.service';
import { OmbiComponent } from './ombi/ombi.component'
import { PlexComponent } from './plex/plex.component'
@@ -41,7 +42,7 @@ const routes: Routes = [
RouterModule
],
providers: [
-
+ SonarrService,
AuthService,
AuthGuard,
],
diff --git a/Ombi/Ombi/wwwroot/app/settings/sonarr/sonarr.component.html b/Ombi/Ombi/wwwroot/app/settings/sonarr/sonarr.component.html
new file mode 100644
index 000000000..9321bb908
--- /dev/null
+++ b/Ombi/Ombi/wwwroot/app/settings/sonarr/sonarr.component.html
@@ -0,0 +1,102 @@
+
diff --git a/Ombi/Ombi/wwwroot/app/settings/sonarr/sonarr.component.ts b/Ombi/Ombi/wwwroot/app/settings/sonarr/sonarr.component.ts
new file mode 100644
index 000000000..ee82a4244
--- /dev/null
+++ b/Ombi/Ombi/wwwroot/app/settings/sonarr/sonarr.component.ts
@@ -0,0 +1,79 @@
+import { Component, OnInit } from '@angular/core';
+
+import { ISonarrSettings } from '../../interfaces/ISettings'
+import { ISonarrProfile, ISonarrRootFolder } from '../../interfaces/ISonarr'
+import { SettingsService } from '../../services/settings.service';
+import { SonarrService } from '../../services/applications/sonarr.service';
+import { NotificationService } from "../../services/notification.service";
+
+@Component({
+ selector: 'ombi',
+ moduleId: module.id,
+ templateUrl: './sonarr.component.html',
+})
+export class SonarrComponent implements OnInit {
+
+ constructor(private settingsService: SettingsService, private sonarrService: SonarrService, private notificationService: NotificationService) { }
+
+ settings: ISonarrSettings;
+
+ qualities: ISonarrProfile[];
+ rootFolders: ISonarrRootFolder[];
+
+ selectedRootFolder:ISonarrRootFolder;
+ selectedQuality: ISonarrProfile;
+
+ profilesRunning: boolean;
+ rootFoldersRunning:boolean;
+
+ ngOnInit(): void {
+ this.settings = {
+ apiKey: "",
+ port: 8081,
+ fullRootPath: "",
+ rootPath: "",
+ subDir: "",
+ ssl: false,
+ seasonFolders: false,
+ qualityProfile: "",
+ ip: "",
+ enable: false,
+ id: 0
+ };
+ }
+
+
+ getProfiles() {
+ this.profilesRunning = true;
+ this.sonarrService.getQualityProfiles(this.settings).subscribe(x => {
+ this.qualities = x;
+
+ this.profilesRunning = false;
+ this.notificationService.success("Quality Profiles", "Successfully retrevied the Quality Profiles");
+ });
+ }
+
+ getRootFolders() {
+ this.rootFoldersRunning = true;
+ this.sonarrService.getRootFolders(this.settings).subscribe(x => {
+ this.rootFolders = x;
+
+ this.rootFoldersRunning = false;
+ this.notificationService.success("Settings Saved", "Successfully retrevied the Root Folders");
+ });
+ }
+
+ test() {
+ // TODO
+ }
+
+ save() {
+ this.settingsService.saveSonarr(this.settings).subscribe(x => {
+ if (x) {
+ this.notificationService.success("Settings Saved", "Successfully saved Ombi settings");
+ } else {
+ this.notificationService.success("Settings Saved", "There was an error when saving the Ombi settings");
+ }
+ });
+ }
+}
\ No newline at end of file
diff --git a/Ombi/Ombi/wwwroot/systemjs.config.js b/Ombi/Ombi/wwwroot/systemjs.config.js
new file mode 100644
index 000000000..79a38f763
--- /dev/null
+++ b/Ombi/Ombi/wwwroot/systemjs.config.js
@@ -0,0 +1,14 @@
+"use strict";
+System.config({
+ baseURL: '/lib',
+ packages: {
+ '.': {
+ defaultExtension: 'js'
+ }
+ },
+ map: { app: '../app' }
+});
+System.import('bundle').then(function () {
+ System.import('/app/main');
+});
+//# sourceMappingURL=systemjs.config.js.map
\ No newline at end of file
diff --git a/Ombi/Ombi/wwwroot/systemjs.config.js.map b/Ombi/Ombi/wwwroot/systemjs.config.js.map
new file mode 100644
index 000000000..1a2f3a3c3
--- /dev/null
+++ b/Ombi/Ombi/wwwroot/systemjs.config.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"systemjs.config.js","sourceRoot":"","sources":["systemjs.config.ts"],"names":[],"mappings":";AAAA,MAAM,CAAC,MAAM,CAAC;IACV,OAAO,EAAE,MAAM;IACf,QAAQ,EAAE;QACN,GAAG,EAAE;YACD,gBAAgB,EAAE,IAAI;SACzB;KACJ;IACD,GAAG,EAAE,EAAE,GAAG,EAAE,QAAQ,EAAE;CACzB,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC;IACzB,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;AAC/B,CAAC,CAAC,CAAA"}
\ No newline at end of file