Ability to customize the logo in digest emails

This commit is contained in:
Robin Ward 2014-03-18 15:56:17 -04:00
parent d0edfe2179
commit 84e608079b
3 changed files with 6 additions and 1 deletions

View File

@ -26,7 +26,8 @@ module UserNotificationsHelper
end end
def logo_url def logo_url
logo_url = SiteSetting.logo_url logo_url = SiteSetting.digest_logo_url
logo_url = SiteSetting.logo_url if logo_url.blank?
if logo_url !~ /http(s)?\:\/\// if logo_url !~ /http(s)?\:\/\//
logo_url = "#{Discourse.base_url}#{logo_url}" logo_url = "#{Discourse.base_url}#{logo_url}"
end end

View File

@ -610,6 +610,7 @@ en:
onebox_max_chars: "Maximum characters a onebox will import from an external website into the post" onebox_max_chars: "Maximum characters a onebox will import from an external website into the post"
logo_url: "The logo for your site eg: http://example.com/logo.png" logo_url: "The logo for your site eg: http://example.com/logo.png"
digest_logo_url: "The logo used in your site's email digest. If left blank `logo_url` will be used. eg: http://example.com/logo.png"
logo_small_url: "The small logo for your site used when scrolling down on topics eg: http://example.com/logo-small.png" logo_small_url: "The small logo for your site used when scrolling down on topics eg: http://example.com/logo-small.png"
favicon_url: "A favicon for your site, see http://en.wikipedia.org/wiki/Favicon" favicon_url: "A favicon for your site, see http://en.wikipedia.org/wiki/Favicon"
apple_touch_icon_url: "Icon used for Apple touch devices. Recommended size is 144px by 144px." apple_touch_icon_url: "Icon used for Apple touch devices. Recommended size is 144px by 144px."

View File

@ -12,6 +12,9 @@ required:
logo_small_url: logo_small_url:
client: true client: true
default: '/images/d-logo-sketch-small.png' default: '/images/d-logo-sketch-small.png'
digest_logo_url:
client: false
default: ''
favicon_url: favicon_url:
client: true client: true
default: '/images/default-favicon.ico' default: '/images/default-favicon.ico'