mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-19 12:59:39 -07:00
Added some wiki pages and also made it so we cannot edit Plex Users email address (since they will get overwrote via the Importer)
#865
This commit is contained in:
parent
143c619db0
commit
6588fa8ca3
11 changed files with 57 additions and 14 deletions
|
@ -24,4 +24,8 @@ export class JobService extends ServiceAuthHelpers {
|
||||||
public runPlexImporter(): Observable<boolean> {
|
public runPlexImporter(): Observable<boolean> {
|
||||||
return this.http.post(`${this.url}plexUserImporter/`, { headers: this.headers }).map(this.extractData);
|
return this.http.post(`${this.url}plexUserImporter/`, { headers: this.headers }).map(this.extractData);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public runEmbyImporter(): Observable<boolean> {
|
||||||
|
return this.http.post(`${this.url}embyUserImporter/`, { headers: this.headers }).map(this.extractData);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
<settings-menu></settings-menu>
|
<settings-menu></settings-menu>
|
||||||
|
<wiki [url]="'https://github.com/tidusjar/Ombi/wiki/Customization-Settings'"></wiki>
|
||||||
|
|
||||||
<fieldset *ngIf="settings">
|
<fieldset *ngIf="settings">
|
||||||
<legend>Customization</legend>
|
<legend>Customization</legend>
|
||||||
|
<div class="col-md-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="applicationName" class="control-label">Application Name</label>
|
<label for="applicationName" class="control-label">Application Name</label>
|
||||||
<div>
|
<div>
|
||||||
|
@ -24,17 +26,22 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<label for="logo" class="control-label">Logo Preview:</label>
|
|
||||||
<div>
|
|
||||||
<img *ngIf="settings.logo" [src]="settings.logo" style="width: 300px"/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<div>
|
<div>
|
||||||
<button (click)="save()" type="submit" id="save" class="btn btn-primary-outline">Submit</button>
|
<button (click)="save()" type="submit" id="save" class="btn btn-primary-outline">Submit</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-6">
|
||||||
|
|
||||||
|
<div *ngIf="settings.logo" class="form-group">
|
||||||
|
<label for="logo" class="control-label">Logo Preview:</label>
|
||||||
|
<div>
|
||||||
|
<img [src]="settings.logo" style="width: 300px" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
|
@ -1,5 +1,7 @@
|
||||||
|
|
||||||
<settings-menu></settings-menu>
|
<settings-menu></settings-menu>
|
||||||
|
|
||||||
|
<wiki [url]="'https://github.com/tidusjar/Ombi/wiki/Landing-Page-Settings'"></wiki>
|
||||||
<div *ngIf="settings">
|
<div *ngIf="settings">
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend>Landing Page Configuration</legend>
|
<legend>Landing Page Configuration</legend>
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
<settings-menu></settings-menu>
|
<settings-menu></settings-menu>
|
||||||
|
|
||||||
|
<wiki [url]="'https://github.com/tidusjar/Ombi/wiki/Ombi-Settings'"></wiki>
|
||||||
<fieldset *ngIf="form">
|
<fieldset *ngIf="form">
|
||||||
<legend>Ombi Configuration</legend>
|
<legend>Ombi Configuration</legend>
|
||||||
<form novalidate [formGroup]="form" (ngSubmit)="onSubmit(form)">
|
<form novalidate [formGroup]="form" (ngSubmit)="onSubmit(form)">
|
||||||
|
|
|
@ -28,6 +28,7 @@ import { RadarrComponent } from "./radarr/radarr.component";
|
||||||
import { SonarrComponent } from "./sonarr/sonarr.component";
|
import { SonarrComponent } from "./sonarr/sonarr.component";
|
||||||
import { UpdateComponent } from "./update/update.component";
|
import { UpdateComponent } from "./update/update.component";
|
||||||
import { UserManagementComponent } from "./usermanagement/usermanagement.component";
|
import { UserManagementComponent } from "./usermanagement/usermanagement.component";
|
||||||
|
import { WikiComponent } from "./wiki.component";
|
||||||
|
|
||||||
import { SettingsMenuComponent } from "./settingsmenu.component";
|
import { SettingsMenuComponent } from "./settingsmenu.component";
|
||||||
|
|
||||||
|
@ -89,6 +90,7 @@ const routes: Routes = [
|
||||||
UserManagementComponent,
|
UserManagementComponent,
|
||||||
UpdateComponent,
|
UpdateComponent,
|
||||||
AboutComponent,
|
AboutComponent,
|
||||||
|
WikiComponent,
|
||||||
],
|
],
|
||||||
exports: [
|
exports: [
|
||||||
RouterModule,
|
RouterModule,
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
<settings-menu></settings-menu>
|
<settings-menu></settings-menu>
|
||||||
|
|
||||||
|
<wiki [url]="'https://github.com/tidusjar/Ombi/wiki/User-Management-Settings'"></wiki>
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend>User Management Settings</legend>
|
<legend>User Management Settings</legend>
|
||||||
|
|
||||||
|
|
|
@ -102,6 +102,7 @@ export class UserManagementComponent implements OnInit {
|
||||||
|
|
||||||
public runImporter(): void {
|
public runImporter(): void {
|
||||||
this.jobService.runPlexImporter().subscribe();
|
this.jobService.runPlexImporter().subscribe();
|
||||||
|
this.jobService.runPlexImporter().subscribe();
|
||||||
}
|
}
|
||||||
|
|
||||||
private filter(query: string, users: IUsersModel[]): IUsersModel[] {
|
private filter(query: string, users: IUsersModel[]): IUsersModel[] {
|
||||||
|
|
5
src/Ombi/ClientApp/app/settings/wiki.component.html
Normal file
5
src/Ombi/ClientApp/app/settings/wiki.component.html
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
<div class="col-md-12">
|
||||||
|
<div class="col-md-1 col-md-push-11">
|
||||||
|
<a href="{{url}}" target="_blank" class="btn btn-sm btn-info-outline">Wiki</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
9
src/Ombi/ClientApp/app/settings/wiki.component.ts
Normal file
9
src/Ombi/ClientApp/app/settings/wiki.component.ts
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
import { Component, Input } from "@angular/core";
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector:"wiki",
|
||||||
|
templateUrl: "./wiki.component.html",
|
||||||
|
})
|
||||||
|
export class WikiComponent {
|
||||||
|
@Input() public url: string;
|
||||||
|
}
|
|
@ -27,7 +27,7 @@
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="alias" class="control-label">Email Address</label>
|
<label for="alias" class="control-label">Email Address</label>
|
||||||
<div>
|
<div>
|
||||||
<input type="text" [(ngModel)]="user.emailAddress" class="form-control form-control-custom " id="emailAddress" name="emailAddress" value="{{user?.emailAddress}}" [disabled]="user?.userType != 1">
|
<input type="text" [(ngModel)]="user.emailAddress" class="form-control form-control-custom " id="emailAddress" name="emailAddress" value="{{user?.emailAddress}}" [disabled]="user?.userType == 2">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -6,6 +6,7 @@ using Microsoft.Extensions.Caching.Memory;
|
||||||
using Ombi.Api.Service;
|
using Ombi.Api.Service;
|
||||||
using Ombi.Attributes;
|
using Ombi.Attributes;
|
||||||
using Ombi.Helpers;
|
using Ombi.Helpers;
|
||||||
|
using Ombi.Schedule.Jobs.Emby;
|
||||||
using Ombi.Schedule.Jobs.Plex;
|
using Ombi.Schedule.Jobs.Plex;
|
||||||
using Ombi.Schedule.Ombi;
|
using Ombi.Schedule.Ombi;
|
||||||
|
|
||||||
|
@ -17,15 +18,17 @@ namespace Ombi.Controllers
|
||||||
public class JobController : Controller
|
public class JobController : Controller
|
||||||
{
|
{
|
||||||
public JobController(IOmbiAutomaticUpdater updater, IPlexUserImporter userImporter,
|
public JobController(IOmbiAutomaticUpdater updater, IPlexUserImporter userImporter,
|
||||||
IMemoryCache mem)
|
IMemoryCache mem, IEmbyUserImporter embyImporter)
|
||||||
{
|
{
|
||||||
_updater = updater;
|
_updater = updater;
|
||||||
_plexUserImporter = userImporter;
|
_plexUserImporter = userImporter;
|
||||||
|
_embyUserImporter = embyImporter;
|
||||||
_memCache = mem;
|
_memCache = mem;
|
||||||
}
|
}
|
||||||
|
|
||||||
private readonly IOmbiAutomaticUpdater _updater;
|
private readonly IOmbiAutomaticUpdater _updater;
|
||||||
private readonly IPlexUserImporter _plexUserImporter;
|
private readonly IPlexUserImporter _plexUserImporter;
|
||||||
|
private readonly IEmbyUserImporter _embyUserImporter;
|
||||||
private readonly IMemoryCache _memCache;
|
private readonly IMemoryCache _memCache;
|
||||||
|
|
||||||
[HttpPost("update")]
|
[HttpPost("update")]
|
||||||
|
@ -68,5 +71,12 @@ namespace Ombi.Controllers
|
||||||
BackgroundJob.Enqueue(() => _plexUserImporter.Start());
|
BackgroundJob.Enqueue(() => _plexUserImporter.Start());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[HttpPost("embyuserimporter")]
|
||||||
|
public bool EmbyUserImporter()
|
||||||
|
{
|
||||||
|
BackgroundJob.Enqueue(() => _embyUserImporter.Start());
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Add table
Add a link
Reference in a new issue