diff options
Diffstat (limited to 'client/src/app')
3 files changed, 19 insertions, 1 deletions
diff --git a/client/src/app/+admin/users/user-edit/user-edit.component.html b/client/src/app/+admin/users/user-edit/user-edit.component.html index 78c92227f..fb34d6b22 100644 --- a/client/src/app/+admin/users/user-edit/user-edit.component.html +++ b/client/src/app/+admin/users/user-edit/user-edit.component.html | |||
@@ -174,6 +174,17 @@ | |||
174 | </div> | 174 | </div> |
175 | </div> | 175 | </div> |
176 | 176 | ||
177 | <div class="form-group" *ngIf="!isCreation() && getAuthPlugins().length !== 0"> | ||
178 | <label i18n for="pluginAuth">Auth plugin</label> | ||
179 | |||
180 | <div class="peertube-select-container"> | ||
181 | <select id="pluginAuth" formControlName="pluginAuth" class="form-control"> | ||
182 | <option [value]="null" i18n>None (local authentication)</option> | ||
183 | <option *ngFor="let authPlugin of getAuthPlugins()" [value]="authPlugin">{{ authPlugin }}</option> | ||
184 | </select> | ||
185 | </div> | ||
186 | </div> | ||
187 | |||
177 | <div class="form-group"> | 188 | <div class="form-group"> |
178 | <my-peertube-checkbox | 189 | <my-peertube-checkbox |
179 | inputName="byPassAutoBlock" formControlName="byPassAutoBlock" | 190 | inputName="byPassAutoBlock" formControlName="byPassAutoBlock" |
diff --git a/client/src/app/+admin/users/user-edit/user-edit.ts b/client/src/app/+admin/users/user-edit/user-edit.ts index 1613bb0d1..faa2f5ad8 100644 --- a/client/src/app/+admin/users/user-edit/user-edit.ts +++ b/client/src/app/+admin/users/user-edit/user-edit.ts | |||
@@ -42,6 +42,11 @@ export abstract class UserEdit extends FormReactive implements OnInit { | |||
42 | return forAccount + forChannels | 42 | return forAccount + forChannels |
43 | } | 43 | } |
44 | 44 | ||
45 | getAuthPlugins () { | ||
46 | return this.serverConfig.plugin.registeredIdAndPassAuths.map(p => p.npmName) | ||
47 | .concat(this.serverConfig.plugin.registeredExternalAuths.map(p => p.npmName)) | ||
48 | } | ||
49 | |||
45 | isInBigView () { | 50 | isInBigView () { |
46 | return this.screenService.getWindowInnerWidth() > 1600 | 51 | return this.screenService.getWindowInnerWidth() > 1600 |
47 | } | 52 | } |
diff --git a/client/src/app/+admin/users/user-edit/user-update.component.ts b/client/src/app/+admin/users/user-edit/user-update.component.ts index e16f66a2b..281c3dcef 100644 --- a/client/src/app/+admin/users/user-edit/user-update.component.ts +++ b/client/src/app/+admin/users/user-edit/user-update.component.ts | |||
@@ -53,7 +53,8 @@ export class UserUpdateComponent extends UserEdit implements OnInit, OnDestroy { | |||
53 | role: USER_ROLE_VALIDATOR, | 53 | role: USER_ROLE_VALIDATOR, |
54 | videoQuota: USER_VIDEO_QUOTA_VALIDATOR, | 54 | videoQuota: USER_VIDEO_QUOTA_VALIDATOR, |
55 | videoQuotaDaily: USER_VIDEO_QUOTA_DAILY_VALIDATOR, | 55 | videoQuotaDaily: USER_VIDEO_QUOTA_DAILY_VALIDATOR, |
56 | byPassAutoBlock: null | 56 | byPassAutoBlock: null, |
57 | pluginAuth: null | ||
57 | }, defaultValues) | 58 | }, defaultValues) |
58 | 59 | ||
59 | this.paramsSub = this.route.params.subscribe(routeParams => { | 60 | this.paramsSub = this.route.params.subscribe(routeParams => { |
@@ -120,6 +121,7 @@ export class UserUpdateComponent extends UserEdit implements OnInit, OnDestroy { | |||
120 | role: userJson.role.toString(), | 121 | role: userJson.role.toString(), |
121 | videoQuota: userJson.videoQuota, | 122 | videoQuota: userJson.videoQuota, |
122 | videoQuotaDaily: userJson.videoQuotaDaily, | 123 | videoQuotaDaily: userJson.videoQuotaDaily, |
124 | pluginAuth: userJson.pluginAuth, | ||
123 | byPassAutoBlock: userJson.adminFlags & UserAdminFlag.BYPASS_VIDEO_AUTO_BLACKLIST | 125 | byPassAutoBlock: userJson.adminFlags & UserAdminFlag.BYPASS_VIDEO_AUTO_BLACKLIST |
124 | }) | 126 | }) |
125 | } | 127 | } |