diff --git a/src/var/lib/tyto/program/db.py b/src/var/lib/tyto/program/db.py index b721f15..e0f1deb 100644 --- a/src/var/lib/tyto/program/db.py +++ b/src/var/lib/tyto/program/db.py @@ -67,6 +67,7 @@ domain_values = \ 'domain_www_url', 'domain_wip_url', 'domain_title', + 'domain_date', 'domain_about', 'domain_lang', 'domain_mail', @@ -74,6 +75,8 @@ domain_values = \ 'domain_logo', 'domain_license', 'domain_licurl', + 'domain_legalurl', + 'domain_termsurl', 'domain_css', 'domain_sep', 'domain_relme', diff --git a/src/var/lib/tyto/program/domain.py b/src/var/lib/tyto/program/domain.py index 6c7031e..f818352 100644 --- a/src/var/lib/tyto/program/domain.py +++ b/src/var/lib/tyto/program/domain.py @@ -31,6 +31,7 @@ import logs, db, tyto, html domain_footer_about = \ 'Un petit essai' + #==========================# # Manage Argument 'domain' # # target: 3rd argument # @@ -52,7 +53,6 @@ def manage_domain(target): # When an active and complete domain is needed # #----------------------------------------------# def domain_needed(): - # Check if can process if not db.domain_exists \ or db.incomplete_domain \ or not db.domain_active: @@ -854,16 +854,15 @@ def create_footer(option): if not res in ['y', 'Y']: return # Default footer contents - Tytosrc = '(%s)'%tyto.trans[3][tyto.n] + Tytosrc = '(\n%s%s)'%(9 * ' ', tyto.trans[3][tyto.n]) tyto_show = \ - '%s %s'%(tyto.Tyto, Tytosrc) + '\n%s%s %s'%(9 * ' ', tyto.Tyto, Tytosrc) # Show copyright date from creation to now year - print(db.domain_date, datetime.now().year) if int(db.domain_date) == int(datetime.now().year): footer_date = db.domain_date else: @@ -871,29 +870,32 @@ def create_footer(option): # Simple link to home domain_home = \ - '%s'%db.domain_title + '\n%s%s'%(9 * ' ', db.domain_title) # Show domain_HTML_about (if not empty), else domain_about if domain_footer_about: db.domain_about = domain_footer_about + # License URL + if not db.domain_licurl: db.domain_licurl = '/' + # Links for laws (Terms and legals) if db.domain_legalurl: legal_link = \ - '%s'%tyto.trans[16][tyto.n] + '%s'%(11 * ' ', tyto.trans[16][tyto.n]) if db.domain_termsurl: terms_link = \ - '%s'%tyto.trans[15][tyto.n] + '%s'%(11 * ' ', tyto.trans[15][tyto.n]) footer_law = '' if db.domain_termsurl and db.domain_legalurl: - footer_law = '%s - %s'%(legal_link, terms_link) + footer_law = '%s - \n%s%s'%(legal_link, 8 * ' ', terms_link) elif db.domain_termsurl: footer_law = terms_link elif db.domain_legalurl: @@ -919,9 +921,10 @@ def create_footer(option): '-->\n' + \ '