* Added the default streaming country to the user importer

This commit is contained in:
tidusjar 2021-01-08 20:00:01 +00:00
commit 93997116be
3 changed files with 16 additions and 4 deletions

View file

@ -212,6 +212,7 @@ export interface IUserManagementSettings extends ISettings {
bannedPlexUserIds: string[]; bannedPlexUserIds: string[];
bannedEmbyUserIds: string[]; bannedEmbyUserIds: string[];
bannedJellyfinUserIds: string[]; bannedJellyfinUserIds: string[];
defaultStreamingCountry: string;
} }
export interface IAbout { export interface IAbout {

View file

@ -75,6 +75,15 @@
</div> </div>
</div> </div>
<mat-form-field>
<mat-label [translate]="'UserPreferences.StreamingCountry'"></mat-label>
<mat-select [(value)]="settings.defaultStreamingCountry">
<mat-option *ngFor="let value of countries" [value]="value">
{{value}}
</mat-option>
</mat-select>
</mat-form-field>
</div> </div>
<div class="form-group"> <div class="form-group">
<button (click)="submit()" mat-raised-button type="submit" id="save" class="mat-focus-indicator mat-stroked-button accent mat-accent mat-raised-button mat-button-base" ng-reflect-disabled="false"> <button (click)="submit()" mat-raised-button type="submit" id="save" class="mat-focus-indicator mat-stroked-button accent mat-accent mat-raised-button mat-button-base" ng-reflect-disabled="false">

View file

@ -29,6 +29,7 @@ export class UserManagementComponent implements OnInit {
public bannedJellyfinUsers: IUsersModel[] = []; public bannedJellyfinUsers: IUsersModel[] = [];
public enableImportButton = false; public enableImportButton = false;
public countries: string[];
constructor(private readonly settingsService: SettingsService, constructor(private readonly settingsService: SettingsService,
private readonly notificationService: NotificationService, private readonly notificationService: NotificationService,
@ -40,6 +41,7 @@ export class UserManagementComponent implements OnInit {
} }
public ngOnInit(): void { public ngOnInit(): void {
this.identityService.getSupportedStreamingCountries().subscribe(x => this.countries = x);
this.settingsService.getUserManagementSettings().subscribe(x => { this.settingsService.getUserManagementSettings().subscribe(x => {
this.settings = x; this.settings = x;