summaryrefslogtreecommitdiffstats
path: root/client/components/settings
diff options
context:
space:
mode:
authorLauri Ojansivu <x@xet7.org>2018-12-16 22:21:16 +0200
committerLauri Ojansivu <x@xet7.org>2018-12-16 22:21:16 +0200
commitf1ed6304a4c3bfcd1c778b0c43cafe6808829286 (patch)
tree5c2ecf6231e906c1dc54b6777b345281d14a9483 /client/components/settings
parenta42d9871bd420ba0647a590ad2a131822455a905 (diff)
downloadwekan-f1ed6304a4c3bfcd1c778b0c43cafe6808829286.tar.gz
wekan-f1ed6304a4c3bfcd1c778b0c43cafe6808829286.tar.bz2
wekan-f1ed6304a4c3bfcd1c778b0c43cafe6808829286.zip
- Admin Panel / Layout / Custom HTML after <body> start, and Custom HTML before </body> end.
In progress, does not work yet. Thanks to xet7 !
Diffstat (limited to 'client/components/settings')
-rw-r--r--client/components/settings/settingBody.jade6
-rw-r--r--client/components/settings/settingBody.js4
2 files changed, 10 insertions, 0 deletions
diff --git a/client/components/settings/settingBody.jade b/client/components/settings/settingBody.jade
index bc6e0f50..153649fc 100644
--- a/client/components/settings/settingBody.jade
+++ b/client/components/settings/settingBody.jade
@@ -145,5 +145,11 @@ template(name='layoutSettings')
.title {{_ 'custom-product-name'}}
.form-group
input.form-control#product-name(type="text", placeholder="Wekan" value="{{currentSetting.productName}}")
+ li.layout-form
+ .title {{_ 'add-custom-html-after-body-start'}}
+ textarea#customHTMLafterBodyStart.form-control= currentSetting.customHTMLafterBodyStart
+ li.layout-form
+ .title {{_ 'add-custom-html-before-body-end'}}
+ textarea#customHTMLbeforeBodyEnd.form-control= currentSetting.customHTMLbeforeBodyEnd
li
button.js-save-layout.primary {{_ 'save'}}
diff --git a/client/components/settings/settingBody.js b/client/components/settings/settingBody.js
index ba5b4f47..4f07c84c 100644
--- a/client/components/settings/settingBody.js
+++ b/client/components/settings/settingBody.js
@@ -140,6 +140,8 @@ BlazeComponent.extendComponent({
const productName = $('#product-name').val().trim();
const hideLogoChange = ($('input[name=hideLogo]:checked').val() === 'true');
+ const customHTMLafterBodyStart = $('#customHTMLafterBodyStart').val().trim();
+ const customHTMLbeforeBodyEnd = $('#customHTMLbeforeBodyEnd').val().trim();
try {
@@ -147,6 +149,8 @@ BlazeComponent.extendComponent({
$set: {
productName,
hideLogo: hideLogoChange,
+ customHTMLafterBodyStart,
+ customHTMLbeforeBodyEnd,
},
});
} catch (e) {