Show event category with map

main
Bob Mottram 2025-05-11 11:59:09 +01:00
parent f686cfc52b
commit c8b7e8aa87
1 changed files with 8 additions and 1 deletions

View File

@ -3211,6 +3211,13 @@ def individual_post_as_html(signing_priv_key_pem: str,
translate, session, translate, session,
session, session) session, session)
if map_str: if map_str:
event_category = ''
if category_str:
category_text = 'Category'
if translate.get('Category'):
category_text = translate['Category']
event_category = '<br>' + category_text + ': ' + \
category_str + '\n'
map_addr_str = '' map_addr_str = ''
if '<br><address>' in location_str: if '<br><address>' in location_str:
# append the address after the map # append the address after the map
@ -3218,7 +3225,7 @@ def individual_post_as_html(signing_priv_key_pem: str,
map_addr_str = \ map_addr_str = \
'<br><br><address>' + addrstr + '\n' '<br><br><address>' + addrstr + '\n'
map_str = '<center>\n' + map_str + \ map_str = '<center>\n' + map_str + \
map_addr_str + '</center>\n' map_addr_str + event_category + '</center>\n'
attrib = None attrib = None
if post_json_object['object'].get('attributedTo'): if post_json_object['object'].get('attributedTo'):
attrib = \ attrib = \