aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts')
-rw-r--r--client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts18
1 files changed, 14 insertions, 4 deletions
diff --git a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
index cd8c926f7..027268536 100644
--- a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
+++ b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
@@ -49,7 +49,9 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit {
49 signupLimit: '', 49 signupLimit: '',
50 adminEmail: '', 50 adminEmail: '',
51 userVideoQuota: '', 51 userVideoQuota: '',
52 transcodingThreads: '' 52 transcodingThreads: '',
53 customizationJavascript: '',
54 customizationCSS: ''
53 } 55 }
54 validationMessages = { 56 validationMessages = {
55 instanceName: INSTANCE_NAME.MESSAGES, 57 instanceName: INSTANCE_NAME.MESSAGES,
@@ -84,7 +86,9 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit {
84 adminEmail: [ '', ADMIN_EMAIL.VALIDATORS ], 86 adminEmail: [ '', ADMIN_EMAIL.VALIDATORS ],
85 userVideoQuota: [ '', USER_VIDEO_QUOTA.VALIDATORS ], 87 userVideoQuota: [ '', USER_VIDEO_QUOTA.VALIDATORS ],
86 transcodingThreads: [ '', TRANSCODING_THREADS.VALIDATORS ], 88 transcodingThreads: [ '', TRANSCODING_THREADS.VALIDATORS ],
87 transcodingEnabled: [ ] 89 transcodingEnabled: [ ],
90 customizationJavascript: [ '' ],
91 customizationCSS: [ '' ]
88 } 92 }
89 93
90 for (const resolution of this.resolutions) { 94 for (const resolution of this.resolutions) {
@@ -125,7 +129,11 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit {
125 instance: { 129 instance: {
126 name: this.form.value['instanceName'], 130 name: this.form.value['instanceName'],
127 description: this.form.value['instanceDescription'], 131 description: this.form.value['instanceDescription'],
128 terms: this.form.value['instanceTerms'] 132 terms: this.form.value['instanceTerms'],
133 customizations: {
134 javascript: this.form.value['customizationJavascript'],
135 css: this.form.value['customizationCSS']
136 }
129 }, 137 },
130 cache: { 138 cache: {
131 previews: { 139 previews: {
@@ -183,7 +191,9 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit {
183 adminEmail: this.customConfig.admin.email, 191 adminEmail: this.customConfig.admin.email,
184 userVideoQuota: this.customConfig.user.videoQuota, 192 userVideoQuota: this.customConfig.user.videoQuota,
185 transcodingThreads: this.customConfig.transcoding.threads, 193 transcodingThreads: this.customConfig.transcoding.threads,
186 transcodingEnabled: this.customConfig.transcoding.enabled 194 transcodingEnabled: this.customConfig.transcoding.enabled,
195 customizationJavascript: this.customConfig.instance.customizations.javascript,
196 customizationCSS: this.customConfig.instance.customizations.css
187 } 197 }
188 198
189 for (const resolution of this.resolutions) { 199 for (const resolution of this.resolutions) {