diff options
author | Lauri Ojansivu <x@xet7.org> | 2018-12-18 20:23:43 +0200 |
---|---|---|
committer | Lauri Ojansivu <x@xet7.org> | 2018-12-18 20:23:43 +0200 |
commit | 61c02920891b95e7d0779848ebe4f6b3d516592c (patch) | |
tree | cdee0f25362e47d6ea8f10301d4e959e777e2163 /client | |
parent | c8173fd9f9d220c7de40c9b7ecdca34d97181f26 (diff) | |
parent | 2fbcf7e9b61702a2c3311f813de2bb12a754b2b2 (diff) | |
download | wekan-61c02920891b95e7d0779848ebe4f6b3d516592c.tar.gz wekan-61c02920891b95e7d0779848ebe4f6b3d516592c.tar.bz2 wekan-61c02920891b95e7d0779848ebe4f6b3d516592c.zip |
Merge branch 'edge' into meteor-1.8
Diffstat (limited to 'client')
-rw-r--r-- | client/components/main/layouts.jade | 2 | ||||
-rw-r--r-- | client/components/main/layouts.js | 9 | ||||
-rw-r--r-- | client/components/settings/settingBody.jade | 6 | ||||
-rw-r--r-- | client/components/settings/settingBody.js | 4 |
4 files changed, 21 insertions, 0 deletions
diff --git a/client/components/main/layouts.jade b/client/components/main/layouts.jade index d0c27da5..55ee2686 100644 --- a/client/components/main/layouts.jade +++ b/client/components/main/layouts.jade @@ -38,7 +38,9 @@ template(name="userFormsLayout") template(name="defaultLayout") +header #content + | {{{afterBodyStart}}} +Template.dynamic(template=content) + | {{{beforeBodyEnd}}} if (Modal.isOpen) #modal .overlay diff --git a/client/components/main/layouts.js b/client/components/main/layouts.js index d4a9d6d1..a50d167e 100644 --- a/client/components/main/layouts.js +++ b/client/components/main/layouts.js @@ -42,6 +42,15 @@ Template.userFormsLayout.helpers({ return Settings.findOne(); }, + + afterBodyStart() { + return currentSetting.customHTMLafterBodyStart; + }, + + beforeBodyEnd() { + return currentSetting.customHTMLbeforeBodyEnd; + }, + languages() { return _.map(TAPi18n.getLanguages(), (lang, code) => { const tag = code; 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) { |