aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+admin
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-08-31 10:05:54 +0200
committerChocobozzz <me@florianbigard.com>2018-08-31 10:05:54 +0200
commitd6ca951b3cc7cb19ad9f52249444fc68c5d81d50 (patch)
tree181543a4b0dc2fba2dd78bb5cfee1779e9d7e069 /client/src/app/+admin
parentafd2cba5541fcc4d182176b8797f8416df831869 (diff)
downloadPeerTube-d6ca951b3cc7cb19ad9f52249444fc68c5d81d50.tar.gz
PeerTube-d6ca951b3cc7cb19ad9f52249444fc68c5d81d50.tar.zst
PeerTube-d6ca951b3cc7cb19ad9f52249444fc68c5d81d50.zip
Fix user create daily quota component
Diffstat (limited to 'client/src/app/+admin')
-rw-r--r--client/src/app/+admin/users/user-edit/user-create.component.ts6
-rw-r--r--client/src/app/+admin/users/user-edit/user-edit.component.html14
-rw-r--r--client/src/app/+admin/users/user-edit/user-edit.component.scss2
3 files changed, 14 insertions, 8 deletions
diff --git a/client/src/app/+admin/users/user-edit/user-create.component.ts b/client/src/app/+admin/users/user-edit/user-create.component.ts
index c15cfb267..25c060344 100644
--- a/client/src/app/+admin/users/user-edit/user-create.component.ts
+++ b/client/src/app/+admin/users/user-edit/user-create.component.ts
@@ -32,7 +32,8 @@ export class UserCreateComponent extends UserEdit implements OnInit {
32 ngOnInit () { 32 ngOnInit () {
33 const defaultValues = { 33 const defaultValues = {
34 role: UserRole.USER.toString(), 34 role: UserRole.USER.toString(),
35 videoQuota: '-1' 35 videoQuota: '-1',
36 videoQuotaDaily: '-1'
36 } 37 }
37 38
38 this.buildForm({ 39 this.buildForm({
@@ -40,7 +41,8 @@ export class UserCreateComponent extends UserEdit implements OnInit {
40 email: this.userValidatorsService.USER_EMAIL, 41 email: this.userValidatorsService.USER_EMAIL,
41 password: this.userValidatorsService.USER_PASSWORD, 42 password: this.userValidatorsService.USER_PASSWORD,
42 role: this.userValidatorsService.USER_ROLE, 43 role: this.userValidatorsService.USER_ROLE,
43 videoQuota: this.userValidatorsService.USER_VIDEO_QUOTA 44 videoQuota: this.userValidatorsService.USER_VIDEO_QUOTA,
45 videoQuotaDaily: this.userValidatorsService.USER_VIDEO_QUOTA_DAILY
44 }, defaultValues) 46 }, defaultValues)
45 } 47 }
46 48
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 bb745d6aa..56cf7d17d 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
@@ -61,7 +61,14 @@
61 </option> 61 </option>
62 </select> 62 </select>
63 </div> 63 </div>
64 64
65 <div i18n class="transcoding-information" *ngIf="isTranscodingInformationDisplayed()">
66 Transcoding is enabled on server. The video quota only take in account <strong>original</strong> video. <br />
67 At most, this user could use ~ {{ computeQuotaWithTranscoding() | bytes: 0 }}.
68 </div>
69 </div>
70
71 <div class="form-group">
65 <label i18n for="videoQuotaDaily">Daily video quota</label> 72 <label i18n for="videoQuotaDaily">Daily video quota</label>
66 <div class="peertube-select-container"> 73 <div class="peertube-select-container">
67 <select id="videoQuotaDaily" formControlName="videoQuotaDaily"> 74 <select id="videoQuotaDaily" formControlName="videoQuotaDaily">
@@ -70,11 +77,6 @@
70 </option> 77 </option>
71 </select> 78 </select>
72 </div> 79 </div>
73
74 <div i18n class="transcoding-information" *ngIf="isTranscodingInformationDisplayed()">
75 Transcoding is enabled on server. The video quota only take in account <strong>original</strong> video. <br />
76 At most, this user could use ~ {{ computeQuotaWithTranscoding() | bytes: 0 }}.
77 </div>
78 </div> 80 </div>
79 81
80 <input type="submit" value="{{ getFormButtonTitle() }}" [disabled]="!form.valid"> 82 <input type="submit" value="{{ getFormButtonTitle() }}" [disabled]="!form.valid">
diff --git a/client/src/app/+admin/users/user-edit/user-edit.component.scss b/client/src/app/+admin/users/user-edit/user-edit.component.scss
index b74604e3b..6675f65cc 100644
--- a/client/src/app/+admin/users/user-edit/user-edit.component.scss
+++ b/client/src/app/+admin/users/user-edit/user-edit.component.scss
@@ -17,6 +17,8 @@ input:not([type=submit]) {
17input[type=submit] { 17input[type=submit] {
18 @include peertube-button; 18 @include peertube-button;
19 @include orange-button; 19 @include orange-button;
20
21 margin-top: 10px;
20} 22}
21 23
22.transcoding-information { 24.transcoding-information {